Garrett Johnson
12/22/2025, 8:49 PMpermit support automation2
12/22/2025, 8:49 PMOr Weis
12/22/2025, 9:00 PMAsk Inkeep
12/22/2025, 9:00 PMAsk Inkeep
12/22/2025, 9:01 PMpermit-fe-sdk source code, the SDK does support customRequestHeaders but you're correct that withCredentials is an Axios request config option, not a header. (1)
The current implementation passes headers like this:
const config = headers ? { headers } : {};
This means the SDK currently only forwards custom headers, not other Axios config options like withCredentials.
*Workaround options:*
1. *Proxy approach*: Set up a same-origin proxy on your backend so CORS credentials aren't needed.
2. *Fork/contribute*: Since the SDK is open source, you could fork it and modify the axios calls to include withCredentials: true, or submit a PR to add support for additional Axios config options.
The PermitProps interface currently accepts:
export type PermitProps = {
loggedInUser: string;
userAttributes?: Record<string, any>;
backendUrl: string;
defaultAnswerIfNotExist?: boolean;
customRequestHeaders?: AxiosRequestHeaders;
};
Adding something like axiosConfig?: AxiosRequestConfig would be the ideal enhancement to support your use case.
I'd recommend opening an issue or PR on the permit-fe-sdk GitHub repo to request this feature.Ask Inkeep
12/22/2025, 9:01 PMZe'ev Manilovich
12/23/2025, 9:33 PMZe'ev Manilovich
12/23/2025, 9:33 PMZe'ev Manilovich
12/25/2025, 7:07 PMGarrett Johnson
12/26/2025, 1:41 PM