Skip to content

Commit e3c695e

Browse files
Merge pull request #879 from UKHSA-Internal/task/CDD-3145-use-custom-uhd-auth-header-for-jwt
CDD-3145: Use custom X-UHD-AUTH header for JWT
1 parent 4fee74f commit e3c695e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/api/utils/api.utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ export async function client<T>(
100100
...customConfig.headers,
101101
//passing authorization header only if access token is available, to avoid sending
102102
// "Authorization: Bearer undefined" in the headers which might cause issues with some APIs
103-
...(accessToken ? { Authorization: `Bearer ${accessToken}` } : {}),
103+
...(accessToken ? { 'X-UHD-AUTH': `Bearer ${accessToken}` } : {}),
104104
},
105105
}
106106

0 commit comments

Comments
 (0)