Tagging users from your backend system is a common way of targeting tips at users in real-time or creating segments.

Its simple to do, you are targeting:

  • the unique ID for a user in your backend system (usually an email address, account number or a UUID). Pointzi does not care what the ID is as long as you've sent that ID from the App side (usually when a user logs in). The tag goes to all phones/tablets of the specified user ID (we call this "sh_cuid").
  • The tag name is what you want to call it. In the example below "Plan-49" is how you will see this in the Pointzi Dashboard.
  • Pointzi supports tags of: string, numeric and datetime. In the example below, the value for "Plan-49" is "Trial-Period".



import requests

# Get the <HOST>, <APP_KEY> and <AUTH_TOKEN> on the Settings Page of the Pointzi Dashboard.
HOST = "<...>" 
APP_KEY = "<...>"
AUTH_TOKEN = "<...>"


r = requests.post(
   HOST + '/v3/tags',
    json=[{
        "sh_cuid": "example@acme.com", # your unique userID, doesn't have to be email address
        "key": "Plan-49",
        "string": "Trial-Period",
    }],
    headers={
        'Content-Type': 'application/json',
        'X-App-Key': APP_KEY,
        'X-Auth-Token': AUTH_TOKEN,
    }
)

print(r.json())