CLI — Access tokens
Manage account access tokens. Requires a
dft_ admin token. You can scope tokens to specific permissions and websites.For REST usage, see Account API tokens. For token type differences, see authentication and scopes.
List all tokens
datafast tokens list
Create a token
Run without flags for an interactive prompt (name, permissions, optional website scope):
datafast tokens create
Or pass flags to skip the prompts:
# Full access token
datafast tokens create --name "CI token" --permissions "*"
# Scoped to specific permissions
datafast tokens create --name "Read only" --permissions "analytics:read,websites:read"
# Scoped to specific websites
datafast tokens create --name "Site A token" --permissions "*" --websites <id1>,<id2>
Valid permissions:
analytics:read, websites:read, websites:write, api-keys:read, api-keys:write, team:read, team:write, alerts:read, alerts:write, settings:read, settings:write, or * for full access.Delete a token
datafast tokens delete <tokenId>
# Skip the confirmation prompt
datafast tokens delete <tokenId> --yes
When you create a token, the raw
dft_ key is copied to your clipboard automatically.