Skip to main content
GET/attributes/:id/

Get single attribute

You can return details about a contact attribute.

warning

This endpoint finds contact attributes only. Attribute IDs are numbered separately for each model, so the ID of a company, deal or other attribute returns the contact attribute that happens to have the same ID, or a 404. Use Get all attributes for other models.

Attributes

Optional unless marked required

idintegerrequired
ID of the contact attribute, from the Create attribute response.

Request​

curl -X GET "https://<your_app_subdomain>.user.com/api/public/attributes/:id/" \
-H "Authorization: Token <your_64_char_api_key>" \
-H "Accept: */*; version=2"

Response examples​

{
"name": "My Attribute",
"id": 2511,
"content_type": "user",
"value_type": "boolean",
"name_std": "my_attribute"
}

The 404 comes back when no contact attribute has that ID.

Response fields​

Fields returned in the 200 OK response body.

idinteger
A unique identifier for the attribute which is given by User automatically.
namestring
Attribute name, as entered when it was created.
name_stdstring
Standardized name used in the API and in record bodies (Loyalty tier becomes loyalty_tier).
value_typestring
Value type of the attribute: boolean, date, datetime, fixed, float, integer, json or string.
content_typestring
Always user: the endpoint returns contact attributes only.
note

Errors that can come from any endpoint (401, 429, 500, 502, 504) are described in HTTP response codes.