Skip to content

Commit

Permalink
Enable request context header (#548)
Browse files Browse the repository at this point in the history
* Revert "Remove X-OSDK-Request-Context header"

This reverts commit e1af720.

* Add changeset
  • Loading branch information
bryantpark04 authored Aug 2, 2024
1 parent 0131ade commit f86f8d0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/bright-panthers-lick.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@osdk/client": minor
---

Re-enable X-OSDK-Request-Context header
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ export const addUserAgentAndRequestContextHeaders = (
fetch: createFetchHeaderMutator(
client.fetch,
(headers) => {
headers.set(
"X-OSDK-Request-Context",
JSON.stringify(client.requestContext),
);

if (withMetadata.osdkMetadata) {
headers.set(
"Fetch-User-Agent",
Expand Down

0 comments on commit f86f8d0

Please sign in to comment.