You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|**Variables only**| Read and write environment variables in this environment |
94
94
|**No restrictions**| Full access to the environment |
95
95
96
96
**Trigger only** and **Task operator** can be restricted to selected tasks. Task restrictions use task identifiers, such as `send-email`. A request involving multiple tasks — such as a batch trigger — succeeds only when the key can access every task in the request, so a task-restricted key can batch-trigger only its selected tasks.
97
97
98
+
## Deploy with an API key
99
+
100
+
Set a key in `TRIGGER_ACCESS_TOKEN` to authenticate `trigger deploy` without logging in.
The key must belong to the target environment. Use a Production key for the default deployment, a Staging key with `--env staging`, or a key from the Preview environment with `--env preview`. A Preview deployment key can create and archive Preview branches and sync their environment variables.
110
+
111
+
<Note>
112
+
The deploy CLI reads environment API keys from `TRIGGER_ACCESS_TOKEN`, not
113
+
`TRIGGER_SECRET_KEY`. Setting an API key in `TRIGGER_ACCESS_TOKEN` takes precedence over a saved
114
+
CLI login.
115
+
</Note>
116
+
98
117
## Expire and revoke keys
99
118
100
119
Set an expiration date when creating a key if the integration only needs temporary access. An expired key stops authenticating automatically.
@@ -115,7 +134,7 @@ Public access tokens signed with the previous root key remain valid until the ea
115
134
116
135
## Create public access tokens
117
136
118
-
API keys can be used create scoped [Public Access Tokens](/realtime/auth) using `auth.createPublicToken()`.
137
+
API keys can be used to create scoped [Public Access Tokens](/realtime/auth) using `auth.createPublicToken()`.
119
138
120
139
In order to do so with the newer non-root keys, you must use `@trigger.dev/sdk` version 4.5.8 or later. Creating public tokens with non-root keys has the following restrictions:
0 commit comments