Skip to main content
object

Requires read_payment_sessions access scope.

A unique payment transaction.

Anchor to authorizationExpiresAtauthorizationExpiresAt
•DateTime

The date and time when an authorized payment session expires.

•ID!non-null

A globally-unique ID.

•PaymentSessionNextAction

The next action expected of the partner.

•DateTime

The date and time when a pending payment session expires.

•PaymentSessionStates!non-null

Details about the payment state.


Was this section helpful?

•mutation

Initiates the confirmation process of the given payment_session.

Shopify will start confirming the payment. According to its business logic, Shopify determines if the payment can be authorized and sends a POST request to the payments app, delivering the confirmation result.

Arguments

•ID!required

The payment session ID.


Fields

•PaymentSession

The updated payment session.

•[PaymentSessionConfirmUserError!]!non-null

The list of errors that occurred from executing the mutation.

•mutation

Change a payment session status to pending.

Upon receiving the response from the PaymentSessionPending mutation, you must redirect the customer back to Shopify, using redirectUrl in nextAction.

Upon completion, pending payments must be finalized into either a successful or failed state using the paymentSessionResolve or paymentSessionReject mutations. Both sale and authorization payments can be marked as pending.

Arguments

•ID!required

The payment session ID.

•DateTime!required

The date and time when the pending payment expires, recommended to be within 3 days.

•PaymentSessionStatePendingReason!required

The reason the payment is pending.


Fields

•PaymentSession

The updated payment session.

•[PaymentSessionPendingUserError!]!non-null

The list of errors that occurred from executing the mutation.

•mutation

Redirects the buyer to the given URL for the payment session. For example, Shopify will redirect the buyer to the URL where the 3DS authentication will take place for onsite payment with credit_card payment method.

Arguments

•ID!required

The payment session ID.

•URL!required

The URL that Shopify will redirect the buyer to, for 3DS authentication. Applicable to payments with the credit card payment method only.


Fields

•PaymentSession

The updated payment session.

•[PaymentSessionRedirectUserError!]!non-null

The list of errors that occurred from executing the mutation.

•mutation

Rejects an open payment session. After the paymentSessionReject mutation completes on a given payment session, any paymentSessionResolve mutation attempts will fail. Subsequent paymentSessionReject mutation attempts will succeed, but the RejectionReasonInput argument will be ignored.

Arguments

•PaymentSessionThreeDSecureAuthentication

The 3D Secure authentication data from the partner. Must be present if and only if the Redirect mutation has been called and the payment method is credit card.

•ID!required

The payment session ID.

•PaymentSessionPaymentDetails

The payment details used to process the transaction.

•PaymentSessionRejectionReasonInput!required

The rejection reason.


Fields

•PaymentSession

The updated payment session.

•[UserError!]!non-null

The list of errors that occurred from executing the mutation.

•mutation

Resolves an open payment session. After the paymentSessionResolve mutation completes on a given payment session, any paymentSessionReject mutation attempts will fail. Subsequent paymentSessionResolve mutation attempts will succeed, but the Details argument will be ignored.

Arguments

•PaymentSessionThreeDSecureAuthentication

The 3D Secure authentication data from the partner. Must be present if and only if the Redirect mutation has been called and the payment method is credit card.

Anchor to authorizationExpiresAtauthorizationExpiresAt
•DateTime

The date and time when an authorized payment session expires.

•ID!required

The payment session ID.

Anchor to networkTransactionIdnetworkTransactionId
•String

The transaction ID issued by the network when processing the payment.

•PaymentSessionPaymentDetails

The payment details used to process the transaction.


Fields

•PaymentSession

The updated payment session.

•[UserError!]!non-null

The list of errors that occurred from executing the mutation.


Was this section helpful?