Documentation
Your own workers
View .mdOpenAPI

Revoke a worker join token

POSThttps://weights.fyi/run/v1/nodes/join-tokens/{join_token_id}/revokescope: manage
text
POST https://weights.fyi/run/v1/nodes/join-tokens/<join_token_id>/revoke
Authorization: Bearer <token>                    scope: manage
Available since
2026-10-19 worker enrollment: answered only where this service enrolls your own workers (otherwise the path answers 404); see Bring your own model.
Answer time
synchronous: the token is turned off at once.

Turns off a join token that no worker has used yet. A join token is the single-use secret, beginning wjt_, that lets one worker of your own enroll into the workspace; a worker that presents a revoked token is refused. Use this when a token was pasted somewhere it should not be, or a setup was abandoned before the token expired. The call takes no body and is safe to repeat: a token already revoked answers its first revoked_at again.

A token a worker has already enrolled with is spent and cannot be revoked. That worker now holds its own certificate, so end its enrollment with the worker's revoke call instead. The worker's own enrollment and certificate calls are made by the weights agent with its join token, not with a workspace key, and are not part of this reference.

Request

NameWhereRequiredMeaning
AuthorizationheaderyesBearer and a token with manage.
join_token_idpathyesThe token's id from the answer that made it; GET /v1/nodes also shows it as join_token_id on a worker that used one.

Return value

200 OK:

FieldMeaning
idThe token's number.
workspace_idIts workspace.
revoked_atWhen it was revoked; the first time, when the call is repeated.

Errors

StatusCodeWhen it happensWhat to do
401unauthorized, invalid_token, token_revoked, token_expiredNo token, or one that does not work (any more).Use a valid token.
403scope_required, account_suspendedThe token lacks manage, or the account is suspended.Use a token with manage.
404join_token_not_foundYour workspace has no join token of that number, or the id is not a positive whole number.Use the id from the answer that made the token.
409join_token_usedA worker already enrolled with it.Revoke the worker instead.
503byoc_unavailableWorker enrollment is not available on this service right now.Retry later.

Examples

sh
curl -s -X POST https://weights.fyi/run/v1/nodes/join-tokens/JOIN_TOKEN_ID/revoke \
  -H "Authorization: Bearer $WEIGHTS_API_KEY"
json
{"id": 12, "workspace_id": 7, "revoked_at": "2026-11-14T09:45:00+00:00"}

History

  • 2026-10-19: built.
  • 2026-11-16: this page added.

See also