{"metadata":{"image":[],"title":"","description":""},"api":{"url":"/vaulted-shoppers","auth":"optional","settings":"","results":{"codes":[{"code":"","language":"text"}]},"method":"post","examples":{"codes":[]},"params":[]},"next":{"description":"","pages":[]},"title":"Create Vaulted Shopper","type":"endpoint","slug":"create-vaulted-shopper","excerpt":"","body":"The Create Vaulted Shopper request enables you to store a shopper's details (including payment info) securely in BlueSnap. BlueSnap will provide a token (`vaulted-shopper-id`) for that saved shopper.\n\nYou can then use the `vaulted-shopper-id` in order to complete payment transactions, improve the checkout experience for a returning shopper, and update the shopper's payment details. For an example of using the `vaulted-shopper-id` for a returning shopper, see [Returning shopper tutorial](doc:returning-shopper-tutorial).\n[block:callout]\n{\n \"type\": \"info\",\n \"body\": \"* Each vaulted shopper can have multiple credit cards and multiple ACH accounts.\\n* If you add a credit card to a vaulted shopper, BlueSnap will validate the card before adding it to the shopper. \\n* To create a shopper with wallet details for Masterpass or Visa Checkout, including the payment info and billing and shipping info, you will simply include the `walletId` in the request. For details, see:\\n * [Masterpass Guide](/docs/masterpass)\\n * [Visa Checkout Guide](/docs/visa-checkout)\"\n}\n[/block]\n<a class=\"btn btn-success\" href=\"#section-api-explorer-api-version-2-0-\" role=\"button\">Try it in the API Explorer</a>\n\n###Request Content\nSend a **[vaulted-shopper](doc:vaulted-shopper)** object with the following:\n `payment-sources` *container* optional (see [payment-sources](doc:payment-sources))\n `first-name` *string* <span style=\"color:#F37500\">**required** if `wallet-id` is not sent</span>\n `last-name` *string* <span style=\"color:#F37500\">**required** if `wallet-id` is not sent</span>\n `soft-descriptor` *string* optional\n `descriptor-phone-number` *string* optional\n `merchant-shopper-id` *string* optional\n `country` *string* optional\n `state` *string* optional\n `city` *string* optional\n `address` *string* optional\n `address2` *string* optional\n `email` *string* optional\n `zip` *string* optional\n `phone` *string* optional\n <span style=\"color:#F37500\">`company-name` </span> *string* **required** for Corporate ECP accounts\n `shopper-currency` *string* optional\n `shipping-contact-info` *container* optional (see [shipping-contact-info](doc:shipping-contact-info))\n `wallet-id` *long* optional Include if adding Masterpass or Visa Checkout wallet details\n `transaction-fraud-info` *container* optional (see [transaction-fraud-info](doc:transaction-fraud-info))\n `transaction-order-source` *string* optional\n `three-d-secure` *container* optional (see [three-d-secure](https://developers.bluesnap.com/v8976-XML/docs/three-d-secure))\n\n###Response Details\nThe response content depends on which version of the API you are using (see [Authentication & headers](/docs/authentication)), as follows:\n\n* **API version 3.0**\nIf successful, the response HTTP status code is 200 OK.\nIf you use ACH/ECP, the response includes the [ecp-details](doc:ecp-details) container, which replaces the ecp-info resource, allowing for multiple ACH accounts to be stored for the shopper.\n\n* **API version 2.0**\nIf successful, the response HTTP status code is 200 OK.\nThe response body includes the [vaulted-shopper](doc:vaulted-shopper) resource, which contains all details saved for that shopper.\nThe `vaulted-shopper-id` appears in the response body, as well as in the URL in the location header. In the example below, the `vaulted-shopper-id` is **20848977**.\n\n* **API version 1.0**\nIf successful, the response HTTP status code is 201 Created.\nThe `vaulted-shopper-id` appears in the URL in the location header. In the example below, the `vaulted-shopper-id` is **19549020**.\nThere is no content in the response body.\n\n<hr>\n\n##Examples\n\n###Request Examples\n[block:code]\n{\n \"codes\": [\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <descriptor-phone-number>5121231212</descriptor-phone-number>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <card-number>3411 1159 7241 002</card-number>\\n <security-code>1121</security-code>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"Create Vaulted Shopper Request: basic\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <card-number>4263982640269299</card-number>\\n <security-code>837</security-code>\\n <expiration-month>02</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n <billing-contact-info>\\n <first-name>billingFirstName</first-name>\\n <last-name>billingLastName</last-name>\\n <country>US</country>\\n <state>MA</state>\\n <address1>10 Main St</address1>\\n <address2>Apt 1</address2>\\n <zip>01752</zip>\\n </billing-contact-info>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with credit card and billing info\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <card-number>4263982640269299</card-number>\\n <security-code>837</security-code>\\n <expiration-month>02</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n <billing-contact-info>\\n <first-name>billingFirstName</first-name>\\n <last-name>billingLastName</last-name>\\n <country>US</country>\\n <state>MA</state>\\n <address1>10 Main St</address1>\\n <address2>Apt 1</address2>\\n <zip>01752</zip>\\n </billing-contact-info>\\n </credit-card-info>\\n </payment-sources>\\n <transaction-fraud-info>\\n <fraud-session-id>1234</fraud-session-id>\\n <shopper-ip-address>123.12.134.1</shopper-ip-address>\\n <company>company</company>\\n <shipping-contact-info>\\n <last-name>shippingFirstName</last-name>\\n <first-name>shippingLastName</first-name>\\n <country>US</country>\\n <state>AL</state>\\n <city>shippingCity</city>\\n <address1>shippingAddress1</address1>\\n <address2>shippingAddress2</address2>\\n <zip>shippingZip</zip>\\n </shipping-contact-info>\\n </transaction-fraud-info>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with credit card, billing info and fraud info\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <encrypted-card-number>$bsjs_1_0_3$B23uuxq8drUwOYZm3wZi+Qm69V5GPEt8PEio+Edwcm8akczQSK7odgLQH/Au+VqOCsGspW1Q9mPyQIzGLSZLVToAQVfq5C1ld+2ogIIsDL32Hd6IojboLyVlYT1FvPQoDyz19K6N0CUHh5uk0kCLuHSUyjvoJH38ojHZifbJSm/7S5vAtiuC3BJt2z8k9nauQaAXkbyoAYwrS1yDpqOt2k2lGhKcmdQ4ImDR0RL8m8xig6sFrki9oqo3Mju/M5r7wXXVTf7TMtWiQbzdfREOxKUnviXJZpncdHqVjj5GvPYun2qgopKVKr8F5+yd19TVW2gvA1kXBkXonFL9159Gxg==$zckJgo2i8jXDiAHwVVHBKypXFnWqF2e+6luBkmtQQRKniDXyXaalRVKLtYscBaGd$W7Ojqk1Q2iOJVeGL39RAsZTtfup3f1deSzvxrvC9rXA=</encrypted-card-number>\\n <encrypted-security-code>$bsjs_1_0_3$MB1nBpok/YkuWPG1/7e6dyFFhDPHB8p8E9Yo+0YHHV+xkHuzFKr02wAnE8PJ8QCzWH+2ctXy5FN6wLKjwFrfTOgy0BJ9k9+NDEe8mhsu66wMlyc3lnwrbvMRCWN1O+5gUNCFExj7B0mDtf4gtxecXs74KZ5l5dbpGWdKUk5i7OewWyTqsONbn9taLfVBOwuIOy2Jgi4fx+yB8Q05KdZeHSNSBJh8H/47AUNAn5dM+d9iO6yGQB3obzEzzR3UtHlkGR52ZsgbbFh0JMm9lBM2ClgYM8jvmQjS9HX2ojt1fkbhuPEb1IY/M498a+1wDPpI4aMfDxO1lSpJneRSpY5k4g==$XaKq1NbPcS0iHy9N9jHekEIByHYS4G3wJXlC9EQjAGM=$BJn6X6mBYGUo8Eoq4RQz69gsi4Azl8jT973mNpG9Yuo=</encrypted-security-code>\\n <card-type>VISA</card-type>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with encrypted card details\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <wallet-id>21</wallet-id>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with wallet ID\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <payment-sources>\\n <credit-card-info>\\n <pf-token>9688f4f6945f615b1ab6954ceb5dbf67f63d6b41fa27dbff6ac342cff9bf50fc_</pf-token>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with Hosted Payment Fields token\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <soft-descriptor>MYCOMPANY</soft-descriptor>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <card-number>4263982640269299</card-number>\\n <security-code>837</security-code>\\n <expiration-month>02</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with credit card and soft descriptor\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>Jane</first-name>\\n <last-name>Shopper</last-name>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <payment-sources>\\n <sepa-direct-debit-info>\\n <sepa-direct-debit>\\n \\t<iban>DE09100100101234567893</iban>\\n </sepa-direct-debit>\\n </sepa-direct-debit-info>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with SEPA Direct Debit\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <company-name>MyCo LLC</company-name>\\n <payment-sources>\\n <ecp-details>\\n <ecp>\\n <account-number>4099999992</account-number>\\n <routing-number>011075150</routing-number>\\n <account-type>CORPORATE_CHECKING</account-type>\\n </ecp>\\n </ecp-details>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with ACH/ECP\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <company-name>Harel LLC</company-name>\\n <payment-sources>\\n <ecp-details>\\n \\t <billing-contact-info>\\n \\t \\t<company-name>Scott LLC</company-name>\\n \\t </billing-contact-info>\\n <ecp>\\n <account-number>4099999992</account-number>\\n <routing-number>011075150</routing-number>\\n <account-type>CORPORATE_CHECKING</account-type>\\n </ecp>\\n </ecp-details>\\n <ecp-details>\\n <ecp>\\n <account-number>4099999993</account-number>\\n <routing-number>011075151</routing-number>\\n <account-type>CONSUMER_SAVINGS</account-type>\\n </ecp>\\n </ecp-details>\\n </payment-sources>\\n</vaulted-shopper>'\",\n \"language\": \"curl\",\n \"name\": \"with multiple ACH accounts\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <descriptor-phone-number>98765</descriptor-phone-number>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <transaction-order-source>MOTO</transaction-order-source>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <card-number>4111111111111111</card-number>\\n <security-code>111</security-code>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>\",\n \"language\": \"curl\",\n \"name\": \"with transaction order source: MOTO\"\n },\n {\n \"code\": \"curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \\\\\\n-H 'Content-Type: application/xml' \\\\\\n-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \\\\\\n-d '\\n<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<vaulted-shopper\\n xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <descriptor-phone-number>98765</descriptor-phone-number>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <encrypted-card-number>$bsjs_1_0_3$B23uuxq8drUwOYZm3wZi+Qm69V5GPEt8PEio+Edwcm8akczQSK7odgLQH/Au+VqOCsGspW1Q9mPyQIzGLSZLVToAQVfq5C1ld+2ogIIsDL32Hd6IojboLyVlYT1FvPQoDyz19K6N0CUHh5uk0kCLuHSUyjvoJH38ojHZifbJSm/7S5vAtiuC3BJt2z8k9nauQaAXkbyoAYwrS1yDpqOt2k2lGhKcmdQ4ImDR0RL8m8xig6sFrki9oqo3Mju/M5r7wXXVTf7TMtWiQbzdfREOxKUnviXJZpncdHqVjj5GvPYun2qgopKVKr8F5+yd19TVW2gvA1kXBkXonFL9159Gxg==$zckJgo2i8jXDiAHwVVHBKypXFnWqF2e+6luBkmtQQRKniDXyXaalRVKLtYscBaGd$W7Ojqk1Q2iOJVeGL39RAsZTtfup3f1deSzvxrvC9rXA=</encrypted-card-number>\\n <encrypted-security-code>$bsjs_1_0_3$MB1nBpok/YkuWPG1/7e6dyFFhDPHB8p8E9Yo+0YHHV+xkHuzFKr02wAnE8PJ8QCzWH+2ctXy5FN6wLKjwFrfTOgy0BJ9k9+NDEe8mhsu66wMlyc3lnwrbvMRCWN1O+5gUNCFExj7B0mDtf4gtxecXs74KZ5l5dbpGWdKUk5i7OewWyTqsONbn9taLfVBOwuIOy2Jgi4fx+yB8Q05KdZeHSNSBJh8H/47AUNAn5dM+d9iO6yGQB3obzEzzR3UtHlkGR52ZsgbbFh0JMm9lBM2ClgYM8jvmQjS9HX2ojt1fkbhuPEb1IY/M498a+1wDPpI4aMfDxO1lSpJneRSpY5k4g==$XaKq1NbPcS0iHy9N9jHekEIByHYS4G3wJXlC9EQjAGM=$BJn6X6mBYGUo8Eoq4RQz69gsi4Azl8jT973mNpG9Yuo=</encrypted-security-code>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n </credit-card-info>\\n </payment-sources>\\n <three-d-secure>\\n <three-d-secure-result-token>eyJhbGciOiJIUzI1NiJ9.eyJp....</three-d-secure-result-token>\\n </three-d-secure>\\n</vaulted-shopper>\",\n \"language\": \"curl\",\n \"name\": \"with encrypted card details and 3DS\"\n }\n ]\n}\n[/block]\n###Response Examples\n**For API Version 3.0**\n[block:code]\n{\n \"codes\": [\n {\n \"code\": \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"yes\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <vaulted-shopper-id>19574796</vaulted-shopper-id>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <company-name></company-name>\\n <soft-descriptor>BLS*BS</soft-descriptor>\\n <descriptor-phone-number>5121231212</descriptor-phone-number>\\n <shopper-currency>USD</shopper-currency>\\n <payment-sources>\\n <credit-card-info>\\n <billing-contact-info>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <city></city>\\n <zip>12345</zip>\\n <country>us</country>\\n </billing-contact-info>\\n <credit-card>\\n <card-last-four-digits>1002</card-last-four-digits>\\n <card-type>AMEX</card-type>\\n <card-sub-type>CREDIT</card-sub-type>\\n <bin-category>CONSUMER</bin-category>\\n <card-regulated>N</card-regulated>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n <issuing-country-code>US</issuing-country-code>\\n </credit-card>\\n <processing-info>\\n <cvv-response-code>MA</cvv-response-code>\\n <avs-response-code-zip>M</avs-response-code-zip>\\n <avs-response-code-address>M</avs-response-code-address>\\n <avs-response-code-name>U</avs-response-code-name>\\n </processing-info>\\n <date-created>09/30/2020</date-created>\\n <time-created>05:59:40</time-created>\\n </credit-card-info>\\n </payment-sources>\\n <fraud-result-info>\\n <device-data-collector>N</device-data-collector>\\n </fraud-result-info>\\n <date-created>09/22/2020</date-created>\\n <time-created>13:41:10</time-created>\\n</vaulted-shopper>\",\n \"language\": \"xml\",\n \"name\": \"Create Vaulted Shopper Response: 200 OK\"\n },\n {\n \"code\": \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"yes\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <vaulted-shopper-id>19574596</vaulted-shopper-id>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <company-name></company-name>\\n <soft-descriptor>BLS*BS</soft-descriptor>\\n <descriptor-phone-number>98765</descriptor-phone-number>\\n <shopper-currency>USD</shopper-currency>\\n <payment-sources>\\n <credit-card-info>\\n <billing-contact-info>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <city></city>\\n <zip>12345</zip>\\n <country>us</country>\\n </billing-contact-info>\\n <credit-card>\\n <card-last-four-digits>1111</card-last-four-digits>\\n <card-type>VISA</card-type>\\n <card-sub-type>CREDIT</card-sub-type>\\n <bin-category>CONSUMER</bin-category>\\n <card-regulated>N</card-regulated>\\n <issuing-bank>JPMORGAN CHASE BANK, N.A.</issuing-bank>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n <issuing-country-code>US</issuing-country-code>\\n </credit-card>\\n <processing-info>\\n <cvv-response-code>MA</cvv-response-code>\\n <avs-response-code-zip>M</avs-response-code-zip>\\n <avs-response-code-address>M</avs-response-code-address>\\n <avs-response-code-name>U</avs-response-code-name>\\n <network-transaction-id>759205438350294</network-transaction-id>\\n </processing-info>\\n <date-created>09/30/2020</date-created>\\n <time-created>05:59:40</time-created>\\n </credit-card-info>\\n </payment-sources>\\n <fraud-result-info>\\n <device-data-collector>N</device-data-collector>\\n </fraud-result-info>\\n <transaction-order-source>MOTO</transaction-order-source>\\n <date-created>09/22/2020</date-created>\\n <time-created>13:41:10</time-created>\\n</vaulted-shopper>\",\n \"language\": \"xml\",\n \"name\": \"with MOTO and NTI\"\n },\n {\n \"code\": \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"yes\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <vaulted-shopper-id>19574596</vaulted-shopper-id>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <soft-descriptor>BLS*BS</soft-descriptor>\\n <shopper-currency>USD</shopper-currency>\\n <payment-sources>\\n <credit-card-info>\\n <billing-contact-info>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <city></city>\\n <zip>12345</zip>\\n <country>us</country>\\n </billing-contact-info>\\n <credit-card>\\n <card-last-four-digits>1111</card-last-four-digits>\\n <card-type>VISA</card-type>\\n <card-sub-type>CREDIT</card-sub-type>\\n <bin-category>CONSUMER</bin-category>\\n <card-regulated>N</card-regulated>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n <issuing-country-code>US</issuing-country-code>\\n </credit-card>\\n <processing-info>\\n <cvv-response-code>MA</cvv-response-code>\\n <avs-response-code-zip>M</avs-response-code-zip>\\n <avs-response-code-address>M</avs-response-code-address>\\n <avs-response-code-name>U</avs-response-code-name>\\n <network-transaction-id>759205438350294</network-transaction-id>\\n </processing-info>\\n <date-created>09/30/2020</date-created>\\n <time-created>05:59:40</time-created>\\n </credit-card-info>\\n </payment-sources>\\n <three-d-secure>\\n <authentication-result>AUTHENTICATION_SUCCEEDED</authentication-result>\\n </three-d-secure>\\n <date-created>09/22/2020</date-created>\\n <time-created>13:41:10</time-created>\\n</vaulted-shopper>\",\n \"language\": \"xml\",\n \"name\": \"Create Vaulted Shopper with 3DS Response\"\n },\n {\n \"code\": \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"yes\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <vaulted-shopper-id>19569774</vaulted-shopper-id>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <company-name>Harel LLC</company-name>\\n <shopper-currency>USD</shopper-currency>\\n <payment-sources>\\n <ecp-details>\\n <billing-contact-info>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <city></city>\\n <company-name>Scott LLC</company-name>\\n </billing-contact-info>\\n <ecp>\\n <account-type>CORPORATE_CHECKING</account-type>\\n <public-account-number>99992</public-account-number>\\n <public-routing-number>75150</public-routing-number>\\n </ecp>\\n <date-created>09/30/2020</date-created>\\n <time-created>05:48:18</time-created>\\n </ecp-details>\\n <ecp-details>\\n <billing-contact-info>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <company-name>Harel LLC</company-name>\\n </billing-contact-info>\\n <ecp>\\n <account-type>CONSUMER_SAVINGS</account-type>\\n <public-account-number>99993</public-account-number>\\n <public-routing-number>75151</public-routing-number>\\n </ecp>\\n <date-created>09/30/2020</date-created>\\n <time-created>05:59:40</time-created>\\n </ecp-details>\\n <fraud-result-info>\\n <device-data-collector>Y</device-data-collector>\\n </fraud-result-info>\\n </payment-sources>\\n <date-created>09/22/2020</date-created>\\n <time-created>13:41:10</time-created>\\n</vaulted-shopper>\",\n \"language\": \"xml\",\n \"name\": \"with ACH/ECP\"\n },\n {\n \"code\": \"<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <vaulted-shopper-id>19582620</vaulted-shopper-id>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <country>us</country>\\n <zip>12345</zip>\\n <phone>1234567890</phone>\\n <company-name></company-name>\\n <soft-descriptor>BLS*BS</soft-descriptor>\\n <descriptor-phone-number>98765</descriptor-phone-number>\\n <shopper-currency>USD</shopper-currency>\\n <payment-sources>\\n <credit-card-info>\\n <billing-contact-info>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <city></city>\\n <zip>12345</zip>\\n <country>us</country>\\n </billing-contact-info>\\n <credit-card>\\n <card-last-four-digits>1091</card-last-four-digits>\\n <card-type>VISA</card-type>\\n <card-sub-type>CREDIT</card-sub-type>\\n <bin-category>CONSUMER</bin-category>\\n <expiration-month>07</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n <processing-info>\\n <cvv-response-code>NR</cvv-response-code>\\n <avs-response-code-zip>N</avs-response-code-zip>\\n <avs-response-code-address>N</avs-response-code-address>\\n <avs-response-code-name>U</avs-response-code-name>\\n <network-transaction-id>020020314061884</network-transaction-id>\\n </processing-info>\\n <date-created>09/30/2020</date-created>\\n <time-created>05:59:40</time-created>\\n </credit-card-info>\\n </payment-sources>\\n <fraud-result-info>\\n <device-data-collector>N</device-data-collector>\\n </fraud-result-info>\\n <three-d-secure>\\n <authentication-result>AUTHENTICATION_SUCCEEDED</authentication-result>\\n </three-d-secure>\\n <date-created>09/22/2020</date-created>\\n <time-created>13:41:10</time-created>\\n</vaulted-shopper>\",\n \"language\": \"xml\",\n \"name\": \"with encrypted card details and 3DS\"\n }\n ]\n}\n[/block]\n**Responses for previous API versions**\n[block:code]\n{\n \"codes\": [\n {\n \"code\": \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" standalone=\\\"yes\\\"?>\\n<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <vaulted-shopper-id>20848977</vaulted-shopper-id>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <shopper-currency>USD</shopper-currency>\\n <payment-sources>\\n <credit-card-info>\\n <billing-contact-info>\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <city></city>\\n <company-name>CompanyName</company-name>\\n </billing-contact-info>\\n <credit-card>\\n <card-last-four-digits>9299</card-last-four-digits>\\n <card-type>VISA</card-type>\\n <card-sub-type>CREDIT</card-sub-type>\\n <card-category>CLASSIC</card-category>\\n <expiration-month>02</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n <processing-info>\\n <cvv-response-code>MA</cvv-response-code>\\n <avs-response-code-zip>U</avs-response-code-zip>\\n <avs-response-code-address>U</avs-response-code-address>\\n <avs-response-code-name>U</avs-response-code-name>\\n </processing-info>\\n <fraud-result-info>\\n <device-data-collector>N</device-data-collector>\\n </fraud-result-info>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>\",\n \"language\": \"xml\",\n \"name\": \"200 Created - API v2.0\"\n },\n {\n \"code\": \"HTTP/ 1.1 201 Created\\nLocation: https://sandbox.bluesnap.com/services/2/vaulted-shoppers/19549020\",\n \"language\": \"http\",\n \"name\": \"201 Created - API v1.0\"\n }\n ]\n}\n[/block]\n<a class=\"btn btn-primary\" href=\"#\" role=\"button\">Back to Top</a>\n\n<hr>\n\n##Example Descriptions\n\n###Basic Create Vaulted Shopper\nThis example shows a basic Create Vaulted Shopper request that saves the shopper in BlueSnap without any information about the shopper's payment methods.\n\n###Create Vaulted Shopper with credit card\nTo save credit card information for the shopper, you'll need to include the `credit-card-info` property within the `payment-sources` resource in your request. See [credit-card-info](doc:credit-card-info). Note that you must meet specific [PCI compliance](/docs/pci-compliance) requirements in order to send unencrypted card details.\n\nAbove is an example of a request with an unencrypted credit card number.\n\n###Create Vaulted Shopper with credit card and billing info\nOptionally, you can include the shopper's billing info in the `credit-card-info` property within the `payment-sources` resource in your request. See [credit-card-info](doc:credit-card-info). This can help improve the experience for returning shoppers, because you can save time by pre-populating the checkout form with their billing details.\n\nAbove is an example of a request with credit card details along with billing info.\n\n###Create Vaulted Shopper with credit card, billing info and fraud info\nOptionally, you can include fraud info in the request, so that your fraud checks can run and verify that you are not saving a shopper with payment info that is suspected to be fraudulent.\n\nAbove is an example of a request with that includes fraud info such as the shopper's IP address and shipping address.\n\n###Create Vaulted Shopper with encrypted credit card\nYour [PCI compliance](/docs/pci-compliance) requirements and API permission level may require that you send credit card data in encrypted format only. To do this, you'll need to include the`encrypted-card-number` and `encrypted-security-code` properties within the [credit-card-info](doc:credit-card-info) resource in your request.\n\nAbove is an example of a request with an encrypted credit card number.\n\n###Create Vaulted Shopper with encrypted credit card\nYour [PCI compliance](/docs/pci-compliance) requirements and API permission level may require that you send credit card data in encrypted format only. To do this, you'll need to include the`encrypted-card-number` and `encrypted-security-code` properties within the [credit-card-info](doc:credit-card-info) resource in your request.\n\nAbove is an example of a request with an encrypted credit card number.\n\n###Create Vaulted Shopper with wallet\nTo create a shopper with wallet details, including the payment info and billing and shipping info, you will simply include the `wallet-id` in the request. No other elements are required.\n\nFor details, see:\n * [Masterpass Guide](/docs/masterpass)\n * [Visa Checkout Guide](/docs/visa-checkout)\n\nAbove is an example of a request with a wallet ID.\n\n###Create Vaulted Shopper with Hosted Payment Fields token\nIf you are using BlueSnap's [Hosted Payment Fields](/v8976-Tools/docs/hosted-payment-fields), you can save the shopper's payment information from the Hosted Payment Fields by including the token within the `pf-token` property in your request.\n\nAbove is an example of a request with the Hosted Payment Fields token.\n\n###Create Vaulted Shopper with credit card and soft descriptor\nThe above example shows how to create a shopper with a credit card and soft descriptor, which is the description that may appear on the shopper's bank statement when BlueSnap validates the card before adding it to the shopper. \n\n###Create Vaulted Shopper with SEPA Direct Debit \nThe above example shows a Create Vaulted Shopper request with bank account details for the [SEPA Direct Debit](/docs/sepa-direct-debit) payment method. Include the shopper's bank account details within `payment-sources` > `sepa-direct-debit-info` > `sepa-direct-debit`. The shopper may have more than one saved bank accounts with the SEPA Direct Debit payment method. \n\n###Create Vaulted Shopper with ACH/ECP info\nTo save ACH/ECP account info for a shopper, include the [ecp-info](doc:ecp-info) element in your request. Only one ACH/ECP account can be saved per shopper.\n\n###Create Vaulted Shopper with multiple ACH accounts\nThe above example shows a Create Vaulted Shopper request for shoppers who have multiple ACH accounts. Include the shopper's account details within `payment-sources` > `ecp-details`.\n\n###Create Vaulted Shopper with MOTO and NTI\nThe `transaction-order-source` identifies the order as Mail Order Telephone Order. The response includes the `network-transaction-id` for the transaction.\n\n###Create Vaulted Shopper with 3DS\nThe response includes the 3DS result and the NTI (`networkTransactionId`) for the transaction. Save this for future transactions.\n\n<br>\n<a class=\"btn btn-primary\" href=\"#\" role=\"button\">Back to Top</a>\n\n<hr>\n\n##API Explorer (API version 2.0)\nTo test out a call, enter the XML portion of the request below and then click **Try it!**\n\n**Tip**: Copy the XML portion from one of the example requests above, or use the XML code below as a starting point. You can enter different parameters and test credit card numbers to see how your test scenario would work. *The request headers, including authorization, are already built in for you in this test area, so you should not include them here.*\n[block:code]\n{\n \"codes\": [\n {\n \"code\": \"<vaulted-shopper xmlns=\\\"http://ws.plimus.com\\\">\\n <first-name>FirstName</first-name>\\n <last-name>LastName</last-name>\\n <payment-sources>\\n <credit-card-info>\\n <credit-card>\\n <card-number>4263982640269299</card-number>\\n <security-code>837</security-code>\\n <expiration-month>02</expiration-month>\\n <expiration-year>2023</expiration-year>\\n </credit-card>\\n </credit-card-info>\\n </payment-sources>\\n</vaulted-shopper>\",\n \"language\": \"xml\"\n }\n ]\n}\n[/block]","updates":[],"order":0,"isReference":true,"hidden":false,"sync_unique":"","link_url":"","link_external":false,"_id":"5ff4b747849e1b03c50684ac","project":"57336fd5a6a9c40e00e13a0b","version":{"version":"8976-XML","version_clean":"8976.0.0-XML","codename":"3.36.1 Release","is_stable":false,"is_beta":false,"is_hidden":false,"is_deprecated":false,"categories":["5ff4b747849e1b03c5068409","5ff4b747849e1b03c506840a","5ff4b747849e1b03c506840b","5ff4b747849e1b03c506840c","5ff4b747849e1b03c506840d","5ff4b747849e1b03c506840e","5ff4b747849e1b03c506840f","5ff4b747849e1b03c5068410","5ff4b747849e1b03c5068411","5ff4b747849e1b03c5068412","5ff4b747849e1b03c5068413","5ff4b747849e1b03c5068414","5ff4b747849e1b03c5068415","5ff4b747849e1b03c5068416","5ff4b747849e1b03c5068417","5ff4b747849e1b03c5068418","5ff4b747849e1b03c5068419","5ff4b747849e1b03c506841a","5ff4b747849e1b03c506841b","5ff4b747849e1b03c506841c"],"_id":"5ff4b747849e1b03c50684c7","project":"57336fd5a6a9c40e00e13a0b","__v":0,"forked_from":"5fd26704abd1b6004f12d72c","createdAt":"2018-04-24T15:24:22.608Z","releaseDate":"2018-04-24T15:24:22.608Z"},"category":{"sync":{"isSync":false,"url":""},"pages":[],"title":"Vaulted Shoppers","slug":"vaulted-shopper-service","order":10,"from_sync":false,"reference":true,"_id":"5ff4b747849e1b03c5068410","version":"5ff4b747849e1b03c50684c7","project":"57336fd5a6a9c40e00e13a0b","createdAt":"2015-10-19T18:31:30.299Z","__v":0},"user":"5beb1b96bc2003003ecd645e","createdAt":"2019-07-24T15:38:44.595Z","__v":0,"parentDoc":null}
postCreate Vaulted Shopper
Definition
Documentation
The Create Vaulted Shopper request enables you to store a shopper's details (including payment info) securely in BlueSnap. BlueSnap will provide a token (vaulted-shopper-id
) for that saved shopper.
You can then use the vaulted-shopper-id
in order to complete payment transactions, improve the checkout experience for a returning shopper, and update the shopper's payment details. For an example of using the vaulted-shopper-id
for a returning shopper, see Returning shopper tutorial.
- Each vaulted shopper can have multiple credit cards and multiple ACH accounts.
- If you add a credit card to a vaulted shopper, BlueSnap will validate the card before adding it to the shopper.
- To create a shopper with wallet details for Masterpass or Visa Checkout, including the payment info and billing and shipping info, you will simply include the
walletId
in the request. For details, see:
Request Content
Send a vaulted-shopper object with the following:
payment-sources
container optional (see payment-sources)
first-name
string required if wallet-id
is not sent
last-name
string required if wallet-id
is not sent
soft-descriptor
string optional
descriptor-phone-number
string optional
merchant-shopper-id
string optional
country
string optional
state
string optional
city
string optional
address
string optional
address2
string optional
email
string optional
zip
string optional
phone
string optional
company-name
string required for Corporate ECP accounts
shopper-currency
string optional
shipping-contact-info
container optional (see shipping-contact-info)
wallet-id
long optional Include if adding Masterpass or Visa Checkout wallet details
transaction-fraud-info
container optional (see transaction-fraud-info)
transaction-order-source
string optional
three-d-secure
container optional (see three-d-secure)
Response Details
The response content depends on which version of the API you are using (see Authentication & headers), as follows:
API version 3.0
If successful, the response HTTP status code is 200 OK.
If you use ACH/ECP, the response includes the ecp-details container, which replaces the ecp-info resource, allowing for multiple ACH accounts to be stored for the shopper.API version 2.0
If successful, the response HTTP status code is 200 OK.
The response body includes the vaulted-shopper resource, which contains all details saved for that shopper.
Thevaulted-shopper-id
appears in the response body, as well as in the URL in the location header. In the example below, thevaulted-shopper-id
is 20848977.API version 1.0
If successful, the response HTTP status code is 201 Created.
Thevaulted-shopper-id
appears in the URL in the location header. In the example below, thevaulted-shopper-id
is 19549020.
There is no content in the response body.
Examples
Request Examples
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<descriptor-phone-number>5121231212</descriptor-phone-number>
<zip>12345</zip>
<phone>1234567890</phone>
<payment-sources>
<credit-card-info>
<credit-card>
<card-number>3411 1159 7241 002</card-number>
<security-code>1121</security-code>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<payment-sources>
<credit-card-info>
<credit-card>
<card-number>4263982640269299</card-number>
<security-code>837</security-code>
<expiration-month>02</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
<billing-contact-info>
<first-name>billingFirstName</first-name>
<last-name>billingLastName</last-name>
<country>US</country>
<state>MA</state>
<address1>10 Main St</address1>
<address2>Apt 1</address2>
<zip>01752</zip>
</billing-contact-info>
</credit-card-info>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<payment-sources>
<credit-card-info>
<credit-card>
<card-number>4263982640269299</card-number>
<security-code>837</security-code>
<expiration-month>02</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
<billing-contact-info>
<first-name>billingFirstName</first-name>
<last-name>billingLastName</last-name>
<country>US</country>
<state>MA</state>
<address1>10 Main St</address1>
<address2>Apt 1</address2>
<zip>01752</zip>
</billing-contact-info>
</credit-card-info>
</payment-sources>
<transaction-fraud-info>
<fraud-session-id>1234</fraud-session-id>
<shopper-ip-address>123.12.134.1</shopper-ip-address>
<company>company</company>
<shipping-contact-info>
<last-name>shippingFirstName</last-name>
<first-name>shippingLastName</first-name>
<country>US</country>
<state>AL</state>
<city>shippingCity</city>
<address1>shippingAddress1</address1>
<address2>shippingAddress2</address2>
<zip>shippingZip</zip>
</shipping-contact-info>
</transaction-fraud-info>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<payment-sources>
<credit-card-info>
<credit-card>
<encrypted-card-number>$bsjs_1_0_3$B23uuxq8drUwOYZm3wZi+Qm69V5GPEt8PEio+Edwcm8akczQSK7odgLQH/Au+VqOCsGspW1Q9mPyQIzGLSZLVToAQVfq5C1ld+2ogIIsDL32Hd6IojboLyVlYT1FvPQoDyz19K6N0CUHh5uk0kCLuHSUyjvoJH38ojHZifbJSm/7S5vAtiuC3BJt2z8k9nauQaAXkbyoAYwrS1yDpqOt2k2lGhKcmdQ4ImDR0RL8m8xig6sFrki9oqo3Mju/M5r7wXXVTf7TMtWiQbzdfREOxKUnviXJZpncdHqVjj5GvPYun2qgopKVKr8F5+yd19TVW2gvA1kXBkXonFL9159Gxg==$zckJgo2i8jXDiAHwVVHBKypXFnWqF2e+6luBkmtQQRKniDXyXaalRVKLtYscBaGd$W7Ojqk1Q2iOJVeGL39RAsZTtfup3f1deSzvxrvC9rXA=</encrypted-card-number>
<encrypted-security-code>$bsjs_1_0_3$MB1nBpok/YkuWPG1/7e6dyFFhDPHB8p8E9Yo+0YHHV+xkHuzFKr02wAnE8PJ8QCzWH+2ctXy5FN6wLKjwFrfTOgy0BJ9k9+NDEe8mhsu66wMlyc3lnwrbvMRCWN1O+5gUNCFExj7B0mDtf4gtxecXs74KZ5l5dbpGWdKUk5i7OewWyTqsONbn9taLfVBOwuIOy2Jgi4fx+yB8Q05KdZeHSNSBJh8H/47AUNAn5dM+d9iO6yGQB3obzEzzR3UtHlkGR52ZsgbbFh0JMm9lBM2ClgYM8jvmQjS9HX2ojt1fkbhuPEb1IY/M498a+1wDPpI4aMfDxO1lSpJneRSpY5k4g==$XaKq1NbPcS0iHy9N9jHekEIByHYS4G3wJXlC9EQjAGM=$BJn6X6mBYGUo8Eoq4RQz69gsi4Azl8jT973mNpG9Yuo=</encrypted-security-code>
<card-type>VISA</card-type>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<?xml version="1.0" encoding="UTF-8"?>
<vaulted-shopper xmlns="http://ws.plimus.com">
<wallet-id>21</wallet-id>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<?xml version="1.0" encoding="UTF-8"?>
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<payment-sources>
<credit-card-info>
<pf-token>9688f4f6945f615b1ab6954ceb5dbf67f63d6b41fa27dbff6ac342cff9bf50fc_</pf-token>
</credit-card-info>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<soft-descriptor>MYCOMPANY</soft-descriptor>
<payment-sources>
<credit-card-info>
<credit-card>
<card-number>4263982640269299</card-number>
<security-code>837</security-code>
<expiration-month>02</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<?xml version="1.0" encoding="UTF-8"?>
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>Jane</first-name>
<last-name>Shopper</last-name>
<zip>12345</zip>
<phone>1234567890</phone>
<payment-sources>
<sepa-direct-debit-info>
<sepa-direct-debit>
<iban>DE09100100101234567893</iban>
</sepa-direct-debit>
</sepa-direct-debit-info>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<?xml version="1.0" encoding="UTF-8"?>
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<zip>12345</zip>
<phone>1234567890</phone>
<company-name>MyCo LLC</company-name>
<payment-sources>
<ecp-details>
<ecp>
<account-number>4099999992</account-number>
<routing-number>011075150</routing-number>
<account-type>CORPORATE_CHECKING</account-type>
</ecp>
</ecp-details>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<?xml version="1.0" encoding="UTF-8"?>
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<zip>12345</zip>
<phone>1234567890</phone>
<company-name>Harel LLC</company-name>
<payment-sources>
<ecp-details>
<billing-contact-info>
<company-name>Scott LLC</company-name>
</billing-contact-info>
<ecp>
<account-number>4099999992</account-number>
<routing-number>011075150</routing-number>
<account-type>CORPORATE_CHECKING</account-type>
</ecp>
</ecp-details>
<ecp-details>
<ecp>
<account-number>4099999993</account-number>
<routing-number>011075151</routing-number>
<account-type>CONSUMER_SAVINGS</account-type>
</ecp>
</ecp-details>
</payment-sources>
</vaulted-shopper>'
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<?xml version="1.0" encoding="UTF-8"?>
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<descriptor-phone-number>98765</descriptor-phone-number>
<zip>12345</zip>
<phone>1234567890</phone>
<transaction-order-source>MOTO</transaction-order-source>
<payment-sources>
<credit-card-info>
<credit-card>
<card-number>4111111111111111</card-number>
<security-code>111</security-code>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</payment-sources>
</vaulted-shopper>
curl -v -X POST https://sandbox.bluesnap.com/services/2/vaulted-shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<?xml version="1.0" encoding="UTF-8"?>
<vaulted-shopper
xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<descriptor-phone-number>98765</descriptor-phone-number>
<zip>12345</zip>
<phone>1234567890</phone>
<payment-sources>
<credit-card-info>
<credit-card>
<encrypted-card-number>$bsjs_1_0_3$B23uuxq8drUwOYZm3wZi+Qm69V5GPEt8PEio+Edwcm8akczQSK7odgLQH/Au+VqOCsGspW1Q9mPyQIzGLSZLVToAQVfq5C1ld+2ogIIsDL32Hd6IojboLyVlYT1FvPQoDyz19K6N0CUHh5uk0kCLuHSUyjvoJH38ojHZifbJSm/7S5vAtiuC3BJt2z8k9nauQaAXkbyoAYwrS1yDpqOt2k2lGhKcmdQ4ImDR0RL8m8xig6sFrki9oqo3Mju/M5r7wXXVTf7TMtWiQbzdfREOxKUnviXJZpncdHqVjj5GvPYun2qgopKVKr8F5+yd19TVW2gvA1kXBkXonFL9159Gxg==$zckJgo2i8jXDiAHwVVHBKypXFnWqF2e+6luBkmtQQRKniDXyXaalRVKLtYscBaGd$W7Ojqk1Q2iOJVeGL39RAsZTtfup3f1deSzvxrvC9rXA=</encrypted-card-number>
<encrypted-security-code>$bsjs_1_0_3$MB1nBpok/YkuWPG1/7e6dyFFhDPHB8p8E9Yo+0YHHV+xkHuzFKr02wAnE8PJ8QCzWH+2ctXy5FN6wLKjwFrfTOgy0BJ9k9+NDEe8mhsu66wMlyc3lnwrbvMRCWN1O+5gUNCFExj7B0mDtf4gtxecXs74KZ5l5dbpGWdKUk5i7OewWyTqsONbn9taLfVBOwuIOy2Jgi4fx+yB8Q05KdZeHSNSBJh8H/47AUNAn5dM+d9iO6yGQB3obzEzzR3UtHlkGR52ZsgbbFh0JMm9lBM2ClgYM8jvmQjS9HX2ojt1fkbhuPEb1IY/M498a+1wDPpI4aMfDxO1lSpJneRSpY5k4g==$XaKq1NbPcS0iHy9N9jHekEIByHYS4G3wJXlC9EQjAGM=$BJn6X6mBYGUo8Eoq4RQz69gsi4Azl8jT973mNpG9Yuo=</encrypted-security-code>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</payment-sources>
<three-d-secure>
<three-d-secure-result-token>eyJhbGciOiJIUzI1NiJ9.eyJp....</three-d-secure-result-token>
</three-d-secure>
</vaulted-shopper>
<vaulted-shopper xmlns="http://ws.plimus.com">
<vaulted-shopper-id>19574796</vaulted-shopper-id>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<zip>12345</zip>
<phone>1234567890</phone>
<company-name></company-name>
<soft-descriptor>BLS*BS</soft-descriptor>
<descriptor-phone-number>5121231212</descriptor-phone-number>
<shopper-currency>USD</shopper-currency>
<payment-sources>
<credit-card-info>
<billing-contact-info>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<city></city>
<zip>12345</zip>
<country>us</country>
</billing-contact-info>
<credit-card>
<card-last-four-digits>1002</card-last-four-digits>
<card-type>AMEX</card-type>
<card-sub-type>CREDIT</card-sub-type>
<bin-category>CONSUMER</bin-category>
<card-regulated>N</card-regulated>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
<issuing-country-code>US</issuing-country-code>
</credit-card>
<processing-info>
<cvv-response-code>MA</cvv-response-code>
<avs-response-code-zip>M</avs-response-code-zip>
<avs-response-code-address>M</avs-response-code-address>
<avs-response-code-name>U</avs-response-code-name>
</processing-info>
<date-created>09/30/2020</date-created>
<time-created>05:59:40</time-created>
</credit-card-info>
</payment-sources>
<fraud-result-info>
<device-data-collector>N</device-data-collector>
</fraud-result-info>
<date-created>09/22/2020</date-created>
<time-created>13:41:10</time-created>
</vaulted-shopper>
<vaulted-shopper xmlns="http://ws.plimus.com">
<vaulted-shopper-id>19574596</vaulted-shopper-id>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<zip>12345</zip>
<phone>1234567890</phone>
<company-name></company-name>
<soft-descriptor>BLS*BS</soft-descriptor>
<descriptor-phone-number>98765</descriptor-phone-number>
<shopper-currency>USD</shopper-currency>
<payment-sources>
<credit-card-info>
<billing-contact-info>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<city></city>
<zip>12345</zip>
<country>us</country>
</billing-contact-info>
<credit-card>
<card-last-four-digits>1111</card-last-four-digits>
<card-type>VISA</card-type>
<card-sub-type>CREDIT</card-sub-type>
<bin-category>CONSUMER</bin-category>
<card-regulated>N</card-regulated>
<issuing-bank>JPMORGAN CHASE BANK, N.A.</issuing-bank>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
<issuing-country-code>US</issuing-country-code>
</credit-card>
<processing-info>
<cvv-response-code>MA</cvv-response-code>
<avs-response-code-zip>M</avs-response-code-zip>
<avs-response-code-address>M</avs-response-code-address>
<avs-response-code-name>U</avs-response-code-name>
<network-transaction-id>759205438350294</network-transaction-id>
</processing-info>
<date-created>09/30/2020</date-created>
<time-created>05:59:40</time-created>
</credit-card-info>
</payment-sources>
<fraud-result-info>
<device-data-collector>N</device-data-collector>
</fraud-result-info>
<transaction-order-source>MOTO</transaction-order-source>
<date-created>09/22/2020</date-created>
<time-created>13:41:10</time-created>
</vaulted-shopper>
<vaulted-shopper xmlns="http://ws.plimus.com">
<vaulted-shopper-id>19574596</vaulted-shopper-id>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<zip>12345</zip>
<phone>1234567890</phone>
<soft-descriptor>BLS*BS</soft-descriptor>
<shopper-currency>USD</shopper-currency>
<payment-sources>
<credit-card-info>
<billing-contact-info>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<city></city>
<zip>12345</zip>
<country>us</country>
</billing-contact-info>
<credit-card>
<card-last-four-digits>1111</card-last-four-digits>
<card-type>VISA</card-type>
<card-sub-type>CREDIT</card-sub-type>
<bin-category>CONSUMER</bin-category>
<card-regulated>N</card-regulated>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
<issuing-country-code>US</issuing-country-code>
</credit-card>
<processing-info>
<cvv-response-code>MA</cvv-response-code>
<avs-response-code-zip>M</avs-response-code-zip>
<avs-response-code-address>M</avs-response-code-address>
<avs-response-code-name>U</avs-response-code-name>
<network-transaction-id>759205438350294</network-transaction-id>
</processing-info>
<date-created>09/30/2020</date-created>
<time-created>05:59:40</time-created>
</credit-card-info>
</payment-sources>
<three-d-secure>
<authentication-result>AUTHENTICATION_SUCCEEDED</authentication-result>
</three-d-secure>
<date-created>09/22/2020</date-created>
<time-created>13:41:10</time-created>
</vaulted-shopper>
<vaulted-shopper xmlns="http://ws.plimus.com">
<vaulted-shopper-id>19569774</vaulted-shopper-id>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<zip>12345</zip>
<phone>1234567890</phone>
<company-name>Harel LLC</company-name>
<shopper-currency>USD</shopper-currency>
<payment-sources>
<ecp-details>
<billing-contact-info>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<city></city>
<company-name>Scott LLC</company-name>
</billing-contact-info>
<ecp>
<account-type>CORPORATE_CHECKING</account-type>
<public-account-number>99992</public-account-number>
<public-routing-number>75150</public-routing-number>
</ecp>
<date-created>09/30/2020</date-created>
<time-created>05:48:18</time-created>
</ecp-details>
<ecp-details>
<billing-contact-info>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<company-name>Harel LLC</company-name>
</billing-contact-info>
<ecp>
<account-type>CONSUMER_SAVINGS</account-type>
<public-account-number>99993</public-account-number>
<public-routing-number>75151</public-routing-number>
</ecp>
<date-created>09/30/2020</date-created>
<time-created>05:59:40</time-created>
</ecp-details>
<fraud-result-info>
<device-data-collector>Y</device-data-collector>
</fraud-result-info>
</payment-sources>
<date-created>09/22/2020</date-created>
<time-created>13:41:10</time-created>
</vaulted-shopper>
<vaulted-shopper xmlns="http://ws.plimus.com">
<vaulted-shopper-id>19582620</vaulted-shopper-id>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<country>us</country>
<zip>12345</zip>
<phone>1234567890</phone>
<company-name></company-name>
<soft-descriptor>BLS*BS</soft-descriptor>
<descriptor-phone-number>98765</descriptor-phone-number>
<shopper-currency>USD</shopper-currency>
<payment-sources>
<credit-card-info>
<billing-contact-info>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<city></city>
<zip>12345</zip>
<country>us</country>
</billing-contact-info>
<credit-card>
<card-last-four-digits>1091</card-last-four-digits>
<card-type>VISA</card-type>
<card-sub-type>CREDIT</card-sub-type>
<bin-category>CONSUMER</bin-category>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
<processing-info>
<cvv-response-code>NR</cvv-response-code>
<avs-response-code-zip>N</avs-response-code-zip>
<avs-response-code-address>N</avs-response-code-address>
<avs-response-code-name>U</avs-response-code-name>
<network-transaction-id>020020314061884</network-transaction-id>
</processing-info>
<date-created>09/30/2020</date-created>
<time-created>05:59:40</time-created>
</credit-card-info>
</payment-sources>
<fraud-result-info>
<device-data-collector>N</device-data-collector>
</fraud-result-info>
<three-d-secure>
<authentication-result>AUTHENTICATION_SUCCEEDED</authentication-result>
</three-d-secure>
<date-created>09/22/2020</date-created>
<time-created>13:41:10</time-created>
</vaulted-shopper>
Responses for previous API versions
<vaulted-shopper xmlns="http://ws.plimus.com">
<vaulted-shopper-id>20848977</vaulted-shopper-id>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<shopper-currency>USD</shopper-currency>
<payment-sources>
<credit-card-info>
<billing-contact-info>
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<city></city>
<company-name>CompanyName</company-name>
</billing-contact-info>
<credit-card>
<card-last-four-digits>9299</card-last-four-digits>
<card-type>VISA</card-type>
<card-sub-type>CREDIT</card-sub-type>
<card-category>CLASSIC</card-category>
<expiration-month>02</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
<processing-info>
<cvv-response-code>MA</cvv-response-code>
<avs-response-code-zip>U</avs-response-code-zip>
<avs-response-code-address>U</avs-response-code-address>
<avs-response-code-name>U</avs-response-code-name>
</processing-info>
<fraud-result-info>
<device-data-collector>N</device-data-collector>
</fraud-result-info>
</credit-card-info>
</payment-sources>
</vaulted-shopper>
HTTP/ 1.1 201 Created
Location: https://sandbox.bluesnap.com/services/2/vaulted-shoppers/19549020
Example Descriptions
Basic Create Vaulted Shopper
This example shows a basic Create Vaulted Shopper request that saves the shopper in BlueSnap without any information about the shopper's payment methods.
Create Vaulted Shopper with credit card
To save credit card information for the shopper, you'll need to include the credit-card-info
property within the payment-sources
resource in your request. See credit-card-info. Note that you must meet specific PCI compliance requirements in order to send unencrypted card details.
Above is an example of a request with an unencrypted credit card number.
Create Vaulted Shopper with credit card and billing info
Optionally, you can include the shopper's billing info in the credit-card-info
property within the payment-sources
resource in your request. See credit-card-info. This can help improve the experience for returning shoppers, because you can save time by pre-populating the checkout form with their billing details.
Above is an example of a request with credit card details along with billing info.
Create Vaulted Shopper with credit card, billing info and fraud info
Optionally, you can include fraud info in the request, so that your fraud checks can run and verify that you are not saving a shopper with payment info that is suspected to be fraudulent.
Above is an example of a request with that includes fraud info such as the shopper's IP address and shipping address.
Create Vaulted Shopper with encrypted credit card
Your PCI compliance requirements and API permission level may require that you send credit card data in encrypted format only. To do this, you'll need to include theencrypted-card-number
and encrypted-security-code
properties within the credit-card-info resource in your request.
Above is an example of a request with an encrypted credit card number.
Create Vaulted Shopper with encrypted credit card
Your PCI compliance requirements and API permission level may require that you send credit card data in encrypted format only. To do this, you'll need to include theencrypted-card-number
and encrypted-security-code
properties within the credit-card-info resource in your request.
Above is an example of a request with an encrypted credit card number.
Create Vaulted Shopper with wallet
To create a shopper with wallet details, including the payment info and billing and shipping info, you will simply include the wallet-id
in the request. No other elements are required.
For details, see:
Above is an example of a request with a wallet ID.
Create Vaulted Shopper with Hosted Payment Fields token
If you are using BlueSnap's Hosted Payment Fields, you can save the shopper's payment information from the Hosted Payment Fields by including the token within the pf-token
property in your request.
Above is an example of a request with the Hosted Payment Fields token.
Create Vaulted Shopper with credit card and soft descriptor
The above example shows how to create a shopper with a credit card and soft descriptor, which is the description that may appear on the shopper's bank statement when BlueSnap validates the card before adding it to the shopper.
Create Vaulted Shopper with SEPA Direct Debit
The above example shows a Create Vaulted Shopper request with bank account details for the SEPA Direct Debit payment method. Include the shopper's bank account details within payment-sources
> sepa-direct-debit-info
> sepa-direct-debit
. The shopper may have more than one saved bank accounts with the SEPA Direct Debit payment method.
Create Vaulted Shopper with ACH/ECP info
To save ACH/ECP account info for a shopper, include the ecp-info element in your request. Only one ACH/ECP account can be saved per shopper.
Create Vaulted Shopper with multiple ACH accounts
The above example shows a Create Vaulted Shopper request for shoppers who have multiple ACH accounts. Include the shopper's account details within payment-sources
> ecp-details
.
Create Vaulted Shopper with MOTO and NTI
The transaction-order-source
identifies the order as Mail Order Telephone Order. The response includes the network-transaction-id
for the transaction.
Create Vaulted Shopper with 3DS
The response includes the 3DS result and the NTI (networkTransactionId
) for the transaction. Save this for future transactions.
API Explorer (API version 2.0)
To test out a call, enter the XML portion of the request below and then click Try it!
Tip: Copy the XML portion from one of the example requests above, or use the XML code below as a starting point. You can enter different parameters and test credit card numbers to see how your test scenario would work. The request headers, including authorization, are already built in for you in this test area, so you should not include them here.
<vaulted-shopper xmlns="http://ws.plimus.com">
<first-name>FirstName</first-name>
<last-name>LastName</last-name>
<payment-sources>
<credit-card-info>
<credit-card>
<card-number>4263982640269299</card-number>
<security-code>837</security-code>
<expiration-month>02</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</payment-sources>
</vaulted-shopper>