Help Center/ DataArts Insight/ API Reference/ User Tags/ Saving User Tag Content (by User)
Updated on 2025-02-25 GMT+08:00

Saving User Tag Content (by User)

Function

This API is used to save user tag content by user.

URI

PUT /v1/{project_id}/tags/{tag_id}/values

Table 1 URI parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

project_id

tag_id

Yes

String

tag_id

Request Parameters

Table 2 Request header parameter

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token. Obtain a user token by calling IAM's "Obtaining a User Token" API. X-Subject-Token in the response header is the desired user token.

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

user_id

Yes

String

userId

value

No

Array of strings

value

value_type

No

String

Default tag value type. The default value is NULL.

  • DEFAULT: Default value, which is the default tag value.
  • NULL: Null.
  • ALL: All values.
  • ENUM: Enumerated values. default_value must be set to an enumerated value.

Response Parameters

Status code: 200

Table 4 Response body parameter

Parameter

Type

Description

{Custom key}

Map<String,String>

  

Example Request

The user tag content is saved.

PUT https://{endpoint}/v1/{project_id}/tags/{tag_id}/values

{
  "user_id" : "bf32ac8de8c64d738caceede9a00d136",
  "value_type" : "ENUM",
  "value" : [ "10086" ]
}

Example Response

Status code: 200

The user tag content is successfully saved.

{
  "data" : true
}

Status Codes

Status Code

Description

200

The user tag content is successfully saved.

Error Codes

See Error Codes.