Definition
https://sandbox.bluesnap.com/services/2/shoppers/:shopper-id|:seller-shopper-id,:seller-id
Documentation
The Update Shopper request enables you to update an existing shopper by changing their contact info, adding and deleting payment methods, adding wallet details, and more.
Notes:
Each shopper can have multiple credit cards.
If you send a credit card number that does not yet exist for that shopper, it will be added to the shopper.
If you send a credit card number that already exists in that shopper, the shopper will be updated with any changes to that card's expiration date.
You can update your shopper's billing info using the public ACH or SEPA info without storing the full IBAN or account number.
Request Content
shopper
required, contains the following properties (see shopper):
web-info
container required (see web-info)
fraud-info
container optional (see fraud-info)
shopper-info
container required (see shopper-info)
wallet-id
integer optional applicable for Masterpass and Visa Checkout.
three-d-secure
container optional (refer to three-d-secure)
Response Details
If successful, the response HTTP status code is 204 No Content.
There is no content in the response body.
For details about possible errors, see: General Errors, Shopper Errors, Hosted Payment Field Errors, and Wallet Errors.
Examples
Request Examples
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575974 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
<remote-host>www.merchant.com</remote-host>
<user-agent>Mozilla/5.0 (Linux; X11)</user-agent>
</web-info>
<shopper-info>
<store-id>4677</store-id>
<soft-descriptor>MYCOMPANY</soft-descriptor>
<payment-info>
<credit-cards-info>
<credit-card-info>
<billing-contact-info>
<first-name>John</first-name>
<last-name>Doe</last-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<zip>75654</zip>
<state>CA</state>
<country>US</country>
</billing-contact-info>
<credit-card>
<card-number>4012 8888 8888 1881</card-number>
<security-code>411</security-code>
<card-type>VISA</card-type>
<expiration-month>07</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</credit-cards-info>
</payment-info>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575974 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.195</ip>
</web-info>
<shopper-info>
<store-id>4677</store-id>
<invoice-contacts-info>
<invoice-contact-info>
<default>true</default>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>[email protected]</email>
<company-name>JohnDoeAndSons</company-name>
<address1>100 Main st</address1>
<city>San Jose</city>
<state>CA</state>
<zip>75654</zip>
<country>US</country>
<phone>14135556789</phone>
<fax>14135556788</fax>
</invoice-contact-info>
</invoice-contacts-info>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575974 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
</web-info>
<shopper-info>
<payment-info>
<credit-cards-info>
<credit-card-info>
<billing-contact-info>
<first-name>Bill</first-name>
<last-name>Smith</last-name>
<address1>500 Lincoln Av</address1>
<city>San Francisco</city>
<state>CA</state>
<zip>75654</zip>
<country>US</country>
</billing-contact-info>
<credit-card>
<card-last-four-digits>1881</card-last-four-digits>
<card-type>VISA</card-type>
</credit-card>
</credit-card-info>
</credit-cards-info>
</payment-info>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575992 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
</web-info>
<shopper-info>
<store-id>4677</store-id>
<payment-info>
<credit-cards-info>
<credit-card-info>
<billing-contact-info>
<first-name>John</first-name>
<last-name>Doe</last-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<zip>75654</zip>
<state>CA</state>
<country>US</country>
</billing-contact-info>
<credit-card>
<card-number>4111111111111111</card-number>
<security-code>411</security-code>
<card-type>VISA</card-type>
<expiration-month>04</expiration-month>
<expiration-year>2023</expiration-year>
</credit-card>
</credit-card-info>
</credit-cards-info>
</payment-info>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
</web-info>
<shopper-info>
<store-id>11580</store-id>
</shopper-info>
<wallet-id>121</wallet-id>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575974 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
</web-info>
<shopper-info>
<store-id>4677</store-id>
<payment-info>
<credit-cards-info>
<credit-card-info>
<billing-contact-info>
<first-name>John</first-name>
<last-name>Doe</last-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<zip>75654</zip>
<state>CA</state>
<country>US</country>
</billing-contact-info>
<pf-token>c7c69ff853ab784ef35a0c78ffec08e78cf1d1b5b4bb9e2644c2bcc73f3f818f_1</pf-token>
</credit-card-info>
</credit-cards-info>
</payment-info>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575992 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>127.0.0.1</ip>
</web-info>
<shopper-info>
<shopper-id>19566484</shopper-id>
<shopper-contact-info>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>jdoe@johndoeandsons.com</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market st</address1>
<city>San Francisco</city>
<zip>756543</zip>
<country>fr</country>
<phone>1413555666</phone>
<fax>1413555666789</fax>
</shopper-contact-info>
<shipping-contact-info/>
<invoice-contacts-info>
<invoice-contact-info>
<default>true</default>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>jdoe@johndoeandsons.com</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market st</address1>
<city>Paris</city>
<zip>756543</zip>
<country>fr</country>
<phone>1413555666</phone>
<fax>1413555666789</fax>
</invoice-contact-info>
</invoice-contacts-info>
<payment-info>
<credit-cards-info/>
<ecps-info/>
<sepa-direct-debits-info>
<sepa-direct-debit-info>
<billing-contact-info>
<first-name>SEPA new</first-name>
<last-name>abc new</last-name>
<address1>123 Oxford</address1>
<city>Paris</city>
<zip>54321</zip>
<country>fr</country>
</billing-contact-info>
<sepa-direct-debit>
<iban-first-four>DE09</iban-first-four>
<iban-last-four>7893</iban-last-four>
</sepa-direct-debit>
</sepa-direct-debit-info>
</sepa-direct-debits-info>
<balance/>
</payment-info>
<store-id>1900</store-id>
<shopper-currency>USD</shopper-currency>
<locale>en</locale>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575992 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>127.0.0.1</ip>
</web-info>
<shopper-info>
<shopper-id>19566478</shopper-id>
<shopper-contact-info>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>[email protected]</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<state>CA</state>
<zip>75654</zip>
<country>us</country>
<phone>14135556789</phone>
<fax>14135556788</fax>
</shopper-contact-info>
<shipping-contact-info/>
<invoice-contacts-info>
<invoice-contact-info>
<default>true</default>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>[email protected]</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<state>CA</state>
<zip>75654</zip>
<country>us</country>
<phone>14135556789</phone>
<fax>14135556788</fax>
</invoice-contact-info>
</invoice-contacts-info>
<payment-info>
<credit-cards-info/>
<ecps-info>
<ecp-info>
<billing-contact-info>
<first-name>first</first-name>
<last-name>last name</last-name>
<address1>123 Oxford</address1>
<city>ny</city>
<state>NY</state>
<zip>90210</zip>
<country>us</country>
</billing-contact-info>
<ecp>
<account-type>CONSUMER_CHECKING</account-type>
<public-account-number>98871</public-account-number>
<public-routing-number>74268</public-routing-number>
</ecp>
</ecp-info>
</ecps-info>
<sepa-direct-debits-info/>
<balance/>
</payment-info>
<store-id>1900</store-id>
<shopper-currency>USD</shopper-currency>
<locale>en</locale>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575992 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>127.0.0.1</ip>
<remote-host>www.merchant.com</remote-host>
<user-agent>Mozilla/5.0 (Linux; X11)</user-agent>
</web-info>
<shopper-info>
<shopper-id>19570110</shopper-id>
<store-id>8540</store-id>
<payment-info>
<ecps-info>
<ecp-info>
<billing-contact-info>
<first-name>first</first-name>
<last-name>last name</last-name>
<address1>123 Oxford</address1>
<city>ny</city>
<state>NY</state>
<zip>90210</zip>
<country>us</country>
</billing-contact-info>
<ecp>
<account-type>CONSUMER_CHECKING</account-type>
<account-number>4099999993</account-number>
<routing-number>011075151</routing-number>
</ecp>
</ecp-info>
</ecps-info>
</payment-info>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575974 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
<remote-host>www.merchant.com</remote-host>
<user-agent>Mozilla/5.0 (Linux; X11)</user-agent>
</web-info>
<shopper-info>
<store-id>4677</store-id>
<soft-descriptor>MYCOMPANY</soft-descriptor>
<payment-info>
<credit-cards-info>
<credit-card-info>
<credit-card>
<card-last-four-digits>9299</card-last-four-digits>
<card-type>VISA</card-type>
</credit-card>
<status>D</status>
</credit-card-info>
</credit-cards-info>
</payment-info>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575974 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
<remote-host>www.merchant.com</remote-host>
<user-agent>Mozilla/4.0</user-agent>
<accept-language>en-us</accept-language>
</web-info>
<shopper-info>
<shopper-id>19564316</shopper-id>
<shopper-contact-info>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>[email protected]</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<state>CA</state>
<zip>75654</zip>
<country>us</country>
<phone>14135556789</phone>
<fax>14135556788</fax>
</shopper-contact-info>
<shipping-contact-info/>
<invoice-contacts-info>
<invoice-contact-info>
<default>true</default>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>[email protected]</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<state>CA</state>
<zip>75654</zip>
<country>us</country>
<phone>14135556789</phone>
<fax>14135556788</fax>
</invoice-contact-info>
</invoice-contacts-info>
<payment-info>
<credit-cards-info/>
<ecps-info>
<ecp-info>
<billing-contact-info>
<first-name>second ecp first</first-name>
<last-name>second ECP last name</last-name>
<address1>123 Oxford</address1>
<city>ny</city>
<state>NY</state>
<zip>90210</zip>
<country>us</country>
<company-name>JohnDoeAndSons</company-name>
</billing-contact-info>
<ecp>
<account-type>CONSUMER_CHECKING</account-type>
<public-account-number>98871</public-account-number>
<public-routing-number>74268</public-routing-number>
</ecp>
<status>D</status>
</ecp-info>
</ecps-info>
<balance/>
</payment-info>
<store-id>1900</store-id>
<shopper-currency>USD</shopper-currency>
<locale>en</locale>
</shopper-info>
</shopper>
curl -v -X PUT https://sandbox.bluesnap.com/services/2/shoppers/19575974 \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d '
<shopper xmlns="http://ws.plimus.com">
<web-info>
<ip>62.219.121.253</ip>
<remote-host>www.merchant.com</remote-host>
<user-agent>Mozilla/4.0</user-agent>
<accept-language>en-us</accept-language>
</web-info>
<shopper-info>
<shopper-id>19564316</shopper-id>
<shopper-contact-info>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>[email protected]</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market St</address1>
<city>San Francisco</city>
<zip>75654</zip>
<country>fr</country>
<phone>14135556789</phone>
<fax>14135556788</fax>
</shopper-contact-info>
<shipping-contact-info/>
<invoice-contacts-info>
<invoice-contact-info>
<default>true</default>
<title>Mr.</title>
<first-name>John</first-name>
<last-name>Doe</last-name>
<email>[email protected]</email>
<company-name>JohnDoeAndSons</company-name>
<address1>138 Market St</address1>
<city>Paris</city>
<zip>75654</zip>
<country>fr</country>
<phone>14135556789</phone>
<fax>14135556788</fax>
</invoice-contact-info>
</invoice-contacts-info>
<payment-info>
<sepa-direct-debits-info>
<sepa-direct-debit-info>
<billing-contact-info>
<first-name>SEPA Billing first name</first-name>
<last-name>SEPA Billing last name</last-name>
<address1>123 Oxford</address1>
<city>Paris</city>
<zip>15016</zip>
<country>fr</country>
</billing-contact-info>
<sepa-direct-debit>
<iban-first-four>DE09</iban-first-four>
<iban-last-four>7893</iban-last-four>
</sepa-direct-debit>
<status>D</status>
</sepa-direct-debit-info>
</sepa-direct-debits-info>
<balance/>
</payment-info>
<store-id>1900</store-id>
<shopper-currency>USD</shopper-currency>
<locale>en</locale>
</shopper-info>
</shopper>
Response Example
HTTP/ 1.1 204 No Content
Example Descriptions
Add credit card
The example above shows how to add another credit card to an existing shopper.
Add invoice contact information
The example above shows how to add invoice contact info to a shopper. Note that this will not change any of the existing invoice contact info, but will instead be added to the shopper's list of invoice contact info.
Update billing information
The example above shows how to update the billing information for a shopper's existing credit card. To do this, you only need to send the last four digits of the relevant credit card, not the entire card number.
Update credit card information
The example above shows how to update information for a shopper's existing credit card (card number 4111-1111-1111-1111). To update an existing credit card, you must send the complete card data.
Update with wallet ID
The example above shows how to add credit card info from a Masterpass or Visa Checkout wallet to a shopper by including the wallet-id
in the request.
For details, see:
Update with Hosted Payment Fields token
The example above shows how to add credit card information from BlueSnap's Hosted Payment Fields to the shopper, by including the Hosted Payment Fields token within the pf-token
property in your request.
Update SEPA information
The example above shows how to update information for a shopper's existing SEPA info. To update existing SEPA info, you must update the :seller-shopper-id,:seller-id in the URL (pass both seller-shopper-id and seller-id in the URL separated by a comma). (Note that this does not depend on the payment method, but works for credit cards, SEPA info, and so on.)
Update ACH information
The example above shows how to update information for a shopper's existing ACH info. To update existing ACH info, you must update the :seller-shopper-id,:seller-id in the URL (pass both seller-shopper-id and seller-id in the URL separated by a comma). (Note that this does not depend on the payment method, but works for credit cards, ACH info, and so on.)
Delete* credit card
This example request shows how to delete a credit card from a vaulted shopper. Include the status
property in the request and set its value to D. Specify the card to be deleted by including card-type
and card-last-four-digits
.
Delete* ACH/ECP
This example request shows how to delete an ACH/ECP payment method from a vaulted shopper. Include the status
property in the request and set its value to D. Specify the ecp-details
to be deleted by including account-type
, public-account-number
, and public-routing-number
.
Delete* SEPA
This example request shows how to delete a SEPA payment method from a vaulted shopper. Include the status
property in the request and set its value to D. Specify the sepa-direct-debit-info
to be deleted by including iban-first-four
and iban-last-four
.
* Notes on deleting a payment method
-
If you attempt to delete a payment method that is linked to a subscription, an error occurs. Send an Update Subscription request to either switch the shopper's payment source or to cancel the subscription, and then retry the Update Vaulted Shopper request to delete the payment method.
-
You cannot delete a payment method if there is a payment pending approval for the payment method.
Back to Top