--- title: Job - GraphQL Admin description: A job corresponds to some long running task that the client should poll for status. api_version: 2025-10 api_name: admin type: object api_type: graphql source_url: html: https://shopify.dev/docs/api/admin-graphql/latest/objects/Job md: https://shopify.dev/docs/api/admin-graphql/latest/objects/Job.md --- # Job object A job corresponds to some long running task that the client should poll for status. ## Fields * done [Boolean!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/Boolean) non-null This indicates if the job is still queued or has been run. * id [ID!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/ID) non-null A globally-unique ID that's returned when running an asynchronous mutation. * query [Query​Root](https://shopify.dev/docs/api/admin-graphql/latest/objects/QueryRoot) This field will only resolve once the job is done. Can be used to ask for object(s) that have been changed by the job. *** ## Map No referencing types *** ## Queries * [job](https://shopify.dev/docs/api/admin-graphql/latest/queries/job) query Returns a Job resource by ID. Used to check the status of internal jobs and any applicable changes. *** ## \Job Queries ### Queried by * \[job](https://shopify.dev/docs/api/admin-graphql/latest/queries/job) *** ## Mutations * [collection​Add​Products​V2](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionAddProductsV2) mutation Asynchronously adds a set of products to a given collection. It can take a long time to run. Instead of returning a collection, it returns a job which should be polled. * [collection​Remove​Products](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionRemoveProducts) mutation Removes multiple products from a collection in a single operation. This mutation can process large product sets (up to 250 products) and may take significant time to complete for collections with many products. For example, when ending a seasonal promotion, merchants can remove all sale items from a "Summer Clearance" collection at once rather than editing each product individually. Use `CollectionRemoveProducts` to: * Bulk-remove products from collections efficiently * Clean up collection membership during catalog updates * Implement automated collection management workflows The operation processes asynchronously to avoid timeouts and performance issues, especially for large product sets. Learn more about [collection management](https://shopify.dev/docs/api/admin-graphql/latest/objects/Collection). * [collection​Reorder​Products](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionReorderProducts) mutation Asynchronously reorders products within a specified collection. Instead of returning an updated collection, this mutation returns a job, which should be [polled](https://shopify.dev/api/admin-graphql/latest/queries/job). The [`Collection.sortOrder`](https://shopify.dev/api/admin-graphql/latest/objects/Collection#field-collection-sortorder) must be `MANUAL`. How to use this mutation: * Provide only the products that actually moved in the `moves` list; do not send the entire product list. For example: to move the product at index 1 to index N, send a single move for that product with `newPosition: N`. * Each move is applied sequentially in the order provided. * `newPosition` is a zero-based index within the collection at the moment the move is applied (after any prior moves in the list). * Products not included in `moves` keep their relative order, aside from any displacement caused by the moves. * If `newPosition` is greater than or equal to the number of products, the product is placed at the end. Example: * Initial order: \[A, B, C, D, E] (indices 0..4) * Moves (applied in order): * E -> newPosition: 1 * C -> newPosition: 4 * Result: \[A, E, B, D, C] Displaced products will have their position altered in a consistent manner with no gaps. * [collection​Update](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionUpdate) mutation Updates a [collection](https://shopify.dev/docs/api/admin-graphql/latest/objects/Collection), modifying its properties, products, or publication settings. Collections help organize [products](https://shopify.dev/docs/api/admin-graphql/latest/objects/Product) together in the [online store](https://shopify.dev/docs/apps/build/online-store) and other [sales channels](https://shopify.dev/docs/apps/build/sales-channels). Use the `collectionUpdate` mutation to programmatically modify collections in scenarios such as: * Updating collection details, like title, description, or image * Modifying SEO metadata for better search visibility * Changing which products are included (using rule updates for smart collections) * Publishing or unpublishing collections across different sales channels * Updating custom data using [metafields](https://shopify.dev/docs/apps/build/custom-data/metafields) There are two types of collections with different update capabilities: * **[Custom (manual) collections](https://help.shopify.com/manual/products/collections/manual-shopify-collection)**: You can update collection properties, but rule sets can't be modified since products are manually selected. * **[Smart (automated) collections](https://help.shopify.com/manual/products/collections/automated-collections)**: You can update both collection properties and the rules that automatically determine which products are included. When updating [rule sets](https://shopify.dev/docs/api/admin-graphql/latest/objects/CollectionRuleConditions) for smart collections, the operation might be processed asynchronously. In these cases, the mutation returns a [`job`](https://shopify.dev/docs/api/admin-graphql/latest/objects/Job) object that you can use to track the progress of the update. To publish or unpublish collections to specific sales channels, use the dedicated [`publishablePublish`](https://shopify.dev/docs/api/admin-graphql/latest/mutations/publishablePublish) and [`publishableUnpublish`](https://shopify.dev/docs/api/admin-graphql/latest/mutations/publishableUnpublish) mutations. Learn more about [using metafields with smart collections](https://shopify.dev/docs/apps/build/custom-data/metafields/use-metafield-capabilities). * [customer​Merge](https://shopify.dev/docs/api/admin-graphql/latest/mutations/customerMerge) mutation Merges two customers. * [delivery​Profile​Remove](https://shopify.dev/docs/api/admin-graphql/latest/mutations/deliveryProfileRemove) mutation Enqueue the removal of a delivery profile. * [discount​Automatic​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountAutomaticBulkDelete) mutation Deletes multiple automatic discounts in a single operation, providing efficient bulk management for stores with extensive discount catalogs. This mutation processes deletions asynchronously to handle large volumes without blocking other operations. For example, when cleaning up expired seasonal promotions or removing outdated automatic discounts across product categories, merchants can delete dozens of discounts simultaneously rather than processing each individually. Use `DiscountAutomaticBulkDelete` to: * Remove multiple automatic discounts efficiently * Clean up expired or obsolete promotions * Streamline discount management workflows * Process large-scale discount removals asynchronously The operation returns a job object for tracking deletion progress and any validation errors encountered during processing. Learn more about [discount management](https://shopify.dev/docs/api/admin-graphql/latest/objects/DiscountAutomatic). * [discount​Code​Bulk​Activate](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeBulkActivate) mutation Activates multiple [code discounts](https://help.shopify.com/manual/discounts/discount-types#discount-codes) asynchronously using one of the following: * A search query * A saved search ID * A list of discount code IDs For example, you can activate discounts for all codes that match a search criteria, or activate a predefined set of discount codes. * [discount​Code​Bulk​Deactivate](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeBulkDeactivate) mutation Deactivates multiple [code-based discounts](https://help.shopify.com/manual/discounts/discount-types#discount-codes) asynchronously using one of the following: * A search query * A saved search ID * A list of discount code IDs For example, you can deactivate discounts for all codes that match a search criteria, or deactivate a predefined set of discount codes. * [discount​Code​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeBulkDelete) mutation Deletes multiple [code-based discounts](https://help.shopify.com/manual/discounts/discount-types#discount-codes) asynchronously using one of the following: * A search query * A saved search ID * A list of discount code IDs For example, you can delete discounts for all codes that match a search criteria, or delete a predefined set of discount codes. * [discount​Code​Redeem​Code​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeRedeemCodeBulkDelete) mutation Asynchronously delete [discount codes](https://help.shopify.com/manual/discounts/discount-types#discount-codes) in bulk that customers can use to redeem a discount. * [draft​Order​Bulk​Add​Tags](https://shopify.dev/docs/api/admin-graphql/latest/mutations/draftOrderBulkAddTags) mutation Adds tags to multiple draft orders. * [draft​Order​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/draftOrderBulkDelete) mutation Deletes multiple draft orders. * [draft​Order​Bulk​Remove​Tags](https://shopify.dev/docs/api/admin-graphql/latest/mutations/draftOrderBulkRemoveTags) mutation Removes tags from multiple draft orders. * [marketing​Activities​Delete​All​External](https://shopify.dev/docs/api/admin-graphql/latest/mutations/marketingActivitiesDeleteAllExternal) mutation Deletes all external marketing activities. Deletion is performed by a background job, as it may take a bit of time to complete if a large number of activities are to be deleted. Attempting to create or modify external activities before the job has completed will result in the create/update/upsert mutation returning an error. * [metafield​Definition​Update](https://shopify.dev/docs/api/admin-graphql/latest/mutations/metafieldDefinitionUpdate) mutation Updates a metafield definition. * [metaobject​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/metaobjectBulkDelete) mutation Asynchronously delete metaobjects and their associated metafields in bulk. * [order​Cancel](https://shopify.dev/docs/api/admin-graphql/latest/mutations/orderCancel) mutation Cancels an order, with options for refunding, restocking inventory, and customer notification. *** Caution Order cancellation is irreversible. An order that has been cancelled can't be restored to its original state. *** Use the `orderCancel` mutation to programmatically cancel orders in scenarios such as: * Customer-requested cancellations due to size, color, or other preference changes * Payment processing failures or declined transactions * Fraud detection and prevention * Insufficient inventory availability * Staff errors in order processing * Wholesale or B2B order management workflows The `orderCancel` mutation provides flexible refund options including refunding to original payment methods or issuing store credit. If a payment was only authorized (temporarily held) but not yet charged, that hold will be automatically released when the order is cancelled, even if you choose not to refund other payments. The mutation supports different cancellation reasons: customer requests, payment declines, fraud, inventory issues, staff errors, or other unspecified reasons. Each cancellation can include optional staff notes for internal documentation (notes aren't visible to customers). An order can only be cancelled if it meets the following criteria: * The order hasn't already been cancelled. * The order has no pending payment authorizations. * The order has no active returns in progress. * The order has no outstanding fulfillments that can't be cancelled. Orders might be assigned to locations that become [deactivated](https://help.shopify.com/manual/fulfillment/setup/locations-management#deactivate-and-reactivate-locations) after the order was created. When cancelling such orders, inventory behavior depends on payment status: * **Paid orders**: Cancellation will fail with an error if restocking is enabled, since inventory can't be returned to deactivated locations. * **Unpaid orders**: Cancellation succeeds but inventory is not restocked anywhere, even when the restock option is enabled. The committed inventory effectively becomes unavailable rather than being returned to stock at the deactivated location. After you cancel an order, you can still make limited updates to certain fields (like notes and tags) using the [`orderUpdate`](https://shopify.dev/docs/api/admin-graphql/latest/mutations/orderUpdate). For partial refunds or more complex refund scenarios on active orders, such as refunding only specific line items while keeping the rest of the order fulfilled, consider using the [`refundCreate`](https://shopify.dev/docs/api/admin-graphql/latest/mutations/refundCreate) mutation instead of full order cancellation. Learn how to build apps that integrate with [order management and fulfillment processes](https://shopify.dev/docs/apps/build/orders-fulfillment). * [order​Create​Mandate​Payment](https://shopify.dev/docs/api/admin-graphql/latest/mutations/orderCreateMandatePayment) mutation Creates a payment for an order by mandate. * [product​Duplicate](https://shopify.dev/docs/api/admin-graphql/latest/mutations/productDuplicate) mutation Duplicates a product. If you need to duplicate a large product, such as one that has many [variants](https://shopify.dev/api/admin-graphql/latest/input-objects/ProductVariantInput) that are active at several [locations](https://shopify.dev/api/admin-graphql/latest/input-objects/InventoryLevelInput), you might encounter timeout errors. To avoid these timeout errors, you can instead duplicate the product asynchronously. In API version 2024-10 and higher, include `synchronous: false` argument in this mutation to perform the duplication asynchronously. In API version 2024-07 and lower, use the asynchronous [`ProductDuplicateAsyncV2`](https://shopify.dev/api/admin-graphql/2024-07/mutations/productDuplicateAsyncV2). Metafield values are not duplicated if the unique values capability is enabled. * [product​Reorder​Media](https://shopify.dev/docs/api/admin-graphql/latest/mutations/productReorderMedia) mutation Asynchronously reorders the media attached to a product, changing the sequence in which images, videos, and other media appear in product displays. This affects how media is presented across all sales channels. For example, merchants can move their best product photo to the first position or reorder images to tell a better product story, with changes appearing in storefronts once processing completes. Use `ProductReorderMedia` to: * Optimize media presentation order for better customer experience * Implement drag-and-drop media management interfaces * Automate media sequencing based on performance or quality metrics The operation processes asynchronously to handle products with large media collections without blocking other operations. Learn more about [product media](https://shopify.dev/docs/api/admin-graphql/latest/objects/Media). * [subscription​Billing​Cycle​Bulk​Charge](https://shopify.dev/docs/api/admin-graphql/latest/mutations/subscriptionBillingCycleBulkCharge) mutation Asynchronously queries and charges all subscription billing cycles whose [billingAttemptExpectedDate](https://shopify.dev/api/admin-graphql/latest/objects/SubscriptionBillingCycle#field-billingattemptexpecteddate) values fall within a specified date range and meet additional filtering criteria. The results of this action can be retrieved using the [subscriptionBillingCycleBulkResults](https://shopify.dev/api/admin-graphql/latest/queries/subscriptionBillingCycleBulkResults) query. * [subscription​Billing​Cycle​Bulk​Search](https://shopify.dev/docs/api/admin-graphql/latest/mutations/subscriptionBillingCycleBulkSearch) mutation Asynchronously queries all subscription billing cycles whose [billingAttemptExpectedDate](https://shopify.dev/api/admin-graphql/latest/objects/SubscriptionBillingCycle#field-billingattemptexpecteddate) values fall within a specified date range and meet additional filtering criteria. The results of this action can be retrieved using the [subscriptionBillingCycleBulkResults](https://shopify.dev/api/admin-graphql/latest/queries/subscriptionBillingCycleBulkResults) query. * [theme​Files​Upsert](https://shopify.dev/docs/api/admin-graphql/latest/mutations/themeFilesUpsert) mutation Create or update theme files. * [url​Redirect​Bulk​Delete​All](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteAll) mutation Asynchronously delete [URL redirects](https://shopify.dev/api/admin-graphql/latest/objects/UrlRedirect) in bulk. * [url​Redirect​Bulk​Delete​By​Ids](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteByIds) mutation Asynchronously delete [URLRedirect](https://shopify.dev/api/admin-graphql/latest/objects/UrlRedirect) objects in bulk by IDs. Learn more about [URLRedirect](https://help.shopify.com/en/manual/online-store/menus-and-links/url-redirect) objects. * [url​Redirect​Bulk​Delete​By​Saved​Search](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteBySavedSearch) mutation Asynchronously delete redirects in bulk. * [url​Redirect​Bulk​Delete​By​Search](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteBySearch) mutation Asynchronously delete redirects in bulk. * [url​Redirect​Import​Submit](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectImportSubmit) mutation Submits a `UrlRedirectImport` request to be processed. The `UrlRedirectImport` request is first created with the [`urlRedirectImportCreate`](https://shopify.dev/api/admin-graphql/latest/mutations/urlRedirectImportCreate) mutation. *** ## <\~> Job Mutations ### Mutated by * <\~>[collection​Add​Products​V2](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionAddProductsV2) * <\~>[collection​Remove​Products](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionRemoveProducts) * <\~>[collection​Reorder​Products](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionReorderProducts) * <\~>[collection​Update](https://shopify.dev/docs/api/admin-graphql/latest/mutations/collectionUpdate) * <\~>[customer​Merge](https://shopify.dev/docs/api/admin-graphql/latest/mutations/customerMerge) * <\~>[delivery​Profile​Remove](https://shopify.dev/docs/api/admin-graphql/latest/mutations/deliveryProfileRemove) * <\~>[discount​Automatic​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountAutomaticBulkDelete) * <\~>[discount​Code​Bulk​Activate](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeBulkActivate) * <\~>[discount​Code​Bulk​Deactivate](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeBulkDeactivate) * <\~>[discount​Code​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeBulkDelete) * <\~>[discount​Code​Redeem​Code​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/discountCodeRedeemCodeBulkDelete) * <\~>[draft​Order​Bulk​Add​Tags](https://shopify.dev/docs/api/admin-graphql/latest/mutations/draftOrderBulkAddTags) * <\~>[draft​Order​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/draftOrderBulkDelete) * <\~>[draft​Order​Bulk​Remove​Tags](https://shopify.dev/docs/api/admin-graphql/latest/mutations/draftOrderBulkRemoveTags) * <\~>[marketing​Activities​Delete​All​External](https://shopify.dev/docs/api/admin-graphql/latest/mutations/marketingActivitiesDeleteAllExternal) * <\~>[metafield​Definition​Update](https://shopify.dev/docs/api/admin-graphql/latest/mutations/metafieldDefinitionUpdate) * <\~>[metaobject​Bulk​Delete](https://shopify.dev/docs/api/admin-graphql/latest/mutations/metaobjectBulkDelete) * <\~>[order​Cancel](https://shopify.dev/docs/api/admin-graphql/latest/mutations/orderCancel) * <\~>[order​Create​Mandate​Payment](https://shopify.dev/docs/api/admin-graphql/latest/mutations/orderCreateMandatePayment) * <\~>[product​Duplicate](https://shopify.dev/docs/api/admin-graphql/latest/mutations/productDuplicate) * <\~>[product​Reorder​Media](https://shopify.dev/docs/api/admin-graphql/latest/mutations/productReorderMedia) * <\~>[subscription​Billing​Cycle​Bulk​Charge](https://shopify.dev/docs/api/admin-graphql/latest/mutations/subscriptionBillingCycleBulkCharge) * <\~>[subscription​Billing​Cycle​Bulk​Search](https://shopify.dev/docs/api/admin-graphql/latest/mutations/subscriptionBillingCycleBulkSearch) * <\~>[theme​Files​Upsert](https://shopify.dev/docs/api/admin-graphql/latest/mutations/themeFilesUpsert) * <\~>[url​Redirect​Bulk​Delete​All](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteAll) * <\~>[url​Redirect​Bulk​Delete​By​Ids](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteByIds) * <\~>[url​Redirect​Bulk​Delete​By​Saved​Search](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteBySavedSearch) * <\~>[url​Redirect​Bulk​Delete​By​Search](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectBulkDeleteBySearch) * <\~>[url​Redirect​Import​Submit](https://shopify.dev/docs/api/admin-graphql/latest/mutations/urlRedirectImportSubmit)