Skip to content

Ask AI

Powered by Blaze

Answers come from E2E Cloud documentation. AI can make mistakes.

Troubleshooting TIR Token Factory

View as Markdown

Every reply from a model carries an X-Request-Id header. When you contact support about a request, include that value, the model ID, the time of the request, and the exact error text. For short answers about keys, models, and billing, see the TIR Token Factory FAQ.

The request carried no key that Token Factory reads. The key must be in the Authorization header, written exactly as Authorization: Bearer <your-api-key> with a capital B. A key in another header such as x-api-key, a lowercase bearer, a different word such as Token in place of Bearer, or an empty value after Bearer all give this error. Fix the header and send the request again; sending it unchanged gives the same error. See Call a model with REST.

The key is wrong, expired, revoked, or blocked. Check it on API Keys in Token Factory:

  • If the key is Expired or no longer on the list, create a new key and use it instead.
  • If it is Blocked and someone in your project blocked it, unblock it; see Block, unblock, or revoke an API key. If its status reads “Blocked by Token Factory support”, contact support with the key’s name, the project’s name, and the time of the failed request.
  • If it is Active, check that your code sends the whole key, with nothing added or cut off, and that it is a Token Factory API key from this project. A TIR Personal Access Token does not work with Token Factory.

404: The requested model is not currently available

Section titled “404: The requested model is not currently available”

Token Factory does not serve the model ID in the request, or the request went to a wrong path. Copy the model ID from the model’s page, with its creator part, such as google/gemma-4-31b-it, and send the request to /chat/completions under https://blaze.e2enetworks.net/v1. If the model was retired from the catalog, choose another; see Choose a model.

400: The upstream provider rejected the request

Section titled “400: The upstream provider rejected the request”

Something in the request itself is wrong, so sending it unchanged gives the same error. Check, in this order:

  • The body is valid JSON and has a messages list.
  • The prompt fits in the model’s context window, shown as Context in the model list.
  • Every optional field is one the model supports. Remove fields one at a time to find the one it refuses.
  • Images go only to a model with Vision, tools only to a model with Tools, and JSON output only to a model with JSON.

See Use tools, JSON output, vision, and reasoning.

The reply’s message reads “Upstream rate limit exceeded. Please retry.” The model is busy with more requests than it can take at the moment. Send the request again after a short wait, and make the wait longer after each failed try. If a model stays busy, choose another model with the capabilities you need; see Choose a model.

The model is unavailable for a moment. Send the request again after a short wait, making the wait longer after each failed try, or switch to another model; see Choose a model.

The fault is on E2E’s side, not with your key. Contact support with the reply’s X-Request-Id, the model ID, the time of the request, and the exact error text.

A request that is not streamed fails if the whole reply takes longer than four minutes. Turn streaming on so the reply arrives as the model writes it; see Call a model with the OpenAI SDK.

A stream that stops before a chunk with a finish reason has failed partway, even though the request started with a success status. Send the request again. To catch this in your code, see Call a model with the OpenAI SDK.

The last chunk of a streamed reply carries only the token usage and has no choices, so code that reads the first choice of every chunk fails on it. Skip chunks without choices; see Call a model with the OpenAI SDK.

The answer is empty and the finish reason is length

Section titled “The answer is empty and the finish reason is length”

The model used all of max_tokens before it finished. On a model with Reasoning, the reasoning counts toward max_tokens too, and it can use them all before the answer starts. Send the request again with a higher max_tokens; see Use tools, JSON output, vision, and reasoning.

This project already has 25 active API keys

Section titled “This project already has 25 active API keys”

A project can have up to 25 active API keys. Revoke a key you no longer use, then create the new one; see Block, unblock, or revoke an API key.

Add credit to your account to create an API key

Section titled “Add credit to your account to create an API key”

On a prepaid account, creating an API key needs a credit balance above zero. Add credit to your account, then create the key again; see Billing and Usage.

TIR shows “Could not check your account’s credit. Please try again.” when it cannot read your account’s credit while you are creating a key. Try again in a moment; see Create an API key.

While Token Factory is blocked for a project, every key in it is refused and no new key can be created. Contact support with the project’s name, the time, and the message you saw.

This API key was blocked by Token Factory support

Section titled “This API key was blocked by Token Factory support”

Token Factory support blocked this key, so you cannot block or unblock it from the project. Contact support with the key’s name, the project’s name, the time, and the message you saw.

TIR shows “Token Factory is unavailable right now. Please try again in a few minutes.” when it cannot load your API keys or usage figures for a moment. If the message stays after a few minutes, contact support with the time you saw it and what you were doing, such as creating a key; see Create an API key.

“Token Factory is busy right now. Please try again in a minute.” means too many requests to manage API keys or load usage figures reached Token Factory at once. Wait a minute, then try again; see Create an API key or Monitor usage and cost, depending on what you were doing.

The key you acted on has already been revoked, so it can no longer be blocked or unblocked. Refresh API Keys; to restore access, create a new key.

The key no longer exists in the project, for example because someone revoked it in another window. Refresh API Keys to see the current list; see Block, unblock, or revoke an API key.

Token Factory pricing is not available right now

Section titled “Token Factory pricing is not available right now”

The model list shows “Token Factory pricing is not available right now. Please try again later.” when it cannot load the prices for your account. Try again later; see Choose a model.

Access Denied! when you open Token Factory

Section titled “Access Denied! when you open Token Factory”

“Your current policies do not permit access to this resource. Please contact your administrator to request access.” means your role or policy does not grant Read access to Token Factory. Ask your administrator for a role or policy with Read access to Token Factory; see Manage project members and policies.

Was this page helpful?