checkoutAssociateUser Mutation
Description
Associates a user account with a checkout.
mutation checkoutAssociateUser($id: String!, $data: JSON) {
checkoutAssociateUser(id: $id, data: $data) {
_id
id
configRef
origin
created
shipping {
status
date
method
freeShippingThreshold
tracking
shopCollection
weight
}
billing {
status
paymentDate
refundDate
}
orderId
note {
date
content
}
items {
_id
id
quantity
added
total
unavailable
}
buyer {
_id
email
firstName
id
lastName
name
telephone
organisation
taxNumber
isGuest
}
seller {
_id
id
firstName
lastName
name
email
telephone
taxNumber
}
updated
expires
status
message
totals {
grand
leftToPay
discount
itemsQuantity
itemQuantity
subtotal
subtotalBeforeTaxes
shipping
tax
}
urls {
checkout
storefront
}
useSingleAddress
}
}
Variables
{
"id": "9Pi-nHmv2",
"data": {}
}
Response
{
"checkoutAssociateUser": {
"_id": "b0ecf89ff56cfc48f210376b",
"id": "8c4-BbJVY",
"configRef": "b3770f0bb5a4db7f820e1c99",
"origin": "example",
"created": 1758261269045,
"shipping": {
"status": "example",
"date": 1743776594884,
"method": "example",
"freeShippingThreshold": 1.23,
"tracking": "example",
"shopCollection": true,
"weight": "example"
},
"billing": {
"status": "example",
"paymentDate": 1713465714089,
"refundDate": 1769895154349
},
"orderId": "example",
"note": {
"date": 1754758984304,
"content": "example"
},
"items": [
{
"_id": "b1089f9d1193745192d2b8ba",
"id": "0BJ-6mXBw",
"quantity": 1.23,
"added": 1721836650325,
"total": 29.99,
"unavailable": true
}
],
"buyer": {
"_id": "dfd331d1970a30d943b61a5c",
"email": "email@example.com",
"firstName": "example",
"id": 1.23,
"lastName": "example",
"name": "example",
"telephone": "example",
"organisation": "example",
"taxNumber": "example",
"isGuest": true
},
"seller": {
"_id": "e77cc0c200368547b377013d",
"id": "h2w-wLQl6",
"firstName": "example",
"lastName": "example",
"name": "example",
"email": "email@example.com",
"telephone": "example",
"taxNumber": "example"
},
"updated": 1750740302547,
"expires": 1732727188635,
"status": "example",
"message": "example",
"totals": {
"grand": 1.23,
"leftToPay": 1.23,
"discount": 0.1,
"itemsQuantity": 1.23,
"itemQuantity": 42,
"subtotal": 1.23,
"subtotalBeforeTaxes": 1.23,
"shipping": 1.23,
"tax": 1.23
},
"urls": {
"checkout": "example",
"storefront": "example"
},
"useSingleAddress": true
}
}
Arguments
| Name | Type | Description |
|---|---|---|
id | String! | Checkout identifier string. |
data | JSON | Additional user data in JSON format. |