Create a new Shop Pay payment request session.
Arguments
A payment request object.
A unique identifier for the payment request session.
Was this section helpful?
ShopPayPaymentRequestSessionCreatePayload returns
The new Shop Pay payment request session object.
Error codes for failed Shop Pay payment request session mutations.
Was this section helpful?
Hide code
Mutation reference
Copy
mutation shopPayPaymentRequestSessionCreate($paymentRequest: ShopPayPaymentRequestInput!, $sourceIdentifier: String!) {
shopPayPaymentRequestSessionCreate(paymentRequest: $paymentRequest, sourceIdentifier: $sourceIdentifier) {
shopPayPaymentRequestSession {
# ShopPayPaymentRequestSession fields
}
userErrors {
field
message
}
}
}
Hide code
Input
Copy
{
"paymentRequest": {
"deliveryMethods": [],
"discountCodes": [],
"discounts": [],
"lineItems": [],
"locale": "<your-locale>",
"paymentMethod": "<your-paymentMethod>",
"presentmentCurrency": "AED",
"selectedDeliveryMethodType": "PICKUP",
"shippingLines": [],
"subtotal": {},
"total": {},
"totalShippingPrice": {},
"totalTax": {}
},
"sourceIdentifier": "<your-sourceIdentifier>"
}
input ShopPayPaymentRequestInput {
deliveryMethods: [ShopPayPaymentRequestDeliveryMethodInput!]
discountCodes: [String!]
discounts: [ShopPayPaymentRequestDiscountInput!]
lineItems: [ShopPayPaymentRequestLineItemInput!]
locale: String!
paymentMethod: String
presentmentCurrency: CurrencyCode!
selectedDeliveryMethodType: ShopPayPaymentRequestDeliveryMethodType
shippingAddress: ShopPayPaymentRequestContactFieldInput
shippingLines: [ShopPayPaymentRequestShippingLineInput!]
subtotal: MoneyInput!
total: MoneyInput!
totalShippingPrice: ShopPayPaymentRequestTotalShippingPriceInput
totalTax: MoneyInput
}
input ShopPayPaymentRequestDeliveryMethodInput {