Payment Session
Requires access scope.
A unique payment transaction.
Anchor to FieldsFields
- authorizationExpiresAt (DateTime)
- id (ID!)
- nextAction (PaymentSessionNextAction)
- pendingExpiresAt (DateTime)
- state (PaymentSessionStates!)
- •Date
Time The date and time when an authorized payment session expires.
- •ID!non-null
A globally-unique ID.
- Anchor to nextActionnext•Payment
Action Session Next Action The next action expected of the partner.
Show fields
- Anchor to pendingExpiresAtpending•Date
Expires At Time The date and time when a pending payment session expires.
- Anchor to statestate•Payment
Session States! non-null Details about the payment state.
Show union types
Anchor to MutationsMutations
- paymentSessionConfirm (PaymentSessionConfirmPayload)
- paymentSessionModal (PaymentSessionModalPayload)
- paymentSessionPending (PaymentSessionPendingPayload)
- paymentSessionRedirect (PaymentSessionRedirectPayload)
- paymentSessionReject (PaymentSessionRejectPayload)
- paymentSessionResolve (PaymentSessionResolvePayload)
- •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.
Show payload
- •ID!required
The payment session ID.
Arguments
- •ID!
- •mutation
Raises a modal that will be displayed to the buyer after a checkout is completed. Included data will be used to populate the UI extension in the modal.
Show payload
- Anchor to actionaction•Modal
Action! required The buyer action and corresponding data that will be made available in the modal at runtime.
Show input fields
- Anchor to expiresAtexpires•Date
At Time The date and time the modal will expire, in UTC
- •ID!required
The payment session ID.
Arguments
- •mutation
Change a payment session status to pending.
Upon receiving the response from the
mutation, you must redirect the customer back to Shopify, usingin.Upon completion, pending payments must be finalized into either a successful or failed state using the
ormutations. Bothsaleandauthorizationpayments can be marked as pending.Show payload
- •ID!required
The payment session ID.
- Anchor to pendingExpiresAtpending•Date
Expires At Time! required The date and time when the pending payment expires, recommended to be within 3 days.
- Anchor to reasonreason•Payment
Session State Pending Reason! required The reason the payment is pending.
Show enum values
Arguments
- •ID!
- •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
payment method.Show payload
- •ID!required
The payment session ID.
- Anchor to redirectUrlredirect•URL!
Url required The absolute HTTPS URL, including a host, that Shopify will redirect the buyer to for 3DS authentication. The URL must not contain spaces, ASCII control characters, or user information before the hostname, such as a username or password. Applicable to payments with the credit card payment method only.
Arguments
- •ID!
- •mutation
Rejects an open payment session. After the
mutation completes on a given payment session, anymutation attempts will fail. Subsequentmutation attempts will succeed, but theargument will be ignored.Show payload
- Anchor to authenticationauthentication•Payment
Session Three DSecure Authentication 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.
Show input fields
- •ID!required
The payment session ID.
- Anchor to paymentDetailspayment•Payment
Details Session Payment Details The payment details used to process the transaction.
Show input fields
- Anchor to reasonreason•Payment
Session Rejection Reason Input! required The rejection reason.
Show input fields
Arguments
- •mutation
Resolves an open payment session. After the
mutation completes on a given payment session, anymutation attempts will fail. Subsequentmutation attempts will succeed, but theDetailsargument will be ignored.Show payload
- Anchor to authenticationauthentication•Payment
Session Three DSecure Authentication 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.
Show input fields
- •Date
Time The date and time when an authorized payment session expires.
- •ID!required
The payment session ID.
- Anchor to networkTransactionIdnetwork•String
Transaction Id The transaction ID issued by the network when processing the payment.
- Anchor to paymentDetailspayment•Payment
Details Session Payment Details The payment details used to process the transaction.
Show input fields
Arguments