Export CSV Template

Download a pre-formatted CSV template with the correct column headers for bulk-importing records into a workspace.


Export CSV Template

The exportCSVTemplate mutation generates a blank CSV file pre-populated with the correct column headers for a given workspace, including all custom field names. This template can be filled out and then uploaded via the importTodos mutation.

Basic Example

mutation DownloadImportTemplate {
  exportCSVTemplate(
    input: {
      projectId: "clm4n8qwx000008l0g4oxdqn7"
    }
  )
}

Advanced Example

Use the returned signed URL to trigger a browser download:

mutation DownloadImportTemplate {
  exportCSVTemplate(
    input: {
      projectId: "clm4n8qwx000008l0g4oxdqn7"
    }
  )
}

# Response:
# {
#   "data": {
#     "exportCSVTemplate": "https://storage.example.com/org-slug/workspace-slug/workspace-template-301520032025.csv?X-Amz-Expires=86400&..."
#   }
# }

Input Parameters

ExportCSVTemplateInput

ParameterTypeRequiredDescription
projectIdString!YesID of the workspace to generate the template for

Response Fields

FieldTypeDescription
exportCSVTemplateString!A signed download URL for the generated CSV template file. The URL expires after 24 hours.

Template Columns

The generated CSV contains a header row with the following columns, followed by one empty data row:

ColumnDescription
TitleRecord title
ListName of the list to place the record in
DoneCompletion status (true / false)
Start DateStart date of the record
Due DateDue date of the record
DescriptionRecord description
AssigneesComma-separated assignee names or emails
Created AtOriginal creation timestamp
Updated AtOriginal last-updated timestamp
Created ByOriginal creator name or email
ColorRecord color
ProjectWorkspace name
TagsComma-separated tag names
Custom field columnsOne column per custom field in the workspace, ordered by position. Currency-type fields include an additional Currency Types column immediately after.

Required Permissions

Access LevelCan Export Template
OWNERYes
ADMINYes
MEMBERYes
CLIENTYes
COMMENT_ONLYYes
VIEW_ONLYYes

Any user with access to the workspace can generate a CSV template. Creating records from the template still requires record-creation permission.

Error Responses

ProjectNotFoundError

{
  "errors": [{
    "message": "Project was not found.",
    "extensions": {
      "code": "PROJECT_NOT_FOUND"
    }
  }]
}

When: The specified projectId does not exist.

Important Notes

  • Signed URL: The returned URL is a pre-signed storage URL that expires after 24 hours. Download the file promptly or request a new URL.
  • Custom Fields Included: The template automatically includes columns for every custom field configured in the workspace, ordered by their position. This ensures CSV imports can set custom field values.
  • Currency Fields: If the workspace has a currency-type custom field, an additional Currency Types column is inserted immediately after the currency column for specifying the currency code (e.g., USD, EUR).
  • Workflow: The typical bulk-import workflow is:
    1. Call exportCSVTemplate to download the template
    2. Fill in record data in the CSV
    3. Upload the CSV file using the file upload API
    4. Call importTodos with the s3Key, headers, and projectId
    5. Subscribe to subscribeToImportExportProgress to track progress