Skip to content

Tags ​

Manage vehicles and user categorization through unstructured tags.

Get List of Tags ​

Lists tags available in the account, including tags for Trips, Cars and Users. Tags are a free-form way to categorize things across an account.

GET

http
https://api.zubiecar.com/api/v2/zinc/tags
Sample response 200
json
{
  "tags": [
    {
      "color": "#CCCCCC",
      "key": "SampleKey",
      "type": "Car",
      "value": "Blue Cars"
    }
  ]
}

Create Tag ​

Create a new tag available for the whole account.

POST

http
https://api.zubiecar.com/api/v2/zinc/tags

Request Body Schema

PropertyTypeDescription
colorstringHex color value used for tag display in app.
typestringType of tag. Must be Car, Trip or User.
valuestring requiredGroup name.
Sample request body
json
{
  "color": "#CCCCCC",
  "type": "Car",
  "value": "At Risk Drivers"
}
Sample response 201
json
{
    "color": "#CCCCCC",
    "key": "agpzflj1BmllY2FyckILEgdBY2NvdW50IhZSRmRva5RrYTg0V0xVVGI5ZkhKM29iBfdsaA1RhZyIWNlM3a1c5TnBOd1VZSmtqYkhCUk1ISww",
    "type": "Car",
    "value": "At Risk Drivers"
}

Get a tag by key ​

Retrieve a specific tag.

GET

http
https://api.zubiecar.com/api/v2/zinc/tag/{tag_key}

Path Parameters

PropertyTypeDescription
tag_keyrequiredUnique tag key.
Sample response 200
json
{
  "color": "#CCCCCC",
  "key": "SampleKey",
  "type": "Car",
  "value": "Blue Cars"
}

Update Tag ​

Update a Tag name or color.

POST

http
https://api.zubiecar.com/api/v2/zinc/tag/{tag_key}

Path Parameters

PropertyTypeDescription
tag_keyrequiredUnique tag key.

Request Body Schema

PropertyTypeDescription
colorstringHex color code of the tag.
valuestringLabel for the tag.
Sample request body
json
{
  "color": "#CCCCCC",
  "value": "At Risk Drivers"
}

Apply Tag ​

Apply Tags to Trips, Cars or Users.

POST

http
https://api.zubiecar.com/api/v2/zinc/tag/{tag_key}/apply

Path Parameters

PropertyTypeDescription
tag_keyrequiredUnique tag key.

Request Body Schema

PropertyTypeDescription
actionstringDefault: add
Whether to add or remove the tag from entities.
entity_keysArray of strings requiredMust be valid keys associated with tag type Cars, Trips or Users.
Sample request body
json
{
  "action": "add",
  "entity_keys": [
    "SampleKey1",
    "SampleKey2"
  ]
}