SalesAgreement
Requires access scope or
access scope.
A contract between a merchant and a customer to do business. Shopify creates a sales agreement whenever an order is placed, edited, or refunded. A sales agreement has one or more sales records, which provide itemized details about the initial agreement or subsequent changes made to the order. For example, when a customer places an order, Shopify creates the order, generates a sales agreement, and records a sale for each line item purchased in the order. A sale record is specific to a type of order line. Order lines can represent different things such as a purchased product, a tip added by a customer, shipping costs collected at checkout, and more.
Anchor to Fields and connectionsFields and connections
- •
The application that created the agreement.
- Anchor to happenedAthappened•
At DateTime! non-null The date and time at which the agreement occured.
- •ID!non-null
The unique ID for the agreement.
- Anchor to reasonreason•Order
Action non-nullType! The reason the agremeent was created.
- Anchor to salessales•Sale
Connection! non-null The sales associated with the agreement.
- Anchor to useruser•
The staff member associated with the agreement.
1{2 "app": "",3 "happenedAt": "",4 "id": "",5 "reason": "",6 "sales": {7 "first": "",8 "after": "",9 "last": "",10 "before": "",11 "reverse": ""12 },13 "user": ""14}
{
"app": "",
"happenedAt": "",
"id": "",
"reason": "",
"sales": {
"first": "",
"after": "",
"last": "",
"before": "",
"reverse": ""
},
"user": ""
}
interface SalesAgreement {
app: App
happenedAt: DateTime!
id: ID!
reason: OrderActionType!
user: StaffMember
}