Samsung Pay
Samsung Pay provides an in-app purchasing experience that allows customers with supported Samsung devices to pay with payment methods stored in their Samsung Pay app.
For more details on compatibility and availability, see our Samsung Pay support article.
Creating transactions
You can create a Samsung Pay transaction using the chargePaymentMethod
mutation while suppling an amount
and paymentMethodId
.
mutation
mutation ChargePaymentMethod($input: ChargePaymentMethodInput!) {chargePaymentMethod(input: $input) {transaction {idlegacyIdstatuspaymentMethodSnapshot {... on CreditCardDetails {origin {typedetails {... on SamsungPayOriginDetails {bin}}}}}}}}
variables
{"input": {"paymentMethodId": "id_of_payment_method","transaction": {"amount": "1.00",}}}
response
{"data": {"chargePaymentMethod": {"transaction": {"id": "id_of_transaction","legacyId": "legacy_id_of_transaction","status": "SUBMITTED_FOR_SETTLEMENT","paymentMethodSnapshot": {"origin": {"type": "SAMSUNG_PAY","details": {"bin": "bank_identification_number"}}}}}},"extensions": {"requestId": "a-uuid-for-the-request"}}
Vaulting Samsung Pay
Samsung Pay cards can only be saved to your Vault for specific use cases; see the support article for details.
If your use case is supported, you can store a customer's Samsung Pay card in your Vault in one of the following ways:
- Using the
vaultPaymentMethod
mutation - Including
vaultPaymentMethodAfterTransacting
in the input for thechargePaymentMethod
mutation