attribute
Collection: attributes
An attribute is a non-standard property that can be applied to multiple resources such as a client, user, store, transaction, cart, subscription, shipment, item, and customer. You can set the visibility to control whether or not other client implementations can also view the property or if that property should not be visible unless connected with the proper client credentials.
Client Attribute Restrictions: To modify, view or create a client attribute, you must be connected to the API using an OAuth token which has client_full_access scope.
User Attribute Restrictions: To modify, view or create a user attribute, you must be connected to the API using an OAuth token which has user_full_access scope.
Notes
The endpoint URL for attributes varies depending on the parent resource. For example, store attributes are at /store_attributes/{id}, transaction attributes at /transaction_attributes/{id}, customer attributes at /customer_attributes/{id}, and so on. The URL shown above uses store_attributes as a default, but the actual path will differ based on the parent resource type.
Required Scopes
store_full_access On a store:
stores_read stores_write On a customer:
customers_read customers_write On a completed transaction:
transactions_read transactions_write On a cart:
carts_read carts_write On an item (completed transaction):
transactions_read transactions_write On an item (cart):
carts_read carts_write On a subscription:
subscriptions_read subscriptions_write On a shipment:
transactions_read transactions_write On a coupon:
coupons_read coupons_write On a gift card:
gift_cards_read gift_cards_write On a client (requires client_full_access):
clients_read clients_write On a user (requires user_full_access):
users_read users_write Actions
Properties (5)
name String · Required · max 500 The name of this attribute.
value String · Required · max 1000 The value of this attribute.
visibility String Controls who can see this attribute. Public attributes can be shown to anyone, including customers. Private attributes are more suitable for configuration or technical details which are irrelevant to the public. Restricted attributes can only be viewed by the OAuth client who creates them.
Cannot be modified once set.
Default: private
publicprivaterestricted date_created String (nullable) · Read-only The date this resource was created.
date_modified String (nullable) · Read-only The date this resource was last modified.
Link Relations (1)
self This Attribute Example Representation
{
"_links": {
"curies": [
{
"name": "fx",
"href": "https://api.foxycart.com/rels/{rel}",
"templated": true
}
],
"self": {
"href": "https://api.foxycart.com/store_attributes/123",
"title": "This Attribute"
}
},
"name": "Hours",
"value": "9am to 5pm",
"visibility": "private",
"date_created": "2013-08-05T14:15:59-0700",
"date_modified": "2013-08-05T14:15:59-0700"
}