Home > @infiniteobjects/shopify-data-manager > AdminTypes > BulkOperation
An asynchronous long-running operation to fetch data in bulk or to bulk import data.
Bulk operations are created using the bulkOperationRunQuery
or bulkOperationRunMutation
mutation. After they are created, clients should poll the status
field for updates. When COMPLETED
, the url
field contains a link to the data in [JSONL](http://jsonlines.org/) format.
Refer to the [bulk operations guide](https://shopify.dev/api/usage/bulk-operations/imports) for more details.
Signature:
export interface BulkOperation extends Node
Extends: Node
Property | Modifiers | Type | Description |
---|---|---|---|
completedAt? | Maybe<Scalars[‘DateTime’][‘output’]> | (Optional) When the bulk operation was successfully completed. | |
createdAt | Scalars[‘DateTime’][‘output’] | When the bulk operation was created. | |
errorCode? | Maybe<BulkOperationErrorCode | `${BulkOperationErrorCode}`> | (Optional) Error code for failed operations. | |
fileSize? | Maybe<Scalars[‘UnsignedInt64’][‘output’]> | (Optional) File size in bytes of the file in the url field. |
|
id | Scalars[‘ID’][‘output’] | A globally-unique ID. | |
objectCount | Scalars[‘UnsignedInt64’][‘output’] | A running count of all the objects processed. For example, when fetching all the products and their variants, this field counts both products and variants. This field can be used to track operation progress. | |
partialDataUrl? | Maybe<Scalars[‘URL’][‘output’]> | (Optional) The URL that points to the partial or incomplete response data (in [JSONL](http://jsonlines.org/) format) that was returned by a failed operation. The URL expires 7 days after the operation fails. Returns null when there’s no data available. |
|
query | Scalars[‘String’][‘output’] | GraphQL query document specified in bulkOperationRunQuery . |
|
rootObjectCount | Scalars[‘UnsignedInt64’][‘output’] | A running count of all the objects that are processed at the root of the query. For example, when fetching all the products and their variants, this field only counts products. This field can be used to track operation progress. | |
status | BulkOperationStatus | `${BulkOperationStatus}` | Status of the bulk operation. | |
type | BulkOperationType | `${BulkOperationType}` | The bulk operation’s type. | |
url? | Maybe<Scalars[‘URL’][‘output’]> | (Optional) The URL that points to the response data in [JSONL](http://jsonlines.org/) format. The URL expires 7 days after the operation completes. |