Skip to content

Subrequest headers#1038

Open
xeioex wants to merge 1 commit intonginx:masterfrom
xeioex:subrequest_headers
Open

Subrequest headers#1038
xeioex wants to merge 1 commit intonginx:masterfrom
xeioex:subrequest_headers

Conversation

@xeioex
Copy link
Contributor

@xeioex xeioex commented Mar 21, 2026

No description provided.

@xeioex xeioex force-pushed the subrequest_headers branch 2 times, most recently from 716d24f to 04cb358 Compare March 24, 2026 00:00
The option allows JavaScript code to pass custom request headers
to subrequests:

    r.subrequest('/api', {headers: {'X-Token': secret}})

The option accepts a JavaScript object whose keys and values are
added as request headers to the subrequest.  Parent request headers
are inherited by default; user-supplied headers override matching
parent headers using case-insensitive comparison.

Transport-level headers (Connection, Content-Length,
Transfer-Encoding, Expect) supplied by the caller are silently
ignored.  When a body is provided, Content-Length is derived from
the actual body size regardless of what the caller passes.
@xeioex xeioex force-pushed the subrequest_headers branch from 04cb358 to c5c15c3 Compare March 24, 2026 00:48
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