@@ -12,38 +12,38 @@ def __init__(
12
12
* ,
13
13
project_id : str ,
14
14
x_pd_environment : typing .Optional [str ] = None ,
15
- token : typing .Optional [typing .Union [str , typing .Callable [[], str ]]] = None ,
15
+ access_token : typing .Optional [typing .Union [str , typing .Callable [[], str ]]] = None ,
16
16
headers : typing .Optional [typing .Dict [str , str ]] = None ,
17
17
base_url : str ,
18
18
timeout : typing .Optional [float ] = None ,
19
19
):
20
20
self ._project_id = project_id
21
21
self ._x_pd_environment = x_pd_environment
22
- self ._token = token
22
+ self ._access_token = access_token
23
23
self ._headers = headers
24
24
self ._base_url = base_url
25
25
self ._timeout = timeout
26
26
27
27
def get_headers (self ) -> typing .Dict [str , str ]:
28
28
headers : typing .Dict [str , str ] = {
29
- "User-Agent" : "pipedream/0.3.1 " ,
29
+ "User-Agent" : "pipedream/0.3.2 " ,
30
30
"X-Fern-Language" : "Python" ,
31
31
"X-Fern-SDK-Name" : "pipedream" ,
32
- "X-Fern-SDK-Version" : "0.3.1 " ,
32
+ "X-Fern-SDK-Version" : "0.3.2 " ,
33
33
** (self .get_custom_headers () or {}),
34
34
}
35
35
if self ._x_pd_environment is not None :
36
36
headers ["x-pd-environment" ] = self ._x_pd_environment
37
- token = self ._get_token ()
38
- if token is not None :
39
- headers ["Authorization" ] = f"Bearer { token } "
37
+ access_token = self ._get_access_token ()
38
+ if access_token is not None :
39
+ headers ["Authorization" ] = f"Bearer { access_token } "
40
40
return headers
41
41
42
- def _get_token (self ) -> typing .Optional [str ]:
43
- if isinstance (self ._token , str ) or self ._token is None :
44
- return self ._token
42
+ def _get_access_token (self ) -> typing .Optional [str ]:
43
+ if isinstance (self ._access_token , str ) or self ._access_token is None :
44
+ return self ._access_token
45
45
else :
46
- return self ._token ()
46
+ return self ._access_token ()
47
47
48
48
def get_custom_headers (self ) -> typing .Optional [typing .Dict [str , str ]]:
49
49
return self ._headers
@@ -61,7 +61,7 @@ def __init__(
61
61
* ,
62
62
project_id : str ,
63
63
x_pd_environment : typing .Optional [str ] = None ,
64
- token : typing .Optional [typing .Union [str , typing .Callable [[], str ]]] = None ,
64
+ access_token : typing .Optional [typing .Union [str , typing .Callable [[], str ]]] = None ,
65
65
headers : typing .Optional [typing .Dict [str , str ]] = None ,
66
66
base_url : str ,
67
67
timeout : typing .Optional [float ] = None ,
@@ -70,7 +70,7 @@ def __init__(
70
70
super ().__init__ (
71
71
project_id = project_id ,
72
72
x_pd_environment = x_pd_environment ,
73
- token = token ,
73
+ access_token = access_token ,
74
74
headers = headers ,
75
75
base_url = base_url ,
76
76
timeout = timeout ,
@@ -89,7 +89,7 @@ def __init__(
89
89
* ,
90
90
project_id : str ,
91
91
x_pd_environment : typing .Optional [str ] = None ,
92
- token : typing .Optional [typing .Union [str , typing .Callable [[], str ]]] = None ,
92
+ access_token : typing .Optional [typing .Union [str , typing .Callable [[], str ]]] = None ,
93
93
headers : typing .Optional [typing .Dict [str , str ]] = None ,
94
94
base_url : str ,
95
95
timeout : typing .Optional [float ] = None ,
@@ -98,7 +98,7 @@ def __init__(
98
98
super ().__init__ (
99
99
project_id = project_id ,
100
100
x_pd_environment = x_pd_environment ,
101
- token = token ,
101
+ access_token = access_token ,
102
102
headers = headers ,
103
103
base_url = base_url ,
104
104
timeout = timeout ,
0 commit comments