get https://api.chartmogul.com/v1/customers//attributes
Retrieves the customer attributes of a given customer.
Examples
curl -X GET "https://api.chartmogul.com/v1/customers/cus_de305d54-75b4-431b-adb2-eb6b9e546012/attributes" \
-u YOUR_API_KEY:
customer = ChartMogul::Customer.retrieve("cus_de305d54-75b4-431b-adb2-eb6b9e546012")
customer.attributes
ChartMogul.Customer.attributes(config, "cus_de305d54-75b4-431b-adb2-eb6b9e546012");
$customer = ChartMogul\Customer::retrieve("cus_de305d54-75b4-431b-adb2-eb6b9e546012");
$customer->attributes;
api.RetrieveCustomersAttributes("cus_de305d54-75b4-431b-adb2-eb6b9e546012")
chartmogul.Attributes.retrieve(config, uuid="cus_de305d54-75b4-431b-adb2-eb6b9e546012")
Result Format
{
"tags": ["engage", "unit loss", "discountable"],
"stripe": {
"uid": 7,
"coupon": true
},
"clearbit": {},
"custom": {
"CAC": 213,
"utmCampaign": "social media 1",
"convertedAt": "2022-09-08 00:00:00",
"pro": false,
"salesRep": "Gabi"
}
}
{
:tags => ["engage", "unit loss", "discountable"],
:stripe => {
:uid => 7,
:coupon => true,
},
:clearbit => {},
:custom => {
:CAC => 213,
:utmCampaign => "social media 1",
:convertedAt => "2022-09-08 00:00:00",
:pro => false,
:salesRep => "Gabi",
},
}
{
tags: ["engage", "unit loss", "discountable"],
stripe: {
uid: 7,
coupon: true
},
clearbit: {},
custom: {
CAC: 213,
utmCampaign: "social media 1",
convertedAt: "2022-09-08 00:00:00",
pro: false,
salesRep: "Gabi"
}
}
array (
"custom" =>
array (
"CAC" => 213,
"utmCampaign" => "social media 1",
"convertedAt" => "2022-09-08T00:00:00.000Z",
"pro" => false,
"salesRep" => "Gabi",
),
"clearbit" =>
array (
),
"stripe" =>
array (
"uid" => 7,
"coupon" => true
),
"tags" =>
array (
0 => "engage",
1 => "unit loss",
2 => "discountable",
),
)
(*chartmogul.Attributes)(0xc042042f30)({
Tags: ([]string) (len=3) {
(string) (len=6) "engage",
(string) (len=9) "unit loss",
(string) (len=12) "discountable"
},
Stripe: (*chartmogul.Stripe)(0xc04200c5b0)({
UID: (uint64) 7,
Coupon: (bool) true
}),
Clearbit: (*chartmogul.Clearbit)(0xc0420da3c0)({
}),
Custom: (map[string]interface {}) (len=5) {
(string) (len=3) "CAC": (float64) 213,
(string) (len=11) "utmCampaign": (string) (len=14) "social media 1",
(string) (len=11) "convertedAt": (string) (len=25) "2022-09-08T00:00:00-04:00",
(string) (len=3) "pro": (string) (bool) false,
(string) (len=8) "salesRep": (string) (len=4) "Gabi"
}
})
<Attributes{
clearbit=<Clearbit{
}>,
custom={
"CAC": 213,
"utmCampaign": "social media 1",
"convertedAt": "2022-09-08 00:00:00",
"pro": False,
"salesRep": "Gabi"},
tags=["engage", "unit loss", "discountable"]
}>
The response contains the customer's attributes with the following data:
tags
- An Array of tags that you have added to this customer.stripe
- A JSON object representing any metadata on this customer object in your Stripe account.clearbit
- A JSON object representing publicly available information about this customer retrieved from Clearbit. This is a legacy field. ChartMogul no longer utilizes Clearbit.custom
- A JSON object representing custom attributes that you have added to this customer.