Skip to main content

TagUserByOpenID

Add tags to contacts according to OpenID. Ensure that imported tags have been created in SmartLink > Contacts > Tag management.

POST /api/v3/userinfo/tag_user_by_openid

Request parameters

For more information on the query parameters, see Query parameters.

AttributeData typeRemarksDescription
openidstringrequiredUnique user ID (up to 20 numeric characters)
modify_tsbigintrequiredTimestamp of last update (in milliseconds)
tags[]stringrequiredCustom tags for the grouping of users, used in user segmentation:
  • Ensure the imported tags have been created in SmartLink > Contacts > Tag management, else the update will fail.
  • Tags can only be added, existing tags will not be overwritten.
  • Each user can be associated with up to 100 tags.

Request sample

curl --request POST "https://openapi.smartlink.intlgame.com/api/v3/userinfo/tag_user_by_openid?gameid=${GAME_ID}&seq=${YOUR_RANDOM_STRING}&sig=${SIGNATURE}&ts=${TS}" \
--header 'Content-Type: application/json' \
--data-raw '{
"openid": "1012156612344364",
"modify_ts": 1691225447577,
"tags": [
"tag1",
"tag2"
]
}'

Response parameters

AttributeData typeDescription
codeintReturn code
msgstringReturn message

Response sample

{
"code": 0,
"msg": "Success",
"seq": "{YOUR_RANDOM_STRING}"
}