Endpoints - Management - Tags

Tags

 

Model

A tag is an entity used to provide an alternative classification of Datapoints and Groups in ClickMeter, this is the model represented through JSON for API interaction. Some fields are maked as optional as in they don’t need to be present in a minimum working tag.

Tag Model

GET /tags

Retrieve a list of tags associated to the current authenticated user.

This endpoint has optional filters that can be used in the GET request to change its response behaviour.

Result: EntityURIList (see “Common models”)

Filters:

  • offset [optional] [integer, 0] : Where to start when retrieving tags

  • limit [optional] [integer, 20] : Maximum elements to retrieve

  • createdBefore [optional] [string] : A date in the format YYYYMMDDHHmm that will filter by creation date of the tag

  • createdAfter [optional] [string] : A date in the format YYYYMMDDHHmm that will filter by creation date of the tag

  • name[optional] [string, all] : A pattern name expression. Example: twit*

  • groups [optional] [string] :A comma separated list of group id you want to filter with. Example: 223,456

  • datapoints [optional] [string] :A comma separated list of datapoint id you want to filter with. Example: 223,456

 

GET /tags/count

Retrieve a count of the tags associated to the current authenticated user.

This endpoint has optional filters that can be used in the GET request to change its response behaviour.

Result: CountObject (see “Common models”)

Filters:

  • createdBefore [optional] [string] : A date in the format YYYYMMDDHHmm that will filter by creation date of the tag

  • createdAfter [optional] [string] : A date in the format YYYYMMDDHHmm that will filter by creation date of the tag

  • name[optional] [string, all] : A pattern name expression. Example: twit*

  • groups [optional] [string] :A comma separated list of datapoint id you want to filter with. Example: 223,456

 

POST /tags

Create a tag for the current authenticated user.

Input: Tag (one without id)

Result: EntityURI (uri of the newly created tag)

 

GET /tags/{id}

Retrieve the tag {id} for the current authenticated user.

Result: Tag

 

DELETE /tags/{id}

Delete the tag {id} for the current authenticated user.

Result: EntityURI

 

POST /tags/{id}

Update the tag {id} for the current authenticated user.

Input: Tag (the one you fetched from GET /tags/{id} with your modifications)

Result: EntityURI

 

GET /tags/{id}/datapoints

Retrieve a list of datapoints associated to the current authenticated user for the tag {id}.

This endpoint has optional filters that can be used in the GET request to change its response behaviour.

Result: EntityUriList (see “Common models”)

Filters:

  • offset [optional] [integer, 0] : Where to start when retrieving datapoints

  • limit [optional] [integer, 20] : Maximum elements to retrieve

  • createdBefore [optional] [string] : A date in the format YYYYMMDDHHmm thath will filter by creation date of the datapoint

  • createdAfter [optional] [string] : A date in the format YYYYMMDDHHmm thath will filter by creation date of the datapoint

  • type [optional] [string] : Type of datapoint to retrieve (TL is tracking link, TP is trackinge pixel)

  • status [optional] [string, all] : Status of the datapoint, possible statuses are active, deleted, paused, spam, deleted and all (all statuses)

 

GET /tags/{id}/groups

Retrieve a list of groups associated to the current authenticated user for the tag {id}.

This endpoint has optional filters that can be used in the GET request to change its response behaviour.

Result: EntityURIList (see “Common models”)

Filters:

  • offset [optional] [integer, 0] : Where to start when retrieving groups

  • limit [optional] [integer, 20] : Maximum elements to retrieve

  • createdBefore [optional] [string] : A date in the format YYYYMMDDHHmm that will filter by creation date of the group

  • createdAfter [optional] [string] : A date in the format YYYYMMDDHHmm that will filter by creation date of the group

  • status [optional] [string, all] : Status of the datapoint, possible statuses are active, deleted, and all (all statuses)

 

PUT /tags/{id}/datapoints/patch

Assign to the tag {id} the datapoint specified in the input object.

Input: PatchRequest (see here)

Result: Tag

 

PUT /tags/{id}/groups/patch

Assign to the tag {id} the group specified in the input object.

Input: PatchRequest (see here)

Result: Tag

For more info read this FAQ: 

Have more questions? Submit a request

0 Comments

Article is closed for comments.