POST v1/PaymentAccount/CreditCard?PolicyNumber={PolicyNumber}
Save Credit Card Details
Request Information
URI Parameters
Name | Description | Type | Additional information |
---|---|---|---|
PolicyNumber | string |
Required |
Body Parameters
Credit card details
CreditCardInboundDTOName | Description | Type | Additional information |
---|---|---|---|
Id |
Credit card master id, use for existing credit card |
integer |
None. |
CreditCardNumber |
Credit card token (Required if Id not set) |
string |
String length: inclusive between 0 and 25 |
CreditCardType |
Card network / provider (e.g. Visa, MasterCard) (Required if Id not set) |
CreditCardTypeEnum |
None. |
MonthOfExpirationDate |
Expiration month (January = 1) (Required if Id not set) |
integer |
Range: inclusive between 1 and 12 |
YearOfExpirationDate |
Two or four digit year (e.g. 21 or 2021) (Required if Id not set) |
integer |
None. |
CardHolderName |
Card holder name (Required if Id not set) |
string |
None. |
CardHolderAddress |
Card holder address (Required if Id not set) |
AddressDTO |
None. |
Expand |
Comma separated list of expansions to include in results |
string |
None. |
Request Formats
application/json, text/json
Sample:
{ "Id": 1, "CreditCardNumber": "samplestring2", "CreditCardType": "Unknown", "MonthOfExpirationDate": 1, "YearOfExpirationDate": 2003, "CardHolderName": "sample string 4", "CardHolderAddress": { "Address1": "sample string 1", "Address2": "sample string 2", "City": "sample string 3", "State": "sample string 4", "County": "sample string 5", "Country": "sample string 6", "Zipcode1": "sample string 7", "Zipcode2": "sample string 8", "Id": 9 }, "Expand": "" }
application/xml, text/xml
Sample:
<CreditCardInboundDTO xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/GCApi.Models.Inbound"> <Expand></Expand> <Expansions xmlns:d2p1="http://schemas.datacontract.org/2004/07/GCApi.Enums" /> <Id>1</Id> <CardHolderAddress xmlns:d2p1="http://schemas.datacontract.org/2004/07/GCApi.Models"> <d2p1:Expand></d2p1:Expand> <d2p1:Expansions xmlns:d3p1="http://schemas.datacontract.org/2004/07/GCApi.Enums" /> <d2p1:Id>9</d2p1:Id> <d2p1:Address1>sample string 1</d2p1:Address1> <d2p1:Address2>sample string 2</d2p1:Address2> <d2p1:City>sample string 3</d2p1:City> <d2p1:Country>sample string 6</d2p1:Country> <d2p1:County>sample string 5</d2p1:County> <d2p1:State>sample string 4</d2p1:State> <d2p1:Zipcode1>sample string 7</d2p1:Zipcode1> <d2p1:Zipcode2>sample string 8</d2p1:Zipcode2> </CardHolderAddress> <CardHolderName>sample string 4</CardHolderName> <CreditCardNumber>samplestring2</CreditCardNumber> <CreditCardType>Unknown</CreditCardType> <MonthOfExpirationDate>1</MonthOfExpirationDate> <YearOfExpirationDate>2003</YearOfExpirationDate> </CreditCardInboundDTO>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
IdResponseDTOName | Description | Type | Additional information |
---|---|---|---|
Id |
Primary Id |
integer |
None. |
WarningMessages |
List of warning messages encountered while servicing request |
Collection of string |
None. |
Response Formats
application/json, text/json
Sample:
Sample not available.