Skip to main content

bulkAssignFulfillmentRule

Assigns a fulfillment rule to a batch of fulfillment orders.

Assigning the rule is what starts a fulfillment order's lifecycle, so this is how a batch of fulfillment orders is put to process at once. See assignFulfillmentRule for the single-fulfillment behaviour.

Runs asynchronously: returns a process_id immediately and reports per-fulfillment results through the process_status_updates subscription. Each fulfillment order is processed independently; the ones that cannot be processed are reported with their reason without stopping the rest.

Business Rules

  • Up to 200 fulfillment orders can be submitted per request
  • A fulfillment order is reported as failed when it does not belong to the company, when it is archived, when its state no longer accepts a rule, or when the rule belongs to another company

Error Scenarios

  • **BAD_REQUEST**: when the number of submitted IDs exceeds the maximum allowed

Permissions Required

  • orders:assign_fulfillment_profile permission

It is checked per fulfillment order while the batch runs, not when the request is accepted. A caller without it still gets PROCESSING, and every fulfillment order is reported as failed through the subscription.

bulkAssignFulfillmentRule(
input: BulkAssignFulfillmentRuleInput!
): AsynchronousActionResponse!

Arguments

bulkAssignFulfillmentRule.input ● BulkAssignFulfillmentRuleInput! non-null input common

Parameters for BulkAssignFulfillmentRule

Type

AsynchronousActionResponse object common

Asynchronous action response type