Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.
createProxyFetch from @major-tech/resource-client returns a fetch-compatible function that sends every request through a connector. Major checks the URL against the connector, injects the connector’s credentials, and streams the response back. Your code never sees the API key.Use it when:
You want a third-party SDK that accepts a custom fetch (Stripe, Twilio, OpenAI-compatible APIs, and so on) to run on a connected account.
MAJOR_API_BASE_URL and MAJOR_JWT_TOKEN are set for you in the editor preview and after deploy. The call looks like a normal fetch to the upstream URL. Under the hood it goes to /v1/proxy/<resourceId> with the target URL in a header.
Option
Required
Description
baseUrl
Yes
The Major API base URL. Use process.env.MAJOR_API_BASE_URL.
resourceId
Yes
The connector’s id.
majorJwtToken
Yes
The app’s token. Use process.env.MAJOR_JWT_TOKEN.
timeoutMs
No
Default request timeout. Maximum 60000.
fetch
No
A custom fetch implementation. Defaults to globalThis.fetch.
Pass resourceId as a string literal or an environment variable read at module scope. Major finds the connectors your app uses by reading your code at deploy, so an id computed at runtime isn’t tracked and calls with it fail.
Use it with an SDK
Hand the proxy fetch to any SDK that accepts one. The SDK may insist on an API key in its constructor. Pass a placeholder: the proxy strips it and injects the real credential.
For connectors that use per-user connections (such as Gmail, Google Calendar, or Google Drive), the /next entry forwards the signed-in user’s identity automatically, so each request uses that user’s connected account.Outside a user request, such as a background job, there is no user to forward, and calls to per-user connectors fail. Shared connectors keep working.Outside Next.js, for example in a skill script or plain Node, import createProxyFetch from @major-tech/resource-client (the package root). It has no Next.js dependency and takes an optional getUserJwt function if you have a user token to forward.
Headers and limits
Don’t set Authorization. The proxy injects the connector’s credentials and strips any Authorization you send.
These request headers are always stripped: Authorization, Cookie, Host, Forwarded, X-Forwarded-*, X-Real-Ip, and anything starting with X-Major- or X-Pd-. The exception is X-Major-Timeout-Ms, which sets the timeout for one request.
The target URL must be one the connector allows, usually the service’s API host.
The target must resolve to a public address. A request to a loopback, private, link-local, or other internal address, directly or through a redirect, fails with 403 and the error destination_blocked.
Redirects are followed for up to 10 hops. A redirect from https to http is refused.
The target URL must use https and must not name a port, not even :443. Requests to http:// URLs or to any explicit port are refused.
When a redirect goes to a different host, Major sends only the Accept, Accept-Encoding, Accept-Language, and User-Agent headers on that hop, so the connector’s credentials and any custom headers stay on the original host. A subdomain or a different port counts as a different host. A cross-host 307 or 308 redirect that would resend the request body is refused. Redirects that stay on the same host keep all headers.
Request and response bodies are limited to 50 MB. Timeouts are capped at 60 seconds.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Major","colors":{"primary":"#02906f","light":"#3fa78d","dark":"#006551"},"logo":{"light":"https://mintcdn.com/major-5cc5eebc/X12oJWlEd93WI1uJ/logo/light.svg?fit=max\u0026auto=format\u0026n=X12oJWlEd93WI1uJ\u0026q=85\u0026s=8e7603184824ca90c12dc6dce0935096","dark":"https://mintcdn.com/major-5cc5eebc/X12oJWlEd93WI1uJ/logo/dark.svg?fit=max\u0026auto=format\u0026n=X12oJWlEd93WI1uJ\u0026q=85\u0026s=4fb2271682a769c2c69e65b232e4ec7c"},"favicon":"https://mintcdn.com/major-5cc5eebc/jHCFlO-DV3FrwinJ/favicon.png?fit=max\u0026auto=format\u0026n=jHCFlO-DV3FrwinJ\u0026q=85\u0026s=f0c08c104c41e7cf3bbdf4612f048ae5","navbar":{"links":[{"href":"mailto:support@major.build","label":"Support"}],"primary":{"type":"button","label":"Launch Major","href":"https://app.major.build"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"App editor","icon":"window","href":"https://app.major.build"},{"anchor":"CLI repository","icon":"github","href":"https://github.com/major-technology/cli"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"major-5cc5eebc","hasAudioNarration":false,"actualSubdomain":"major-5cc5eebc","customDomains":["docs.major.build"],"gitSource":{"type":"github","owner":"major-technology","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{},"buildId":"6af677bfa29c450d6ad1f946","clientVersion":"0.0.4131","searchFilterCounts":[{"language":"default","tag":"Learn","count":33},{"language":"default","tag":"Apps","count":14},{"language":"default","tag":"Reference","count":13},{"language":"default","tag":"CLI","count":12},{"language":"default","tag":"Settings","count":8},{"language":"default","tag":"Agents","count":6},{"language":"default","tag":"Triggers","count":5},{"language":"default","tag":"Build","count":3},{"language":"default","tag":"Get Started","count":3},{"language":"default","tag":"Connectors","count":3}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"@media (min-width: 768px){.mdx-content table{table-layout:fixed}.mdx-content table tr>:first-child:nth-last-child(2){width:32%}.mdx-content table tr>:first-child:nth-last-child(n+3){width:22%}.mdx-content table th,.mdx-content table td{min-width:0!important;overflow-wrap:anywhere}}"}],"page":{"pagePath":"learn/connectors/proxy-fetch","slug":"/learn/connectors/proxy-fetch","pageMetadata":{"title":"Proxy fetch","description":"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.","href":"/learn/connectors/proxy-fetch"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[_jsx(_components.code,{children:`createProxyFetch`}),` from `,_jsx(_components.code,{children:`@major-tech/resource-client`}),` returns a `,_jsx(_components.code,{children:`fetch`}),`-compatible function that sends every request through a `,_jsx(_components.a,{href:`/learn/connectors/overview`,children:`connector`}),`. Major checks the URL against the connector, injects the connector’s credentials, and streams the response back. Your code never sees the API key.`]}),`\n`,_jsx(_components.p,{children:`Use it when:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`You want a third-party SDK that accepts a custom `,_jsx(_components.code,{children:`fetch`}),` (Stripe, Twilio, OpenAI-compatible APIs, and so on) to run on a connected account.`]}),`\n`,_jsxs(_components.li,{children:[`You need an endpoint the `,_jsx(_components.a,{href:`/learn/connectors/resource-client`,children:`resource client`}),` doesn’t cover.`]}),`\n`,_jsxs(_components.li,{children:[`The connector has no generated client, such as most `,_jsx(_components.a,{href:`/reference/connectors`,children:`catalog connectors`}),`.`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`Prefer the resource client when it covers what you need, since it gives you typed inputs and outputs.`}),`\n`,_jsx(Heading,{level:`2`,id:`create-a-proxy-fetch`,children:`Create a proxy fetch`}),`\n`,_jsxs(_components.p,{children:[`In a Next.js app, import from `,_jsx(_components.code,{children:`@major-tech/resource-client/next`}),` and call it from server code (Server Components, Route Handlers, Server Actions):`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`13`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`13`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`createProxyFetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"@major-tech/resource-client/next\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` proxyFetch`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` createProxyFetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` baseUrl:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`MAJOR_API_BASE_URL`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` resourceId:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`HUBSPOT_RESOURCE_ID`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` majorJwtToken:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`MAJOR_JWT_TOKEN`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` res`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` proxyFetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://api.hubapi.com/crm/v3/objects/contacts\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` method:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"GET\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` headers:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Content-Type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"application/json\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` data`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` res`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`json`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`MAJOR_API_BASE_URL`}),` and `,_jsx(_components.code,{children:`MAJOR_JWT_TOKEN`}),` are set for you in the editor preview and after deploy. The call looks like a normal `,_jsx(_components.code,{children:`fetch`}),` to the upstream URL. Under the hood it goes to `,_jsx(_components.code,{children:`/v1/proxy/\u003cresourceId>`}),` with the target URL in a header.`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Option`}),_jsx(_components.th,{children:`Required`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`baseUrl`})}),_jsx(_components.td,{children:`Yes`}),_jsxs(_components.td,{children:[`The Major API base URL. Use `,_jsx(_components.code,{children:`process.env.MAJOR_API_BASE_URL`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`resourceId`})}),_jsx(_components.td,{children:`Yes`}),_jsx(_components.td,{children:`The connector’s id.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`majorJwtToken`})}),_jsx(_components.td,{children:`Yes`}),_jsxs(_components.td,{children:[`The app’s token. Use `,_jsx(_components.code,{children:`process.env.MAJOR_JWT_TOKEN`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`timeoutMs`})}),_jsx(_components.td,{children:`No`}),_jsx(_components.td,{children:`Default request timeout. Maximum 60000.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`fetch`})}),_jsx(_components.td,{children:`No`}),_jsxs(_components.td,{children:[`A custom `,_jsx(_components.code,{children:`fetch`}),` implementation. Defaults to `,_jsx(_components.code,{children:`globalThis.fetch`}),`.`]})]})]})]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`Pass `,_jsx(_components.code,{children:`resourceId`}),` as a string literal or an environment variable read at module scope. Major finds the connectors your app uses by reading your code at deploy, so an id computed at runtime isn’t tracked and calls with it fail.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`use-it-with-an-sdk`,children:`Use it with an SDK`}),`\n`,_jsx(_components.p,{children:`Hand the proxy fetch to any SDK that accepts one. The SDK may insist on an API key in its constructor. Pass a placeholder: the proxy strips it and injects the real credential.`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`14`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`14`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` Stripe`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` from`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"stripe\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`createProxyFetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"@major-tech/resource-client/next\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` proxyFetch`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` createProxyFetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` baseUrl:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`MAJOR_API_BASE_URL`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` resourceId:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`STRIPE_RESOURCE_ID`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` majorJwtToken:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` process`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`env`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`MAJOR_JWT_TOKEN`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` stripe`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` new`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` Stripe`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"sk_unused_proxy_injects_real_key\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` httpClient:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` Stripe`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`createFetchHttpClient`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`proxyFetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`),`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` customers`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` stripe`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`customers`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`list`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({ `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`limit:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 10`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` });`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`per-user-connectors`,children:`Per-user connectors`}),`\n`,_jsxs(_components.p,{children:[`For connectors that use `,_jsx(_components.a,{href:`/learn/connectors/overview#shared-vs-per-user-connections`,children:`per-user connections`}),` (such as Gmail, Google Calendar, or Google Drive), the `,_jsx(_components.code,{children:`/next`}),` entry forwards the signed-in user’s identity automatically, so each request uses that user’s connected account.`]}),`\n`,_jsx(_components.p,{children:`Outside a user request, such as a background job, there is no user to forward, and calls to per-user connectors fail. Shared connectors keep working.`}),`\n`,_jsxs(_components.p,{children:[`Outside Next.js, for example in a `,_jsx(_components.a,{href:`/learn/skills/overview`,children:`skill`}),` script or plain Node, import `,_jsx(_components.code,{children:`createProxyFetch`}),` from `,_jsx(_components.code,{children:`@major-tech/resource-client`}),` (the package root). It has no Next.js dependency and takes an optional `,_jsx(_components.code,{children:`getUserJwt`}),` function if you have a user token to forward.`]}),`\n`,_jsx(Heading,{level:`2`,id:`headers-and-limits`,children:`Headers and limits`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[`Don’t set `,_jsx(_components.code,{children:`Authorization`}),`.`]}),` The proxy injects the connector’s credentials and strips any `,_jsx(_components.code,{children:`Authorization`}),` you send.`]}),`\n`,_jsxs(_components.li,{children:[`These request headers are always stripped: `,_jsx(_components.code,{children:`Authorization`}),`, `,_jsx(_components.code,{children:`Cookie`}),`, `,_jsx(_components.code,{children:`Host`}),`, `,_jsx(_components.code,{children:`Forwarded`}),`, `,_jsx(_components.code,{children:`X-Forwarded-*`}),`, `,_jsx(_components.code,{children:`X-Real-Ip`}),`, and anything starting with `,_jsx(_components.code,{children:`X-Major-`}),` or `,_jsx(_components.code,{children:`X-Pd-`}),`. The exception is `,_jsx(_components.code,{children:`X-Major-Timeout-Ms`}),`, which sets the timeout for one request.`]}),`\n`,_jsx(_components.li,{children:`The target URL must be one the connector allows, usually the service’s API host.`}),`\n`,_jsxs(_components.li,{children:[`The target must resolve to a public address. A request to a loopback, private, link-local, or other internal address, directly or through a redirect, fails with `,_jsx(_components.code,{children:`403`}),` and the error `,_jsx(_components.code,{children:`destination_blocked`}),`.`]}),`\n`,_jsxs(_components.li,{children:[`Redirects are followed for up to 10 hops. A redirect from `,_jsx(_components.code,{children:`https`}),` to `,_jsx(_components.code,{children:`http`}),` is refused.`]}),`\n`,_jsxs(_components.li,{children:[`The target URL must use `,_jsx(_components.code,{children:`https`}),` and must not name a port, not even `,_jsx(_components.code,{children:`:443`}),`. Requests to `,_jsx(_components.code,{children:`http://`}),` URLs or to any explicit port are refused.`]}),`\n`,_jsxs(_components.li,{children:[`When a redirect goes to a different host, Major sends only the `,_jsx(_components.code,{children:`Accept`}),`, `,_jsx(_components.code,{children:`Accept-Encoding`}),`, `,_jsx(_components.code,{children:`Accept-Language`}),`, and `,_jsx(_components.code,{children:`User-Agent`}),` headers on that hop, so the connector’s credentials and any custom headers stay on the original host. A subdomain or a different port counts as a different host. A cross-host `,_jsx(_components.code,{children:`307`}),` or `,_jsx(_components.code,{children:`308`}),` redirect that would resend the request body is refused. Redirects that stay on the same host keep all headers.`]}),`\n`,_jsx(_components.li,{children:`Request and response bodies are limited to 50 MB. Timeouts are capped at 60 seconds.`}),`\n`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Proxy fetch","description":"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.","href":"/learn/connectors/proxy-fetch"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Create a proxy fetch","slug":"create-a-proxy-fetch","depth":2,"children":[]},{"title":"Use it with an SDK","slug":"use-it-with-an-sdk","depth":2,"children":[]},{"title":"Per-user connectors","slug":"per-user-connectors","depth":2,"children":[]},{"title":"Headers and limits","slug":"headers-and-limits","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"major-5cc5eebc","siteName":"Major","title":"Proxy fetch - Major","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-13T02:36:50.976Z","originalFileLocation":"learn/connectors/proxy-fetch.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Major\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Proxy fetch - Major\">\u003cmeta data-mint-head property=\"og:description\" content=\"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Major\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.major.build/learn/connectors/proxy-fetch\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://major-5cc5eebc.mintlify.site/_mintlify/api/og/v2?division=Connectors\u0026amp;title=Proxy+fetch\u0026amp;description=Call+any+HTTP+API+on+a+connector+through+Major+with+a+drop-in+fetch%2C+so+third-party+SDKs+work+without+API+keys.\u0026amp;theme=6c2a55a46223a2ab50412aca\u0026amp;signature=63c4c703ac78046f8f04431a86c26858342e7ebf50365cfaf897a182ae5d0150\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Proxy fetch - Major\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://major-5cc5eebc.mintlify.site/_mintlify/api/og/v2?division=Connectors\u0026amp;title=Proxy+fetch\u0026amp;description=Call+any+HTTP+API+on+a+connector+through+Major+with+a+drop-in+fetch%2C+so+third-party+SDKs+work+without+API+keys.\u0026amp;theme=6c2a55a46223a2ab50412aca\u0026amp;signature=63c4c703ac78046f8f04431a86c26858342e7ebf50365cfaf897a182ae5d0150\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/major-5cc5eebc/sh9VBxrFz-oAZ9SE/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Major\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#02906f\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.major.build/learn/connectors/proxy-fetch\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/learn/connectors/proxy-fetch.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.major.build/#organization\",\"name\":\"Major\",\"url\":\"https://docs.major.build\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/major-5cc5eebc/X12oJWlEd93WI1uJ/logo/light.svg?fit=max\u0026auto=format\u0026n=X12oJWlEd93WI1uJ\u0026q=85\u0026s=8e7603184824ca90c12dc6dce0935096\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.major.build#website\",\"name\":\"Major\",\"url\":\"https://docs.major.build\",\"publisher\":{\"@id\":\"https://docs.major.build/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.major.build/learn/connectors/proxy-fetch#webpage\",\"url\":\"https://docs.major.build/learn/connectors/proxy-fetch\",\"name\":\"Proxy fetch\",\"description\":\"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.\",\"dateModified\":\"2026-11-13T02:36:50.976Z\",\"isPartOf\":{\"@id\":\"https://docs.major.build#website\"},\"breadcrumb\":{\"@id\":\"https://docs.major.build/learn/connectors/proxy-fetch#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.major.build/learn/connectors/proxy-fetch#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Learn\",\"item\":\"https://docs.major.build/learn/web-app\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Connectors\",\"item\":\"https://docs.major.build/learn/connectors/overview\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Proxy fetch\",\"item\":\"https://docs.major.build/learn/connectors/proxy-fetch\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.major.build/learn/connectors/proxy-fetch#article\",\"headline\":\"Proxy fetch\",\"name\":\"Proxy fetch\",\"description\":\"Call any HTTP API on a connector through Major with a drop-in fetch, so third-party SDKs work without API keys.\",\"url\":\"https://docs.major.build/learn/connectors/proxy-fetch\",\"mainEntityOfPage\":{\"@id\":\"https://docs.major.build/learn/connectors/proxy-fetch#webpage\"},\"dateModified\":\"2026-11-13T02:36:50.976Z\",\"publisher\":{\"@id\":\"https://docs.major.build/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.major.build#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Major\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Major\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/learn/connectors/proxy-fetch.md","siteName":"Major","nav":{"global":{"anchors":[{"anchor":"App editor","icon":"window","href":"https://app.major.build"},{"anchor":"CLI repository","icon":"github","href":"https://github.com/major-technology/cli"}]},"groups":[{"group":"Get Started","pages":[{"title":"Introduction","href":"/index"},{"title":"Quickstart","href":"/get-started/quickstart"},{"title":"Use cases","href":"/get-started/use-cases"}]},{"group":"Learn","pages":[{"title":"Web app","href":"/learn/web-app"},{"group":"Apps","pages":[{"title":"Overview","href":"/learn/apps/overview"},{"title":"Editor","href":"/learn/apps/editor"},{"title":"Deploying","href":"/learn/apps/deploying"},{"title":"Environments","href":"/learn/apps/environments"},{"title":"Environment Variables","href":"/learn/apps/environment-variables"},{"title":"Authentication (AuthN)","href":"/learn/apps/authentication"},{"title":"Managed Databases","href":"/learn/apps/managed-databases"},{"title":"AI proxy","href":"/learn/apps/ai-proxy"},{"title":"Agents client","href":"/learn/apps/agents-client"},{"title":"Domains","href":"/learn/apps/domains"},{"title":"Theming \u0026 Branding","href":"/learn/apps/theming"},{"title":"Queries","href":"/learn/apps/queries"},{"title":"Errors","href":"/learn/apps/errors"},{"title":"Webhook routes","href":"/learn/apps/webhook-routes"}]},{"group":"Agents","pages":[{"title":"Overview","href":"/learn/agents/overview"},{"title":"Models","href":"/learn/agents/models"},{"title":"Tool Permissions","href":"/learn/agents/tool-permissions"},{"title":"Browser","href":"/learn/agents/browser"},{"title":"External Channels","href":"/learn/agents/external-channels"},{"title":"Access \u0026 Permissions","href":"/learn/agents/access"}]},{"group":"Skills","pages":[{"title":"Overview","href":"/learn/skills/overview"}]},{"group":"Workflows","pages":[{"title":"Overview","href":"/learn/workflows/overview"},{"title":"Nodes","href":"/learn/workflows/nodes"},{"title":"State and input","href":"/learn/workflows/state"}]},{"group":"Triggers","pages":[{"title":"Overview","href":"/learn/triggers/overview"},{"title":"Schedules","href":"/learn/triggers/schedules"},{"title":"Connector events","href":"/learn/triggers/connector-events"},{"title":"Webhooks","href":"/learn/triggers/webhooks"},{"title":"App triggers","href":"/learn/triggers/app-triggers"}]},{"group":"Connectors","pages":[{"title":"Overview","href":"/learn/connectors/overview"},{"title":"Resource Client","description":"Type-safe, zero-dependency client for accessing your Major connectors.","href":"/learn/connectors/resource-client"},{"title":"Proxy fetch","href":"/learn/connectors/proxy-fetch"}]}]},{"group":"Build","pages":[{"title":"MCP","description":"Build on Major from Claude Code, Codex, ChatGPT, Claude Desktop, Cursor, or any MCP client.","href":"/build/mcp"},{"title":"CLI","href":"/build/cli"},{"title":"Platform Agent","href":"/build/platform-agent"}]},{"group":"Settings","pages":[{"title":"Members \u0026 Roles","href":"/settings/members-and-roles"},{"title":"Connected Accounts","href":"/settings/connected-accounts"},{"title":"GitHub App","href":"/settings/github-app"},{"title":"Tool Permissions","href":"/settings/tool-permissions"},{"title":"Browser Controls","href":"/settings/browser-controls"},{"title":"Models","href":"/settings/models"},{"title":"Audit Log","href":"/settings/audit-log"},{"title":"Billing \u0026 Plans","href":"/settings/billing"}]},{"group":"Reference","pages":[{"group":"CLI","pages":[{"title":"CLI overview","href":"/reference/cli/overview"},{"title":"major app","href":"/reference/cli/app"},{"title":"major agent","href":"/reference/cli/agent"},{"title":"major skill","href":"/reference/cli/skill"},{"title":"major workflow","href":"/reference/cli/workflow"},{"title":"major resource","href":"/reference/cli/resource"},{"title":"major vars","href":"/reference/cli/vars"},{"title":"pull, push, validate, publish","href":"/reference/cli/sync"},{"title":"major sandbox","href":"/reference/cli/sandbox"},{"title":"major org","href":"/reference/cli/org"},{"title":"major user","href":"/reference/cli/user"},{"title":"major update","href":"/reference/cli/update"}]},{"title":"Connectors","href":"/reference/connectors"}]}]},"basePath":"","title":"Proxy fetch - Major","buildId":"dpl_5joLUXmnJgwqjrHAS4dxZrQTdxgh","deploymentId":"dpl_5joLUXmnJgwqjrHAS4dxZrQTdxgh","dynamics":[],"chunks":[]}