POST v1/Customers/{customerId}/Payments

Replace payment methods from a customer profile

URI template

v1/Customers/{customerId}/Payments

Request Information

URI Parameters

NameDescriptionTypeAdditional information
customerId

The customer that we are updating the payments for

globally unique identifier

Required

Body Parameters

InPayment object containing an account number, expiration date and a payment type

InPayment
NameDescriptionTypeAdditional information
AccountNumber

string

Required

ExpirationDate

string

Required

PaymentMethodType

CustomerPaymentMethodType

Required

Request Formats

application/json, text/json

Sample:
{
  "AccountNumber": "sample string 1",
  "ExpirationDate": "sample string 2",
  "PaymentMethodType": 0
}

application/xml, text/xml

Sample:
<InPayment xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/OnlineOrderingAPI.Inbound">
  <AccountNumber>sample string 1</AccountNumber>
  <ExpirationDate>sample string 2</ExpirationDate>
  <PaymentMethodType>Amex</PaymentMethodType>
</InPayment>

Response Information

Resource Description

Returns the account id of the payment method. Known internal errors are BadRequest and Error

globally unique identifier

Response Formats

application/json, text/json

Sample:
"d0f154eb-3beb-469c-84a4-7ffb6cea3349"

application/xml, text/xml

Sample:
<guid xmlns="http://schemas.microsoft.com/2003/10/Serialization/">d0f154eb-3beb-469c-84a4-7ffb6cea3349</guid>