Skip to content

Instantly share code, notes, and snippets.

@simonmorley
Forked from michaelschade/gist:8276067
Created January 6, 2014 01:29
Show Gist options
  • Save simonmorley/8276720 to your computer and use it in GitHub Desktop.
Save simonmorley/8276720 to your computer and use it in GitHub Desktop.
> curl https://api.stripe.com/v1/customers \
-u [apikey]: \
-d "card[number]=4000000000000002" \
-d "card[exp_month]=12" \
-d "card[exp_year]=2015" \
-d "card[cvc]=123" \
> -d validate=false
{
"object": "customer",
"created": 1388967139,
"id": "cus_3FwtZFm7cgR8LI",
"livemode": false,
"description": null,
"email": null,
"delinquent": false,
"metadata": {},
"subscription": null,
"discount": null,
"account_balance": 0,
"currency": null,
"cards": {
"object": "list",
"count": 1,
"url": "/v1/customers/cus_3FwtZFm7cgR8LI/cards",
"data": [
{
"id": "card_3FwtW6hKrQoidb",
"object": "card",
"last4": "0002",
"type": "Visa",
"exp_month": 12,
"exp_year": 2015,
"fingerprint": "TNbJaZFsZgLCxMbi",
"customer": "cus_3FwtZFm7cgR8LI",
"country": "US",
"name": null,
"address_line1": null,
"address_line2": null,
"address_city": null,
"address_state": null,
"address_zip": null,
"address_country": null,
"cvc_check": null,
"address_line1_check": null,
"address_zip_check": null
}
]
},
"default_card": "card_3FwtW6hKrQoidb",
"next_recurring_charge": null,
"active_card": {
"id": "card_3FwtW6hKrQoidb",
"object": "card",
"last4": "0002",
"type": "Visa",
"exp_month": 12,
"exp_year": 2015,
"fingerprint": "TNbJaZFsZgLCxMbi",
"customer": "cus_3FwtZFm7cgR8LI",
"country": "US",
"name": null,
"address_line1": null,
"address_line2": null,
"address_city": null,
"address_state": null,
"address_zip": null,
"address_country": null,
"cvc_check": null,
"address_line1_check": null,
"address_zip_check": null
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment