> For the complete documentation index, see [llms.txt](https://docs-old.telematicssdk.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs-old.telematicssdk.com/sdk-features/tags/period-tag.md).

# Tags for period

### ACTIVATE TAG

Method is used for activation of tag. All new trips that will be received from a virtual device, will be marked with this tag until its deactivation.

\
**URL:** <https://mobilesdk.telematicssdk.com/mobilesdk/incoming/tags/activate\\>
**HTTP METHOD**: POST\
**HEADERS:**\
DeviceToken: 194df5b4-5322-43f5-bea7-16d85debfd00\
**REQUEST BODY:**\
\&#xNAN;***Tag:*** tag name. String. All symbols and spaces allowed. Value is required.\
\&#xNAN;***Type:*** type of tag. Now only “SDK” and “UserApp” are supported. Value is required.\
\&#xNAN;***Source:*** ID of tag activation source. String. Optional value.\
\&#xNAN;***ActivationTime:*** ISO 8601 with time-zone. Optional value. If empty, the server value will be used.

\
**Example request body**

```
{
    "Tag": "Sample Tag 1",
    "Type": "SDK",
    "Source": "",
    "ActivationTime": "2019-11-22T14:19:36+03:00"
}
```

**RESPONSE:**\
Success

```
{
    "Result": {
        "Code": 200
    }
}
```

Error

```
{
    "Error": {
        "Code": 400
    }
}
```

<br>

NOTE: If you try to activate the previously activated tag, the error will be returned. Activation of already active tag is not allowed.

### DEACTIVATE TAG

Method is used for deactivation of tag, that is used for marking the trips received from a virtual device.

\
**URL:** <https://mobilesdk.telematicssdk.com/mobilesdk/incoming/tags/deactivate\\>
**HTTP METHOD**: POST\
**HEADERS:**\
DeviceToken: 194df5b4-5322-43f5-bea7-16d85debfd00\
**REQUEST BODY:**\
\&#xNAN;***Tag:*** tag name. String. All symbols and spaces allowed. Value is required.\
\&#xNAN;***Type:*** type of tag. Now only “SDK” and “UserApp” are supported. Value is required.\
\&#xNAN;***Source:*** ID of tag activation source. String. Optional value.\
\&#xNAN;***DeactivationTime:*** ISO 8601 with time-zone. Optional value. If empty, the server value will be used.

**Example request body**

```
{
    "Tag": "Sample Tag 1",
    "Type": "SDK",
    "Source": "",
    "DeactivationTime": "2019-11-22T14:19:36+03:00"
}
```

**RESPONSE:**\
Success

```
{
    "Result": {
        "Code": 200
    }
}
```

\
&#x20;Error

```
{
    "Error": {
        "Code": 400
    }
}
```

NOTE: If you try to deactivate the non-active tag, the error will be returned.

### GET ACTIVE TAGS

Method will be used for receiving the list of active tags on the specified date.

\
**URL:** <https://mobilesdk.telematicssdk.com/mobilesdk/incoming/tags/get/{utc\\_unixtimestamp}\\>
**HTTP METHOD**: GET\
**HEADERS:**\
DeviceToken: 194df5b4-5322-43f5-bea7-16d85debfd00\
**REQUEST:**\
{utc\_unixtimestamp} - UTC in UNIX timestamp, when a moment of active tags. Optional. If not specified - the current time will be used. Example: 1574424517<br>

**RESPONSE:**\
&#x20;Success

```
{
  "Result": {
    [
      {
        "Tag": "Sample tag 1",
        "Type": "SDK",
        "Source": "",
        "ActivationTime": "2019-11-22T14:19:36+03:00",
        "IsServerActivationTime": true
      },
      {
        "Tag": "Sample tag 2",
        "Type": "SDK",
        "Source": "",
        "ActivationTime": "2019-11-21T12:15:00-04:00",
        "IsServerActivationTime": false
      }
    ],
    "Code": 200
  }
```

***Tag:*** tag name. String. All symbols and spaces allowed. Value is required.\
\&#xNAN;***Type:*** type of tag. Now only “SDK” and “UserApp” are supported. Value is required.\
\&#xNAN;***Source:*** ID of tag activation source. String. Optional value.\
\&#xNAN;***ActivationTime:*** ISO 8601 with time-zone. Optional value. If empty, the server name will be used.\
\&#xNAN;***IsServerActivationTime:*** logic value. True - if the server value was used. False - if the user value was used.<br>

\
&#x20;Error

```
{
    "Error": {
        "Code": 400
    }
}
```
