File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change
1
+ import version from 'src/lib/version.js'
2
+
1
3
import { getAuthHeaders } from './auth.js'
2
4
import type { ClientOptions } from './client.js'
3
5
import {
@@ -8,6 +10,11 @@ import {
8
10
9
11
const defaultEndpoint = 'https://connect.getseam.com'
10
12
13
+ const defaultHeaders = {
14
+ 'seam-sdk-name' : 'seamapi/javascript-http' ,
15
+ 'seam-sdk-version' : version ,
16
+ }
17
+
11
18
export type Options = SeamHttpOptions & { publishableKey ?: string }
12
19
13
20
export const parseOptions = (
@@ -23,6 +30,7 @@ export const parseOptions = (
23
30
withCredentials : isSeamHttpOptionsWithClientSessionToken ( options ) ,
24
31
...options . axiosOptions ,
25
32
headers : {
33
+ ...defaultHeaders ,
26
34
...getAuthHeaders ( options ) ,
27
35
...options . axiosOptions ?. headers ,
28
36
} ,
You can’t perform that action at this time.
0 commit comments