88import httpx
99
1010from ... import _legacy_response
11- from ..._types import Body , Query , Headers , NotGiven , not_given
11+ from ..._types import Body , Omit , Query , Headers , NotGiven , omit , not_given
1212from ..._utils import maybe_transform , async_maybe_transform
1313from ..._compat import cached_property
1414from ..._resource import SyncAPIResource , AsyncAPIResource
@@ -44,12 +44,8 @@ def with_streaming_response(self) -> SessionsWithStreamingResponse:
4444 def new (
4545 self ,
4646 * ,
47- customer_email : Optional [str ],
4847 customer_id : str ,
4948 customer_name : str ,
50- integration : Optional [session_new_params .Integration ],
51- manual : Optional [bool ],
52- minutes_to_expire : Optional [float ],
5349 products : List [
5450 Literal [
5551 "benefits" ,
@@ -64,8 +60,12 @@ def new(
6460 "ssn" ,
6561 ]
6662 ],
67- redirect_uri : Optional [str ],
68- sandbox : Optional [Literal ["finch" , "provider" ]],
63+ customer_email : Optional [str ] | Omit = omit ,
64+ integration : Optional [session_new_params .Integration ] | Omit = omit ,
65+ manual : Optional [bool ] | Omit = omit ,
66+ minutes_to_expire : Optional [float ] | Omit = omit ,
67+ redirect_uri : Optional [str ] | Omit = omit ,
68+ sandbox : Optional [Literal ["finch" , "provider" ]] | Omit = omit ,
6969 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
7070 # The extra values given here take precedence over values defined on the client or passed to this method.
7171 extra_headers : Headers | None = None ,
@@ -77,21 +77,21 @@ def new(
7777 Create a new connect session for an employer
7878
7979 Args:
80- customer_email: Email address of the customer
81-
8280 customer_id: Unique identifier for the customer
8381
8482 customer_name: Name of the customer
8583
84+ products: The Finch products to request access to
85+
86+ customer_email: Email address of the customer
87+
8688 integration: Integration configuration for the connect session
8789
8890 manual: Enable manual authentication mode
8991
9092 minutes_to_expire: The number of minutes until the session expires (defaults to 129,600, which is
9193 90 days)
9294
93- products: The Finch products to request access to
94-
9595 redirect_uri: The URI to redirect to after the Connect flow is completed
9696
9797 sandbox: Sandbox mode for testing
@@ -108,13 +108,13 @@ def new(
108108 "/connect/sessions" ,
109109 body = maybe_transform (
110110 {
111- "customer_email" : customer_email ,
112111 "customer_id" : customer_id ,
113112 "customer_name" : customer_name ,
113+ "products" : products ,
114+ "customer_email" : customer_email ,
114115 "integration" : integration ,
115116 "manual" : manual ,
116117 "minutes_to_expire" : minutes_to_expire ,
117- "products" : products ,
118118 "redirect_uri" : redirect_uri ,
119119 "sandbox" : sandbox ,
120120 },
@@ -130,7 +130,7 @@ def reauthenticate(
130130 self ,
131131 * ,
132132 connection_id : str ,
133- minutes_to_expire : int ,
133+ minutes_to_expire : int | Omit = omit ,
134134 products : Optional [
135135 List [
136136 Literal [
@@ -146,8 +146,9 @@ def reauthenticate(
146146 "ssn" ,
147147 ]
148148 ]
149- ],
150- redirect_uri : Optional [str ],
149+ ]
150+ | Omit = omit ,
151+ redirect_uri : Optional [str ] | Omit = omit ,
151152 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
152153 # The extra values given here take precedence over values defined on the client or passed to this method.
153154 extra_headers : Headers | None = None ,
@@ -217,12 +218,8 @@ def with_streaming_response(self) -> AsyncSessionsWithStreamingResponse:
217218 async def new (
218219 self ,
219220 * ,
220- customer_email : Optional [str ],
221221 customer_id : str ,
222222 customer_name : str ,
223- integration : Optional [session_new_params .Integration ],
224- manual : Optional [bool ],
225- minutes_to_expire : Optional [float ],
226223 products : List [
227224 Literal [
228225 "benefits" ,
@@ -237,8 +234,12 @@ async def new(
237234 "ssn" ,
238235 ]
239236 ],
240- redirect_uri : Optional [str ],
241- sandbox : Optional [Literal ["finch" , "provider" ]],
237+ customer_email : Optional [str ] | Omit = omit ,
238+ integration : Optional [session_new_params .Integration ] | Omit = omit ,
239+ manual : Optional [bool ] | Omit = omit ,
240+ minutes_to_expire : Optional [float ] | Omit = omit ,
241+ redirect_uri : Optional [str ] | Omit = omit ,
242+ sandbox : Optional [Literal ["finch" , "provider" ]] | Omit = omit ,
242243 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
243244 # The extra values given here take precedence over values defined on the client or passed to this method.
244245 extra_headers : Headers | None = None ,
@@ -250,21 +251,21 @@ async def new(
250251 Create a new connect session for an employer
251252
252253 Args:
253- customer_email: Email address of the customer
254-
255254 customer_id: Unique identifier for the customer
256255
257256 customer_name: Name of the customer
258257
258+ products: The Finch products to request access to
259+
260+ customer_email: Email address of the customer
261+
259262 integration: Integration configuration for the connect session
260263
261264 manual: Enable manual authentication mode
262265
263266 minutes_to_expire: The number of minutes until the session expires (defaults to 129,600, which is
264267 90 days)
265268
266- products: The Finch products to request access to
267-
268269 redirect_uri: The URI to redirect to after the Connect flow is completed
269270
270271 sandbox: Sandbox mode for testing
@@ -281,13 +282,13 @@ async def new(
281282 "/connect/sessions" ,
282283 body = await async_maybe_transform (
283284 {
284- "customer_email" : customer_email ,
285285 "customer_id" : customer_id ,
286286 "customer_name" : customer_name ,
287+ "products" : products ,
288+ "customer_email" : customer_email ,
287289 "integration" : integration ,
288290 "manual" : manual ,
289291 "minutes_to_expire" : minutes_to_expire ,
290- "products" : products ,
291292 "redirect_uri" : redirect_uri ,
292293 "sandbox" : sandbox ,
293294 },
@@ -303,7 +304,7 @@ async def reauthenticate(
303304 self ,
304305 * ,
305306 connection_id : str ,
306- minutes_to_expire : int ,
307+ minutes_to_expire : int | Omit = omit ,
307308 products : Optional [
308309 List [
309310 Literal [
@@ -319,8 +320,9 @@ async def reauthenticate(
319320 "ssn" ,
320321 ]
321322 ]
322- ],
323- redirect_uri : Optional [str ],
323+ ]
324+ | Omit = omit ,
325+ redirect_uri : Optional [str ] | Omit = omit ,
324326 # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
325327 # The extra values given here take precedence over values defined on the client or passed to this method.
326328 extra_headers : Headers | None = None ,
0 commit comments