--- title: PaymentSession - Payments Apps API description: A unique payment transaction. api_version: 2025-10 api_name: payments-apps type: object api_type: graphql source_url: html: https://shopify.dev/docs/api/payments-apps/latest/objects/paymentsession md: https://shopify.dev/docs/api/payments-apps/latest/objects/paymentsession.md --- # Payment​Session object Requires `read_payment_sessions` access scope. A unique payment transaction. ## Fields * authorization​Expires​At [Date​Time](https://shopify.dev/docs/api/payments-apps/latest/scalars/DateTime) The date and time when an authorized payment session expires. * id [ID!](https://shopify.dev/docs/api/payments-apps/latest/scalars/ID) non-null A globally-unique ID. * next​Action [Payment​Session​Next​Action](https://shopify.dev/docs/api/payments-apps/latest/objects/PaymentSessionNextAction) The next action expected of the partner. * pending​Expires​At [Date​Time](https://shopify.dev/docs/api/payments-apps/latest/scalars/DateTime) The date and time when a pending payment session expires. * state [Payment​Session​States!](https://shopify.dev/docs/api/payments-apps/latest/unions/PaymentSessionStates) non-null Details about the payment state. *** ## Map No referencing types *** ## Mutations * [payment​Session​Confirm](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionConfirm) 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. * id [ID!](https://shopify.dev/docs/api/payments-apps/latest/scalars/ID) required ### Arguments The payment session ID. *** * [payment​Session​Modal](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionModal) 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. * id [ID!](https://shopify.dev/docs/api/payments-apps/latest/scalars/ID) required ### Arguments The payment session ID. * expires​At [Date​Time](https://shopify.dev/docs/api/payments-apps/latest/scalars/DateTime) The date and time the modal will expire, in UTC * action [Modal​Action!](https://shopify.dev/docs/api/payments-apps/latest/input-objects/ModalAction) required The buyer action and corresponding data that will be made available in the modal at runtime. *** * [payment​Session​Pending](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionPending) 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. * id [ID!](https://shopify.dev/docs/api/payments-apps/latest/scalars/ID) required ### Arguments The payment session ID. * pending​Expires​At [Date​Time!](https://shopify.dev/docs/api/payments-apps/latest/scalars/DateTime) required The date and time when the pending payment expires, recommended to be within 3 days. * reason [Payment​Session​State​Pending​Reason!](https://shopify.dev/docs/api/payments-apps/latest/enums/PaymentSessionStatePendingReason) required The reason the payment is pending. *** * [payment​Session​Redirect](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionRedirect) 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. * id [ID!](https://shopify.dev/docs/api/payments-apps/latest/scalars/ID) required ### Arguments The payment session ID. * redirect​Url [URL!](https://shopify.dev/docs/api/payments-apps/latest/scalars/URL) required The URL that Shopify will redirect the buyer to, for 3DS authentication. Applicable to payments with the credit card payment method only. *** * [payment​Session​Reject](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionReject) 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. * id [ID!](https://shopify.dev/docs/api/payments-apps/latest/scalars/ID) required ### Arguments The payment session ID. * reason [Payment​Session​Rejection​Reason​Input!](https://shopify.dev/docs/api/payments-apps/latest/input-objects/PaymentSessionRejectionReasonInput) required The rejection reason. * authentication [Payment​Session​Three​DSecure​Authentication](https://shopify.dev/docs/api/payments-apps/latest/input-objects/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. * payment​Details [Payment​Session​Payment​Details](https://shopify.dev/docs/api/payments-apps/latest/input-objects/PaymentSessionPaymentDetails) The payment details used to process the transaction. *** * [payment​Session​Resolve](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionResolve) 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. * id [ID!](https://shopify.dev/docs/api/payments-apps/latest/scalars/ID) required ### Arguments The payment session ID. * authorization​Expires​At [Date​Time](https://shopify.dev/docs/api/payments-apps/latest/scalars/DateTime) The date and time when an authorized payment session expires. * authentication [Payment​Session​Three​DSecure​Authentication](https://shopify.dev/docs/api/payments-apps/latest/input-objects/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. * network​Transaction​Id [String](https://shopify.dev/docs/api/payments-apps/latest/scalars/String) The transaction ID issued by the network when processing the payment. * payment​Details [Payment​Session​Payment​Details](https://shopify.dev/docs/api/payments-apps/latest/input-objects/PaymentSessionPaymentDetails) The payment details used to process the transaction. *** *** ## <\~> PaymentSession Mutations ### Mutated by * <\~>[payment​Session​Confirm](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionConfirm) * <\~>[payment​Session​Modal](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionModal) * <\~>[payment​Session​Pending](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionPending) * <\~>[payment​Session​Redirect](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionRedirect) * <\~>[payment​Session​Reject](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionReject) * <\~>[payment​Session​Resolve](https://shopify.dev/docs/api/payments-apps/latest/mutations/paymentSessionResolve)