{"type":"api","title":"Regenerate API token","meta":{"id":"/apps/pubhub/media/000-v7-apis/eb73ef9d6f95b0e73b23b4642ac64f87b00a2845/dd92fac8-aef9-3ecd-814c-3bda2fdaeba0","info":{"title":"API Token Management API","description":"Manage your ThousandEyes OpenAPI bearer token.","version":"7.0.88"},"security":[{"BearerAuth":[]}],"tags":[{"name":"API Token"}],"openapi":"3.0.1","servers":[{"description":"ThousandEyes API production URL","url":"https://api.thousandeyes.com/v7"}],"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","description":"Bearer authentication token"}}},"spec":{"tags":["API Token"],"summary":"Regenerate API token","operationId":"regenerateApiToken","description":"Regenerates the bearer token for your account.\n\n- Requires a valid, non-expired bearer token.\n- The new token is valid for 2 years.\n- After regeneration, the previous token remains valid for 14 days, or until its scheduled expiration date, whichever comes first.\n- You can regenerate a new token only if your account has a single active token. Attempts to regenerate more than one new token within the 14-day overlap period returns a 409 error.\n\nUpdate your applications to use the new token immediately.\n","responses":{"201":{"description":"OK","content":{"application/hal+json":{"schema":{"type":"object","properties":{"bearerToken":{"type":"string","description":"The API token for your account.","example":"123e4567-e89b-12d3-a456-426614174000","readOnly":true},"validUntil":{"type":"string","format":"date-time","description":"The date and time when the generated API token will expire.","example":"2024-12-31T23:59:59Z","readOnly":true}},"$$ref":"#/components/schemas/ApiToken"}}}},"401":{"description":"Unauthorized","content":{"application/problem+json":{"schema":{"type":"object","properties":{"error":{"type":"string","example":"invalid_token"},"error_description":{"type":"string","example":"Invalid access token"}},"$$ref":"#/components/schemas/UnauthorizedError"}}},"$$ref":"#/components/responses/401"},"403":{"description":"Insufficient permissions to query endpoint","content":{"application/problem+json":{"schema":{"type":"object","properties":{"type":{"type":"string","description":"A URI reference that identifies the problem type. When this member is not present, its value is assumed to be \"about:blank\"."},"title":{"type":"string","description":"A short, human-readable summary of the problem type."},"status":{"type":"integer","description":"The HTTP status code generated by the origin server for this occurrence of the problem."},"detail":{"type":"string","description":"A human-readable explanation specific to this occurrence of the problem."},"instance":{"type":"string","description":"A URI reference that identifies the specific occurrence of the problem."}},"$$ref":"#/components/schemas/Error"}}},"$$ref":"#/components/responses/403"},"409":{"description":"The user has reached the maximum number of allowed tokens.","content":{"application/problem+json":{"schema":{"type":"object","properties":{"type":{"type":"string","description":"A URI reference that identifies the problem type. When this member is not present, its value is assumed to be \"about:blank\"."},"title":{"type":"string","description":"A short, human-readable summary of the problem type."},"status":{"type":"integer","description":"The HTTP status code generated by the origin server for this occurrence of the problem."},"detail":{"type":"string","description":"A human-readable explanation specific to this occurrence of the problem."},"instance":{"type":"string","description":"A URI reference that identifies the specific occurrence of the problem."}},"$$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal server error","content":{"application/problem+json":{"schema":{"type":"object","properties":{"type":{"type":"string","description":"A URI reference that identifies the problem type. When this member is not present, its value is assumed to be \"about:blank\"."},"title":{"type":"string","description":"A short, human-readable summary of the problem type."},"status":{"type":"integer","description":"The HTTP status code generated by the origin server for this occurrence of the problem."},"detail":{"type":"string","description":"A human-readable explanation specific to this occurrence of the problem."},"instance":{"type":"string","description":"A URI reference that identifies the specific occurrence of the problem."}},"$$ref":"#/components/schemas/Error"},"example":{"type":"about:blank","title":"Internal server error","status":500,"detail":"Optional detail about the internal error message.","instance":"/v7"}}},"$$ref":"#/components/responses/500"}},"__originalOperationId":"regenerateApiToken","security":[{"BearerAuth":[]}],"method":"post","path":"/api-tokens"}}