Skip to main content

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.

Getting started

You’ll need to follow these steps in the next sections to add Samsung Pay to your existing Braintree integration:

If you haven't completed a Braintree integration yet, we recommend following our Get Started guide to set up for credit card payments before adding Samsung Pay.

Configure Samsung Pay

In order to accept payments via Samsung Pay in sandbox or production, you will need to enable it in the Control Panel. All eligible merchant accounts will be enabled once you once you do the following:

  1. Log into either your sandbox Control Panel or your production Control Panel
  2. Click on the gear icon in the top right corner
  3. Click Processing from the drop-down menu
  4. Scroll to the Payment Methods section
  5. Next to Samsung Pay, click the toggle to turn it on

Integrate on your servers

Creating transactions

To create a Samsung Pay transaction, you need a payment method. To turn a Samsung Pay card into a payment method, please use tokenizeSamsungPayCard mutation. Now let's go through how to actually do a transaction.

mutation

mutation ChargePaymentMethod($input: ChargePaymentMethodInput!) {
chargePaymentMethod(input: $input) {
transaction {
id
createdAt
status
amount {
value
currencyCode
}
merchantAccountId
paymentMethodSnapshot {
... on CreditCardDetails {
brand
brandCode
last4
expirationMonth
expirationYear
cardholderName
origin {
type
details {
... on SamsungPayOriginDetails {
bin
}
}
}
}
}
processorResponse {
legacyCode
message
avsPostalCodeResponse
avsStreetAddressResponse
cvvResponse
}
}
}
}

variables

{
"input": {
"paymentMethodId": "tokensam_bd_y6jzc3_7jzgs9_gvvg3s_8rv8mg_hw2",
"transaction": {
"amount": "1.00",
"riskData": {
"customerBrowser": "netscap_1.0",
"customerIp": "8.8.8.8",
"deviceData": "android_v15.0_z2"
}
}
}
}

response

{
"data": {
"chargePaymentMethod": {
"transaction": {
"id": "dHJhbnNhY3Rpb25fcGNxcXJ0MnI",
"createdAt": "2022-09-15T05:52:21.000000Z",
"status": "SUBMITTED_FOR_SETTLEMENT",
"amount": {
"value": "1.00",
"currencyCode": "USD"
},
"merchantAccountId": "paypal",
"paymentMethodSnapshot": {
"brand": "Visa",
"brandCode": "VISA",
"last4": "5545",
"expirationMonth": "12",
"expirationYear": "2020",
"origin": {
"type": "SAMSUNG_PAY",
"details": {
"bin": "411111"
}
}
},
"processorResponse": {
"legacyCode": "1000",
"message": "Approved",
"avsPostalCodeResponse": "NOT_PROVIDED",
"avsStreetAddressResponse": "NOT_PROVIDED",
"cvvResponse": "NOT_PROVIDED"
}
}
}
},
"extensions": {
"requestId": "70b8eee4-f5d8-453d-a941-a0363922e68b"
}
}

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 Google Pay card in your Vault using one of the following mutations: