BillingPlans: getCreditCard

Request

HTTP request

GET /v2/accounts/{accountId}/billing_plan/credit_card

Parameters

Parameter name Value Description
Path parameters
accountId string

The external account number (int) or account ID Guid.

Responses

Code Description Reference
200 OK Successful response.
400 Bad Request Error encountered.

SDK Method

Billing::getCreditCardInfo

Definitions Expand All | Collapse All

addressInformation

Contains address information.

city string

The city associated with the address.

country string

Specifies the country associated with the address.

fax string

A Fax number associated with the address if one is available.

phone string

A phone number associated with the address.

state string

The state or province associated with the address.

street1 string

The first line of the address.

street2 string

The second line of the address (optional).

zip string

The zip or postal code associated with the address.

creditCardInformation

address addressInformation

A complex element containing the credit card billing address information.

This can be the same as billing address and follows the same rules as billingAddress. It contains the following elements: street1, street2, city, state, zip, zipPlus4, phone, fax, and country.

cardNumber string

The number on the credit card.

cardType string

The credit card type. Valid values are: visa, mastercard, or amex.

expirationMonth string

The month that the credit card expires (1-12).

expirationYear string

The year 4 digit year in which the credit card expires.

nameOnCard string

The exact name printed on the credit card.

errorDetails

This object describes errors that occur. It is only valid for responses, and ignored in requests.

errorCode string

An error code associated with the error.

message string

A short error message.

Examples

Generic JSON Response

Response

{
"cardNumber": "sample string 1",
"expirationMonth": "sample string 2",
"expirationYear": "sample string 3",
"nameOnCard": "sample string 4",
"cardType": "sample string 5",
"address": {
"street1": "sample string 1",
"street2": "sample string 2",
"city": "sample string 3",
"state": "sample string 4",
"zip": "sample string 5",
"phone": "sample string 6",
"fax": "sample string 7",
"country": "sample string 8"
}
}

Generic XML Response

Response

<creditCardInformation 
xmlns:i="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.docusign.com/restapi">

<address>
<city>sample string 3</city>
<country>sample string 8</country>
<fax>sample string 7</fax>
<phone>sample string 6</phone>
<state>sample string 4</state>
<street1>sample string 1</street1>
<street2>sample string 2</street2>
<zip>sample string 5</zip>
</address>
<cardNumber>sample string 1</cardNumber>
<cardType>sample string 5</cardType>
<expirationMonth>sample string 2</expirationMonth>
<expirationYear>sample string 3</expirationYear>
<nameOnCard>sample string 4</nameOnCard>
</creditCardInformation>