Order Transaction
Requires access scope or
access scope.
The object represents a payment transaction that's associated with an order. An order
transaction is a specific action or event that happens within the context of an order, such as a customer paying
for a purchase or receiving a refund, or other payment-related activity.
Use the object to capture the complete lifecycle of a payment, from initial
authorization to final settlement, including refunds and currency exchanges. Common use cases for using the
object include:
- Processing new payments for orders
- Managing payment authorizations and captures
- Processing refunds for returned items
- Tracking payment status and errors
- Managing multi-currency transactions
- Handling payment gateway integrations
Each object has a
kind
that defines the type of transaction and a status
that indicates the current state of the transaction. The object stores detailed information about payment
methods, gateway processing, and settlement details.
Learn more about payment processing and payment gateway integrations.
Anchor to FieldsFields
- Anchor to accountNumberaccount•String
Number The masked account number associated with the payment method.
- Anchor to amountRoundingSetamount•Money
Rounding Set Bag The rounding adjustment applied on the cash amount in shop and presentment currencies.
- Anchor to amountSetamount•Money
Set Bag!non-null The amount and currency of the transaction in shop and presentment currencies.
- •String
Authorization code associated with the transaction.
- •Date
Time The time when the authorization expires. This field is available only to stores on a Shopify Plus plan.
- Anchor to createdAtcreated•Date
At Time!non-null Date and time when the transaction was created.
- Anchor to errorCodeerror•Order
Code Transaction Error Code A standardized error code, independent of the payment provider.
- Anchor to feesfees•[Transaction
Fee!]!non-null The transaction fees charged on the order transaction. Only present for Shopify Payments transactions.
- Anchor to formattedGatewayformatted•String
Gateway The human-readable payment gateway name used to process the transaction.
- Anchor to gatewaygateway•String
The payment gateway used to process the transaction.
- •ID!non-null
A globally-unique ID.
- Anchor to kindkind•Order
Transaction Kind!non-null The kind of transaction.
- Anchor to manuallyCapturablemanually•Boolean!non-null
Capturable Whether the transaction can be manually captured.
- Anchor to maximumRefundableV2maximum•Money
Refundable V2 V2 Specifies the available amount with currency to refund on the gateway. This value is only available for transactions of type
.
- Anchor to multiCapturablemulti•Boolean!non-null
Capturable Whether the transaction can be captured multiple times.
- Anchor to orderorder•Order
The associated order.
- Anchor to parentTransactionparent•Order
Transaction Transaction The associated parent transaction, for example the authorization of a capture.
- Anchor to paymentDetailspayment•Payment
Details Details The payment details for the transaction.
- Anchor to paymentIconpayment•Image
Icon The payment icon to display for the transaction.
- Anchor to paymentIdpayment•String
Id The payment ID associated with the transaction.
- Anchor to processedAtprocessed•Date
At Time Date and time when the transaction was processed.
- Anchor to receiptJsonreceipt•JSON
Json The transaction receipt that the payment gateway attaches to the transaction. The value of this field depends on which payment gateway processed the transaction.
- Anchor to settlementCurrencysettlement•Currency
Currency Code The settlement currency.
- Anchor to settlementCurrencyRatesettlement•Decimal
Currency Rate The rate used when converting the transaction amount to settlement currency.
- Anchor to shopifyPaymentsSetshopify•Shopify
Payments Set Payments Transaction Set Contains all Shopify Payments information related to an order transaction. This field is available only to stores on a Shopify Plus plan.
- Anchor to statusstatus•Order
Transaction Status!non-null The status of this transaction.
- Anchor to testtest•Boolean!non-null
Whether the transaction is a test transaction.
- Anchor to totalUnsettledSettotal•Money
Unsettled Set Bag Specifies the available amount with currency to capture on the gateway in shop and presentment currencies. Only available when an amount is capturable or manually mark as paid.
- Anchor to useruser•Staff
Member Staff member who was logged into the Shopify POS device when the transaction was processed.
Deprecated fields
- Anchor to amountamount•Money!non-nullDeprecated
- Anchor to amountV2amount•Money
V2 V2!non-nullDeprecated - Anchor to maximumRefundablemaximum•MoneyDeprecated
Refundable - Anchor to paymentMethodpayment•Payment
Method MethodsDeprecated - Anchor to totalUnsettledtotal•MoneyDeprecated
Unsettled - Anchor to totalUnsettledV2total•Money
Unsettled V2 V2Deprecated
Anchor to MutationsMutations
- •mutation
Captures payment for an authorized transaction on an order. Use this mutation to claim the money that was previously reserved by an authorization transaction.
The
mutation can be used in the following scenarios:
- To capture the full amount of an authorized transaction
- To capture a partial payment by specifying an amount less than the total order amount
- To perform multiple captures on the same order, as long as the order transaction is multi-capturable
NoteMulti-capture functionality is only available to stores on a Shopify Plus plan. For multi-currency orders, the
currency
field is required and should match the presentment currency from the order.After capturing a payment, you can:
- View the transaction details including status, amount, and processing information.
- Track the captured amount in both shop and presentment currencies.
- Monitor the transaction's settlement status.
Learn more about order transactions.
- Anchor to inputinput•Order
Capture Input!required The input for the mutation.
Arguments
- Anchor to transactiontransaction•Order
Transaction The created capture transaction.
- Anchor to userErrorsuser•[User
Errors Error!]!non-null The list of errors that occurred from executing the mutation.
Fields
- •mutation
Trigger the voiding of an uncaptured authorization transaction.
- Anchor to parentTransactionIdparent•ID!required
Transaction Id An uncaptured authorization transaction.
Arguments
- Anchor to transactiontransaction•Order
Transaction The created void transaction.
- Anchor to userErrorsuser•[Transaction
Errors Void User Error!]!non-null The list of errors that occurred from executing the mutation.
Fields