n8n credentials pass but the workflow returns 404: check the endpoint
A successful n8n credential test does not verify the generation route. Separate /models, Chat Completions and Responses with version-specific checks.
A successful n8n OpenAI credential test does not prove that the endpoint used by your workflow is supported. The credential can test the model-list route while generation uses a different route. If the provider accepts /models but not the selected /responses request, the test can pass and the workflow can still fail.
This guide distinguishes the OpenAI credential, the OpenAI action node and the OpenAI Chat Model sub-node. It uses version-specific source evidence rather than assuming that every n8n version has the same defaults. The existing Chinese article records a historical local fixture test; this English edition does not present that old run as a new production test.
Base URL belongs in the credential
The OpenAI credential has a Base URL field. Its purpose is to point compatible nodes at an alternative API root. Use the provider’s documented root, not the full URL of a specific chat or response operation.
For example, a provider root might end in /v1. A generation operation then appends its own path. Pasting a complete /chat/completions URL into a field that expects the root can produce a malformed path when the node appends another endpoint. The exact resulting error depends on the provider; a 404 alone does not identify the cause.
The fixed n8n 2.36.9 credential source shows the Base URL field and a credential test against /models. It does not send a full chat generation request as that test.
Three different operations to keep apart
| Operation | What a success demonstrates | What it does not prove |
|---|---|---|
| Credential test against /models | The model-list request was accepted | That generation supports the same model and credentials |
| Chat Completions request | That particular chat request was accepted | That Responses is also implemented |
| Responses request | That particular response request was accepted | That every chat-compatible model supports this route |
If the provider exposes its model list without authentication, a successful list request is also weak evidence about the key. Do not infer that every provider behaves this way, or that the key is invalid simply because generation fails. Check the provider’s authentication requirements and the actual response.
Identify which node failed
The OpenAI action-node documentation lists different generation operations. The OpenAI Chat Model is a separate sub-node, often connected to an AI Agent, with its own options. Instructions for one should not be blindly applied to the other.
In n8n 2.36.9, the Chat Model implementation exposes the Responses option for node typeVersion 1.3 or later and defines its UI default as true. A saved workflow’s explicit parameters and its runtime behavior still matter. This is a statement about that fixed source version, not a promise about every current installation.
The general documentation and older tutorials can describe a different default. Export the affected node, record its type and typeVersion, and inspect the option actually saved in your workflow. Do not replace that evidence with a screenshot from another release.
Trace the failing request
- Record the n8n version, node type, node typeVersion and operation.
- Confirm the Base URL root and exact model ID without exposing the key.
- Read a redacted request log or provider trace to determine whether the request went to /responses or /chat/completions.
- Compare that route with the provider’s support for the exact model.
- If the model is documented for Chat Completions, select that operation or adjust the Chat Model option, then verify the outgoing route again.
Turning off one option is not a universal guarantee: library behavior or another configured feature can affect route selection. The acceptance check is the actual request path and response, not merely the toggle’s appearance.
Do not replay a production workflow with side effects just to inspect a URL. Isolate the model call with harmless input and disconnect tools that send messages or mutate records. Keep the reproduction small enough that the response can be inspected directly.
A minimal record for support
n8n version:
node type and typeVersion:
selected operation / Responses option:
provider API root:
exact model ID:
observed HTTP method and path:
HTTP status and redacted error body:
request ID, if supplied:
Never paste an API key, authorization header or a full private workflow export into a public issue. A redacted record should preserve the route and error fields while removing credentials and sensitive prompts.
The historical issue #21651 reports a successful credential test and a runtime 404 against a custom provider in n8n 1.118.2. It demonstrates that this symptom has occurred; its existence does not prove that the same old bug remains in your current version.
Do not stop at the first explanation
A 404 can also arise from an incorrect model ID, a provider-specific route, an extra path segment or a reverse proxy. If /chat/completions itself fails, preserve the response and check those possibilities before concluding that Responses compatibility is the only issue.
Our model-not-found troubleshooting guide covers model access and identifiers. The API migration guide explains the broader provider switch. Neither replaces validation of the exact endpoint you are using now.
Frequently Asked Questions
- Can n8n use a custom OpenAI-compatible Base URL?
- Yes. The OpenAI credential exposes the field. Whether a particular node operation works depends on the provider, model and supported endpoint.
- Does the green credential test verify Responses support?
- No. In the fixed source inspected here, the credential test targets /models. Check generation support separately.
- Does a MODEL_NOT_FOUND message always mean the model name is wrong?
- No. Inspect the request path and provider response as well. A wrapper's error category is not enough to distinguish every route failure from an actual model-ID rejection.


