Completes a waitpoint token, unblocking any run that is waiting for it via wait.forToken(). An optional data payload can be passed and will be returned to the waiting run. If the token is already completed, this is a no-op and returns success: true.
This endpoint accepts both secret API keys and short-lived JWTs (public access tokens), making it safe to call from frontend clients.
Use your project-specific Secret API key. Will start with tr_dev_, tr_prod, tr_stg, etc.
You can find your Secret API key in the API Keys section of your Trigger.dev project dashboard.
Our TypeScript SDK will default to using the value of the TRIGGER_SECRET_KEY environment variable if it is set. If you are using the SDK in a different environment, you can set the key using the configure function.
import { configure } from "@trigger.dev/sdk";
configure({ accessToken: "tr_dev_1234" });
The ID of the waitpoint token to complete.
Any JSON-serializable value to pass back to the run waiting on this token. The data will be returned from wait.forToken() as the result payload.
{
"status": "approved",
"comment": "Looks good to me!"
}
Waitpoint token completed successfully
Always true when the request succeeds.
true