API Docs
/
No Results Found
Cards

Cards

A card object shows the credit card information for a particular customer

End Points
Retrieve a credit card information
Delete a credit card
List all Active Credit Cards of a Customer

Attribute

customer_id
string
Unique ID associated with the customer.
card_id
string
Card ID of the card from which payment is about to made by the customer.
last_four_digits
integer
Last four digits of the customer's card.
expiry_month
integer
Expiry month of the customer's card.
expiry_year
integer
Expiry year of the customer's card.
payment_gateway
string
Payment gateway through which payment needs to be made. Supported payment gateway values test_gateway, payflow_pro, stripe, 2checkout, authorize_net, payments_pro, forte, worldpay, wepay.
first_name
string
Customer's first name in card.
last_name
string
Customer's last name in card.
street
string
The street mentioned in the customer's card address.
city
string
City mentioned in the customer's card address.
state
string
State mentioned in the customer's card address.
zip
string
Zip code mentioned in the customer's card address.
country
string
The country mentioned in the customer's card address.
created_time
string
Time at which the contact person was created.
updated_time
string
Time at which the contact person details were last updated.

Example

{ "customer_id": "9030000005664", "card_id": "90300000079226", "last_four_digits": 2145, "expiry_month": 9, "expiry_year": 2030, "payment_gateway": "payflow_pro", "first_name": "benjamin", "last_name": "franklin", "street": "12 Harington Bay Street", "city": "Salt Lake City", "state": "CA", "zip": 92612, "country": "U.S.A", "created_time": "2016-06-05T12:30:08-0700", "updated_time": "2016-06-05T02:30:08-0700" }

Retrieve a credit card information

Details of an existing credit card.
oauthscope : ZohoSubscriptions.customers.READ

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/customers/{customer_id}/cards/{card_id} -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f"

Response Example

{ "code": 0, "message": "success", "card": { "customer_id": "9030000005664", "card_id": "90300000079226", "last_four_digits": 2145, "expiry_month": 9, "expiry_year": 2030, "payment_gateway": "payflow_pro", "first_name": "benjamin", "last_name": "franklin", "street": "12 Harington Bay Street", "city": "Salt Lake City", "state": "CA", "zip": 92612, "country": "U.S.A", "created_time": "2016-06-05T12:30:08-0700", "updated_time": "2016-06-05T02:30:08-0700" } }

Delete a credit card

Delete an existing credit card.
oauthscope : ZohoSubscriptions.customers.DELETE

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/customers/{customer_id}/cards/{card_id} -X DELETE -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f"

Response Example

{ "code": 0, "message": "The credit card has been deleted." }

List all Active Credit Cards of a Customer

List of all the Active Credit Cards of a Customer.
oauthscope : ZohoSubscriptions.customers.READ

Request Example

Click to copy
$ curl https://subscriptions.zoho.com/api/v1/customers/{customer_id}/cards -H "X-com-zoho-subscriptions-organizationid: 10234695" -H "Authorization: Zoho-oauthtoken 1000.41d9f2cfbd1b7a8f9e314b7aff7bc2d1.8fcc9810810a216793f385b9dd6e125f"

Response Example

{ "code": 0, "message": "success", "cards": [ { "card_id": "90300000079226", "customer_id": "9030000005664", "status": "active", "last_four_digits": 2145, "expiry_month": 9, "expiry_year": 2030, "payment_gateway": "payflow_pro", "created_time": "2016-06-05T12:30:08-0700", "updated_time": "2016-06-05T02:30:08-0700" }, {...}, {...} ] }