Skip to content

Commit f3b006e

Browse files
fix(types): make address/dob/email/government_id optional in KYB delegated types
1 parent e4cc981 commit f3b006e

3 files changed

Lines changed: 35 additions & 32 deletions

File tree

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 189
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-e88a4837037207e9591d48d534bd61acca57ca6e7c59ec0d4fdcf6e05288cc6d.yml
3-
openapi_spec_hash: fd8bbc173d1b6dafd117fb1a3a3d446c
4-
config_hash: 64f05ed5c69d8a76596979dc2c17f0f9
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-dad98281bf8dca620bc21f30217878fc043d725586d0395558f0b66b78f316a8.yml
3+
openapi_spec_hash: 326eff6733ff1b438d77dd1288816101
4+
config_hash: 400b9afe0f7f7b7d96177d05950775f9

src/lithic/types/account_holder_create_params.py

Lines changed: 24 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -301,37 +301,40 @@ class KYBDelegatedBusinessEntity(TypedDict, total=False):
301301

302302

303303
class KYBDelegatedBeneficialOwnerIndividual(TypedDict, total=False):
304-
"""Individuals associated with a KYB application. Phone number is optional."""
304+
"""Individuals associated with a KYB_DELEGATED application.
305305
306-
address: Required[Address]
306+
Only first and last name are required.
307+
"""
308+
309+
first_name: Required[str]
310+
"""Individual's first name, as it appears on government-issued identity documents."""
311+
312+
last_name: Required[str]
313+
"""Individual's last name, as it appears on government-issued identity documents."""
314+
315+
address: Address
307316
"""
308317
Individual's current address - PO boxes, UPS drops, and FedEx drops are not
309318
acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
310319
"""
311320

312-
dob: Required[str]
321+
dob: str
313322
"""Individual's date of birth, as an RFC 3339 date."""
314323

315-
email: Required[str]
324+
email: str
316325
"""
317326
Individual's email address. If utilizing Lithic for chargeback processing, this
318327
customer email address may be used to communicate dispute status and resolution.
319328
"""
320329

321-
first_name: Required[str]
322-
"""Individual's first name, as it appears on government-issued identity documents."""
323-
324-
government_id: Required[str]
330+
government_id: str
325331
"""
326332
Government-issued identification number (required for identity verification and
327333
compliance with banking regulations). Social Security Numbers (SSN) and
328334
Individual Taxpayer Identification Numbers (ITIN) are currently supported,
329335
entered as full nine-digits, with or without hyphens
330336
"""
331337

332-
last_name: Required[str]
333-
"""Individual's last name, as it appears on government-issued identity documents."""
334-
335338
phone_number: str
336339
"""Individual's phone number, entered in E.164 format."""
337340

@@ -344,35 +347,35 @@ class KYBDelegatedControlPerson(TypedDict, total=False):
344347
See [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf) (Section II) for more background.
345348
"""
346349

347-
address: Required[Address]
350+
first_name: Required[str]
351+
"""Individual's first name, as it appears on government-issued identity documents."""
352+
353+
last_name: Required[str]
354+
"""Individual's last name, as it appears on government-issued identity documents."""
355+
356+
address: Address
348357
"""
349358
Individual's current address - PO boxes, UPS drops, and FedEx drops are not
350359
acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
351360
"""
352361

353-
dob: Required[str]
362+
dob: str
354363
"""Individual's date of birth, as an RFC 3339 date."""
355364

356-
email: Required[str]
365+
email: str
357366
"""
358367
Individual's email address. If utilizing Lithic for chargeback processing, this
359368
customer email address may be used to communicate dispute status and resolution.
360369
"""
361370

362-
first_name: Required[str]
363-
"""Individual's first name, as it appears on government-issued identity documents."""
364-
365-
government_id: Required[str]
371+
government_id: str
366372
"""
367373
Government-issued identification number (required for identity verification and
368374
compliance with banking regulations). Social Security Numbers (SSN) and
369375
Individual Taxpayer Identification Numbers (ITIN) are currently supported,
370376
entered as full nine-digits, with or without hyphens
371377
"""
372378

373-
last_name: Required[str]
374-
"""Individual's last name, as it appears on government-issued identity documents."""
375-
376379
phone_number: str
377380
"""Individual's phone number, entered in E.164 format."""
378381

tests/api_resources/test_account_holders.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -287,6 +287,8 @@ def test_method_create_with_all_params_overload_2(self, client: Lithic) -> None:
287287
},
288288
beneficial_owner_individuals=[
289289
{
290+
"first_name": "Tom",
291+
"last_name": "Bombadil",
290292
"address": {
291293
"address1": "123 Old Forest Way",
292294
"city": "Omaha",
@@ -297,13 +299,13 @@ def test_method_create_with_all_params_overload_2(self, client: Lithic) -> None:
297299
},
298300
"dob": "1991-03-08 08:00:00",
299301
"email": "tom@middle-earth.com",
300-
"first_name": "Tom",
301302
"government_id": "111-23-1412",
302-
"last_name": "Bombadil",
303303
"phone_number": "+15555555555",
304304
}
305305
],
306306
control_person={
307+
"first_name": "Tom",
308+
"last_name": "Bombadil",
307309
"address": {
308310
"address1": "123 Old Forest Way",
309311
"city": "Omaha",
@@ -314,9 +316,7 @@ def test_method_create_with_all_params_overload_2(self, client: Lithic) -> None:
314316
},
315317
"dob": "1991-03-08 08:00:00",
316318
"email": "tom@middle-earth.com",
317-
"first_name": "Tom",
318319
"government_id": "111-23-1412",
319-
"last_name": "Bombadil",
320320
"phone_number": "+15555555555",
321321
},
322322
external_id="external_id",
@@ -1344,6 +1344,8 @@ async def test_method_create_with_all_params_overload_2(self, async_client: Asyn
13441344
},
13451345
beneficial_owner_individuals=[
13461346
{
1347+
"first_name": "Tom",
1348+
"last_name": "Bombadil",
13471349
"address": {
13481350
"address1": "123 Old Forest Way",
13491351
"city": "Omaha",
@@ -1354,13 +1356,13 @@ async def test_method_create_with_all_params_overload_2(self, async_client: Asyn
13541356
},
13551357
"dob": "1991-03-08 08:00:00",
13561358
"email": "tom@middle-earth.com",
1357-
"first_name": "Tom",
13581359
"government_id": "111-23-1412",
1359-
"last_name": "Bombadil",
13601360
"phone_number": "+15555555555",
13611361
}
13621362
],
13631363
control_person={
1364+
"first_name": "Tom",
1365+
"last_name": "Bombadil",
13641366
"address": {
13651367
"address1": "123 Old Forest Way",
13661368
"city": "Omaha",
@@ -1371,9 +1373,7 @@ async def test_method_create_with_all_params_overload_2(self, async_client: Asyn
13711373
},
13721374
"dob": "1991-03-08 08:00:00",
13731375
"email": "tom@middle-earth.com",
1374-
"first_name": "Tom",
13751376
"government_id": "111-23-1412",
1376-
"last_name": "Bombadil",
13771377
"phone_number": "+15555555555",
13781378
},
13791379
external_id="external_id",

0 commit comments

Comments
 (0)