Documentation Index
Fetch the complete documentation index at: https://docs.linkutm.com/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Permissions are derived from a user’s role in a workspace. Each workspace membership has a role, and each role grants a fixed set of permission actions. These endpoints let you read the caller’s effective permissions for a given workspace. Endpoints live under/api/v1/permissions and require a JWT bearer token plus the x-workspace-id header.
Permissions are resolved from the caller’s
WorkspaceMember record for the workspace in x-workspace-id. If the caller is not a member of that workspace, an empty permission set is returned - the endpoints do not error in that case.Get my permissions
x-workspace-id.
Headers
| Header | Required | Notes |
|---|---|---|
Authorization: Bearer <jwt> | Yes | |
x-workspace-id: <uuid_or_slug> | Yes | Target workspace, by UUID or slug |
Example request
Example response
A JSON array of permission action strings.[].
Check a permission
x-workspace-id.
Headers
| Header | Required | Notes |
|---|---|---|
Authorization: Bearer <jwt> | Yes | |
x-workspace-id: <uuid_or_slug> | Yes | Target workspace, by UUID or slug |
Query parameters
The permission action to check, for example
links.create. See the permission actions table for valid values.Example request
Example response
hasPermission is true only when the caller’s role in the workspace includes the requested action. A missing or unknown action value returns false; the endpoint does not reject it.
Permission actions
The full set of permission actions:| Action | Description |
|---|---|
workspace.manage | Manage workspace settings |
billing.manage | Upgrade or downgrade the plan |
domains.create | Add a custom domain |
domains.update | Update a custom domain |
domains.delete | Delete a custom domain |
team.invite | Invite team members |
team.remove | Remove team members |
utm_rules.manage | Define and edit UTM rules |
utm_templates.create | Create UTM templates |
utm_templates.edit | Edit UTM templates |
utm_templates.delete | Delete UTM templates |
links.create | Create links |
links.edit | Edit links |
links.delete | Delete links |
links.import | Import links |
analytics.view | View link click analytics and GA4 data |
data.export | Export data as CSV |
api_keys.manage | Manage API keys |
Roles and their permissions
There are four built-in roles. The table below shows the default permission set granted to each.| Permission action | owner | admin | member | viewer |
|---|---|---|---|---|
workspace.manage | Yes | - | - | - |
billing.manage | Yes | - | - | - |
domains.create | Yes | Yes | - | - |
domains.update | Yes | Yes | - | - |
domains.delete | Yes | Yes | - | - |
team.invite | Yes | Yes | - | - |
team.remove | Yes | Yes | - | - |
utm_rules.manage | Yes | Yes | - | - |
utm_templates.create | Yes | Yes | Yes | - |
utm_templates.edit | Yes | Yes | Yes | - |
utm_templates.delete | Yes | Yes | Yes | - |
links.create | Yes | Yes | Yes | - |
links.edit | Yes | Yes | Yes | - |
links.delete | Yes | Yes | - | - |
links.import | Yes | Yes | - | - |
analytics.view | Yes | Yes | Yes | Yes |
data.export | Yes | Yes | Yes | - |
api_keys.manage | Yes | Yes | - | - |
Role summary
owner
owner
Full access. Holds every permission action, including
workspace.manage and billing.manage, which no other role has.admin
admin
Holds every permission except
workspace.manage and billing.manage. Can manage domains, team, UTM rules, links, API keys, analytics, and exports.member
member
Can create and edit links, manage UTM templates, view analytics, and export data. Cannot delete or import links, manage domains, manage team, manage UTM rules, or manage API keys.
viewer
viewer
Read-only. Holds
analytics.view only.The table above lists the default role to permission mapping. Effective permissions are read from the
RolePermission records at runtime, so a workspace’s actual mapping may differ if it has been customized.Errors
| Code | When |
|---|---|
401 | Missing or invalid JWT |
429 | Rate limit exceeded (100 requests/minute per IP) |