Skip to content

Rebuild Requesty node on Responses API (@n8n/node-cli, verification-ready) - #2

Merged
Thibaultjaigu merged 33 commits into
mainfrom
requesty-node
Jun 2, 2026
Merged

Rebuild Requesty node on Responses API (@n8n/node-cli, verification-ready)#2
Thibaultjaigu merged 33 commits into
mainfrom
requesty-node

Conversation

@Thibaultjaigu

Copy link
Copy Markdown
Contributor

Clean rebuild of the Requesty n8n community node on the @n8n/node-cli tooling, replacing the original pre-rewrite package.

What this is

A Requesty Chat Model sub-node usable anywhere n8n accepts a chat model (AI Agent, Basic LLM Chain, etc.), backed by the OpenAI Responses API via @n8n/ai-node-sdk.

Highlights

  • Always Responses API — no toggle, unlocks richer features
  • Real structured output via text.format (strict json_schema / json_object) — API-enforced, accepts bare schema or {name, strict, schema} wrapper
  • Native web search provider tool (enable + context size)
  • Reasoning effort (low/medium/high), only sent when explicitly set
  • Base URL override on node and credential for self-hosted deployments
  • Dynamic model dropdown from /models

Quality / tooling

  • 13 Jest unit tests covering supplyData wiring
  • n8n-node lint passes in strict mode (verification rules)
  • CI: lint + build + test on PR/main
  • Publish: npm publish --provenance on GitHub Release (OIDC), package-lock.json committed
  • Removes legacy files (old nodes/Requesty, gulpfile, tslint, etc.)

Known external dependency

Requires the Requesty gateway to emit annotations: [] on output_text content parts per the OpenResponses spec (OutputTextContent.required); otherwise the Responses parser throws Cannot read properties of undefined (reading 'map').

🤖 Generated with Claude Code

- Response Format option (Text / JSON Object / JSON Schema) for real
  API-enforced structured output via response_format + strict mode
- Use Responses API toggle (useResponsesApi)
- Enable Web Search with context size and country, wired as a web_search
  provider tool
Structured output on the Responses API is expressed via text.format
(json_schema / json_object), not the Chat Completions response_format.
Accepts either a bare JSON schema or a full {name, strict, schema} wrapper.
The Requesty node is now Responses-API-first. The 'Use Responses API'
option is removed and useResponsesApi is always true.
Lets self-hosted customers point the node at their own gateway. The
override applies to both the model-list request and chat requests, and
falls back to the public gateway when empty.
Exposes low/medium/high reasoning effort for reasoning-capable models,
wired to the Responses API reasoning.effort parameter.
Drops the country/location option so web search behaves uniformly across
the different providers unified behind the Requesty gateway.
Updates the options table and feature list to cover structured output,
web search, reasoning effort and the self-hosted Base URL override.
Branch 3 now exercises the Requesty node's Response Format = JSON Schema
(real API-enforced structured output) instead of the prompt-based
Structured Output Parser.
Previously reasoning effort defaulted to medium and was sent on every
request, which non-reasoning models can reject. Adds a 'Default' (unset)
option and omits reasoning unless the user picks a level.
The node is always on the Responses API now, so the qualifier is obsolete.
Self-hosted customers can now set their gateway URL on the credential so
the connection test validates against their own deployment. The node's
Base URL option overrides it per-node, falling back to credential then
the public gateway.
Adds jest + ts-jest with 13 tests covering supplyData: always-on
Responses API, base URL override, structured output text.format (json
object, wrapped + bare schema), web search tool, reasoning effort, and
invalid-schema error handling. Tests live in __tests__/ to stay outside
the n8n-node lint scope; only dist/ is published.
Enables 'npm ci --legacy-peer-deps' in CI and publish workflows for fast,
deterministic installs.
Uses 'npm ci --legacy-peer-deps' against the committed lockfile and adds
the test step.
…ckage

- Replace prepublishOnly (which blocked npm publish) with a prepack build
- Drop the interactive release script in favor of CI publishing
- Disable incremental builds so a clean build always emits JS and the
  250kB tsbuildinfo cache never ships in the tarball
Triggers on release published (and manual dispatch), installs with the
lockfile, lints, builds, tests, then runs 'npm publish --provenance'.
Replaces the tag-triggered 'npm run release' which could self-trigger.
Drops the old node (nodes/Requesty), gulpfile, tslint, index.js and
stale eslint/prettier/npmignore configs left over from the original
package, leaving only the @n8n/node-cli based rebuild.
Selecting Response Format = JSON Schema with an empty/missing schema
field crashed with "Cannot use 'in' operator to search for 'schema' in
undefined". Now throws a clear error telling the user to provide a
schema, and validates the parsed value is an object. Adds tests for the
empty and undefined cases.
These were inside the Options collection, where n8n fails to render the
editor (no input area) and the conditional show/hide is unreliable —
users could select JSON Schema but had nowhere to enter the schema.
Moving them to top-level fields fixes both the editor and the
displayOptions that reveals the schema only for JSON Schema format.
@Thibaultjaigu
Thibaultjaigu merged commit 77aa4cd into main Jun 2, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant