Get imports grid
Retrieves a paginated, filterable, and sortable list of all CSV imports in the workspace.
What are Imports? The imports feature allows you to bulk import data from CSV files into Leadtime. You can import entities like Employees, Organizations, Projects, Tasks, and more. The system uses AI to automatically suggest field mappings, and you can preview results before executing.
What is returned:
- Paginated list of imports with metadata (file name, status, row/column counts, timestamps)
- Supports server-side filtering, sorting, and pagination
- Quick search available on file names
Import Status Values:
Uploaded: Import created and ready for mapping/executionProcessing: Import is currently running in the backgroundCompleted: Import finished successfullyFailed: Import encountered errors during processing
Retrieves a paginated grid of imports with filtering and sorting capabilities. Quick search available on: fileName. Filterable fields: fileName, status, rowCount, columnCount, createdAt, importedAt. Sortable fields: fileName, status, rowCount, columnCount, createdAt, importedAt.
GET
/imports-management/gridAuthorization
AuthorizationOAuth2 access token · headerrequiredScopes:
api:reador
AuthorizationBearer token (JWT) · headerrequiredQuery parameters
pagenumberPage number (1-based)
pageSizenumberNumber of items per page
viewIdstringView identifier for saved grid configurations
quickSearchstringQuick search text. Searches across: fileName
filtersstringJSON string containing filter configuration.
**Available Fields:**
- **fileName** (string): Import file name
- **status** (set): Import status (Uploaded, Processing, Completed, Failed)
- **rowCount** (number): Number of rows in the imported file
- **columnCount** (number): Number of columns in the imported file
- **createdAt** (date): Import creation timestamp
- **importedAt** (date): Import completion timestamp
**Filter Structure:**
```json
[
{
"type": "string|number|date|set|boolean|array|task_status|task_type",
"fieldName": "field_name",
"value": {
"comparison": "comparison_type",
"value": "filter_value"
}
}
]
```
**Group Filters (AND/OR Combinations):**
```json
[
{
"type": "group",
"fieldName": "group0.18807479823070028",
"value": {
"type": "or",
"filters": [
{
"type": "string",
"fieldName": "fileName",
"value": {
"comparison": "contain",
"value": "aa"
}
},
{
"type": "number",
"fieldName": "rowCount",
"value": {
"comparison": ">=",
"value": 33
}
}
]
}
}
]
```
**Available Comparison Operators:**
- **fileName** (string): Import file name (string filter). Available comparisons: contain, not_contain, equal, starts_with, ends_with, is_empty, is_not_empty
- **status** (set): Import status (Uploaded, Processing, Completed, Failed) (set filter). Available comparisons: in, not_in, is_empty, is_not_empty
- **rowCount** (number): Number of rows in the imported file (number filter). Available comparisons: equal, not_equal, >, <, >=, <=, is_empty, is_not_empty
- **columnCount** (number): Number of columns in the imported file (number filter). Available comparisons: equal, not_equal, >, <, >=, <=, is_empty, is_not_empty
- **createdAt** (date): Import creation timestamp (date filter). Available comparisons: equal, not_equal, >, <, >=, <=, between, lastMonth, thisMonth, is_empty, is_not_empty
- **importedAt** (date): Import completion timestamp (date filter). Available comparisons: equal, not_equal, >, <, >=, <=, between, lastMonth, thisMonth, is_empty, is_not_empty
**Note:** Use `quickSearch` parameter for simple text search instead of adding it to filters.
sortstringJSON array of sort objects.
**Sortable Fields:**
- **fileName**: Import file name
- **status**: Import status (Uploaded, Processing, Completed, Failed)
- **rowCount**: Number of rows in the imported file
- **columnCount**: Number of columns in the imported file
- **createdAt**: Import creation timestamp
- **importedAt**: Import completion timestamp
**Sort Structure:**
```json
[
{
"field": "field_name",
"direction": "asc|desc"
}
]
```
**Default Sort:** createdAt (desc)
fieldsToReturnany[]Comma-separated list of field names to include in response items. If not provided, all fields are returned.
**Available Fields:** fileName, status, rowCount, columnCount, createdAt, importedAt
Responses
200Successfully retrieved imports grid
itemsobject[]requiredArray of import items in the current page. Each item represents a CSV import with its metadata and status.
Show propertiesHide properties
Array of
objectcolumnCountnumberTotal number of columns in the CSV file
createdAtstring<date-time>ISO 8601 timestamp when the import was created
fileNamestring | nullOriginal name of the uploaded CSV file
idstringUnique identifier (UUID) of the import
importedAtstring<date-time> | nullISO 8601 timestamp when the import finished processing (null if not completed)
rowCountnumberTotal number of data rows in the CSV file
statusstringCurrent status: "Uploaded" (ready), "Processing" (running), "Completed" (success), or "Failed" (error)
pagenumberrequiredCurrent page number (1-based indexing)
pageSizenumberrequiredNumber of items per page in this response
totalnumberrequiredTotal number of imports matching the current filters (across all pages)
viewIdstringrequiredView identifier for saved grid configurations (e.g., "all", "recent", custom view name)
400Invalid query parameters
401Unauthorized - Invalid or missing authentication token
403Forbidden - Insufficient API scopes or permissions
Request
curl -X GET "https://leadtime.app/api/public/imports-management/grid" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN"const response = await fetch("https://leadtime.app/api/public/imports-management/grid", {
method: "GET",
headers: {
"Authorization": "Bearer YOUR_ACCESS_TOKEN"
}
});import requests
response = requests.get(
"https://leadtime.app/api/public/imports-management/grid",
headers={
"Authorization": "Bearer YOUR_ACCESS_TOKEN"
},
)Response
{
"items": [
{
"columnCount": 0,
"createdAt": "2024-01-01T00:00:00Z",
"fileName": "string",
"id": "string",
"importedAt": "2024-01-01T00:00:00Z",
"rowCount": 0,
"status": "string"
}
],
"page": 1,
"pageSize": 100,
"total": 42,
"viewId": "all"
}Invalid query parameters
Unauthorized - Invalid or missing authentication token
Forbidden - Insufficient API scopes or permissions