Anchor to fulfillmentCreatefulfillment
fulfillmentCreate
mutation
Requires access scope,
access scope or
access scope. Also: The user must have fulfill_and_ship_orders permission.
Creates a fulfillment for one or many fulfillment orders. The fulfillment orders are associated with the same order and are assigned to the same location.
Anchor to Arguments
Arguments
- Anchor to fulfillmentfulfillment•Fulfillment
Input! required The input fields used to create a fulfillment from fulfillment orders.
- Anchor to messagemessage•
An optional message for the fulfillment request.
Was this section helpful?
Anchor to FulfillmentCreatePayload returnsFulfillmentCreatePayload returns
- Anchor to fulfillmentfulfillment•
The created fulfillment.
- Anchor to userErrorsuser•
Errors [UserError!]! non-null The list of errors that occurred from executing the mutation.
Was this section helpful?
Mutation Reference
mutation fulfillmentCreate($fulfillment: FulfillmentInput!, $message: String) {
fulfillmentCreate(fulfillment: $fulfillment, message: $message) {
fulfillment {
# Fulfillment fields
}
userErrors {
field
message
}
}
}
Input
{
"fulfillment": {
"lineItemsByFulfillmentOrder": [
{
"fulfillmentOrderId": "gid://shopify/<objectName>/10079785100",
"fulfillmentOrderLineItems": [
""
]
}
],
"notifyCustomer": true,
"originAddress": {
"address1": "<your-address1>",
"address2": "<your-address2>",
"city": "<your-city>",
"countryCode": "<your-countryCode>",
"provinceCode": "<your-provinceCode>",
"zip": "<your-zip>"
},
"trackingInfo": {
"company": "<your-company>",
"number": "<your-number>",
"numbers": [
"<your-numbers>"
],
"url": "https://example.myshopify.com",
{
"fulfillment": {
"lineItemsByFulfillmentOrder": [
{
"fulfillmentOrderId": "gid://shopify/<objectName>/10079785100",
"fulfillmentOrderLineItems": [
""
]
}
],
"notifyCustomer": true,
"originAddress": {
"address1": "<your-address1>",
"address2": "<your-address2>",
"city": "<your-city>",
"countryCode": "<your-countryCode>",
"provinceCode": "<your-provinceCode>",
"zip": "<your-zip>"
},
"trackingInfo": {
"company": "<your-company>",
"number": "<your-number>",
"numbers": [
"<your-numbers>"
],
"url": "https://example.myshopify.com",
"urls": [
"https://example.myshopify.com"
]
}
},
"message": "<your-message>"
}
input FulfillmentInput {
lineItemsByFulfillmentOrder: [FulfillmentOrderLineItemsInput!]!
notifyCustomer: Boolean
originAddress: FulfillmentOriginAddressInput
trackingInfo: FulfillmentTrackingInput
}
input FulfillmentOrderLineItemsInput {
fulfillmentOrderId: ID!
fulfillmentOrderLineItems: [FulfillmentOrderLineItemInput!]
}
input FulfillmentOriginAddressInput {
address1: String
address2: String
city: String
countryCode: String!
provinceCode: String
zip: String
}
input FulfillmentTrackingInput {
company: String
number: String
numbers: [String!]
url: URL
urls: [URL!]
}