# UBOs

## Read Ubos

> Get all UBO information associated with a verification session. This helps in reviewing the ownership structure of the business being verified.

```json
{"openapi":"3.1.0","info":{"title":"BeetleLabs","version":"1.0.0"},"servers":[{"url":"https://beetlelabs.ai/beetlelabs-verification","description":"Local development server"}],"paths":{"/ubos/":{"get":{"tags":["UBOs"],"summary":"Read Ubos","description":"Get all UBO information associated with a verification session. This helps in reviewing the ownership structure of the business being verified.","operationId":"read_ubos_ubos__get","parameters":[{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"session_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Session Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UBOResponse"},"title":"Response Read Ubos Ubos  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"UBOResponse":{"properties":{"session_id":{"type":"string","format":"uuid","title":"Session Id"},"full_name":{"type":"string","title":"Full Name"},"date_of_birth":{"type":"string","format":"date","title":"Date Of Birth"},"nationality":{"type":"string","title":"Nationality"},"ownership_percentage":{"type":"integer","title":"Ownership Percentage"},"residential_address":{"type":"string","title":"Residential Address"},"id_document_type":{"$ref":"#/components/schemas/DocumentType"},"id_document_number":{"type":"string","title":"Id Document Number"},"id_document_path":{"type":"string","title":"Id Document Path"},"id_document_back_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Back Path"},"liveness_check_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Liveness Check Path"},"verification_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Notes"},"consent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consent","default":false},"id":{"type":"string","format":"uuid","title":"Id"}},"type":"object","required":["session_id","full_name","date_of_birth","nationality","ownership_percentage","residential_address","id_document_type","id_document_number","id_document_path","id"],"title":"UBOResponse"},"DocumentType":{"type":"string","enum":["PASSPORT","NRIC","DRIVING_LICENSE","AADHAAR","PAN","BANK_STATEMENT","UTILITY_BILL"],"title":"DocumentType"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## Create Ubo

> Add information about Ultimate Beneficial Owners (UBOs) of a business. UBOs are individuals who ultimately own or control the business. This information is crucial for compliance and anti-money laundering purposes.

```json
{"openapi":"3.1.0","info":{"title":"BeetleLabs","version":"1.0.0"},"servers":[{"url":"https://beetlelabs.ai/beetlelabs-verification","description":"Local development server"}],"paths":{"/ubos/":{"post":{"tags":["UBOs"],"summary":"Create Ubo","description":"Add information about Ultimate Beneficial Owners (UBOs) of a business. UBOs are individuals who ultimately own or control the business. This information is crucial for compliance and anti-money laundering purposes.","operationId":"create_ubo_ubos__post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UBOCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UBOResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"UBOCreate":{"properties":{"session_id":{"type":"string","format":"uuid","title":"Session Id"},"full_name":{"type":"string","title":"Full Name"},"date_of_birth":{"type":"string","format":"date","title":"Date Of Birth"},"nationality":{"type":"string","title":"Nationality"},"ownership_percentage":{"type":"integer","title":"Ownership Percentage"},"residential_address":{"type":"string","title":"Residential Address"},"id_document_type":{"$ref":"#/components/schemas/DocumentType"},"id_document_number":{"type":"string","title":"Id Document Number"},"id_document_path":{"type":"string","title":"Id Document Path"},"id_document_back_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Back Path"},"liveness_check_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Liveness Check Path"},"verification_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Notes"},"consent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consent","default":false}},"type":"object","required":["session_id","full_name","date_of_birth","nationality","ownership_percentage","residential_address","id_document_type","id_document_number","id_document_path"],"title":"UBOCreate"},"DocumentType":{"type":"string","enum":["PASSPORT","NRIC","DRIVING_LICENSE","AADHAAR","PAN","BANK_STATEMENT","UTILITY_BILL"],"title":"DocumentType"},"UBOResponse":{"properties":{"session_id":{"type":"string","format":"uuid","title":"Session Id"},"full_name":{"type":"string","title":"Full Name"},"date_of_birth":{"type":"string","format":"date","title":"Date Of Birth"},"nationality":{"type":"string","title":"Nationality"},"ownership_percentage":{"type":"integer","title":"Ownership Percentage"},"residential_address":{"type":"string","title":"Residential Address"},"id_document_type":{"$ref":"#/components/schemas/DocumentType"},"id_document_number":{"type":"string","title":"Id Document Number"},"id_document_path":{"type":"string","title":"Id Document Path"},"id_document_back_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Back Path"},"liveness_check_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Liveness Check Path"},"verification_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Notes"},"consent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consent","default":false},"id":{"type":"string","format":"uuid","title":"Id"}},"type":"object","required":["session_id","full_name","date_of_birth","nationality","ownership_percentage","residential_address","id_document_type","id_document_number","id_document_path","id"],"title":"UBOResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## GET /ubos/{ubo\_id}

> Read Ubo

```json
{"openapi":"3.1.0","info":{"title":"BeetleLabs","version":"1.0.0"},"servers":[{"url":"https://beetlelabs.ai/beetlelabs-verification","description":"Local development server"}],"paths":{"/ubos/{ubo_id}":{"get":{"tags":["UBOs"],"summary":"Read Ubo","operationId":"read_ubo_ubos__ubo_id__get","parameters":[{"name":"ubo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ubo Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UBOResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"UBOResponse":{"properties":{"session_id":{"type":"string","format":"uuid","title":"Session Id"},"full_name":{"type":"string","title":"Full Name"},"date_of_birth":{"type":"string","format":"date","title":"Date Of Birth"},"nationality":{"type":"string","title":"Nationality"},"ownership_percentage":{"type":"integer","title":"Ownership Percentage"},"residential_address":{"type":"string","title":"Residential Address"},"id_document_type":{"$ref":"#/components/schemas/DocumentType"},"id_document_number":{"type":"string","title":"Id Document Number"},"id_document_path":{"type":"string","title":"Id Document Path"},"id_document_back_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Back Path"},"liveness_check_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Liveness Check Path"},"verification_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Notes"},"consent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consent","default":false},"id":{"type":"string","format":"uuid","title":"Id"}},"type":"object","required":["session_id","full_name","date_of_birth","nationality","ownership_percentage","residential_address","id_document_type","id_document_number","id_document_path","id"],"title":"UBOResponse"},"DocumentType":{"type":"string","enum":["PASSPORT","NRIC","DRIVING_LICENSE","AADHAAR","PAN","BANK_STATEMENT","UTILITY_BILL"],"title":"DocumentType"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## PUT /ubos/{ubo\_id}

> Update Ubo

```json
{"openapi":"3.1.0","info":{"title":"BeetleLabs","version":"1.0.0"},"servers":[{"url":"https://beetlelabs.ai/beetlelabs-verification","description":"Local development server"}],"paths":{"/ubos/{ubo_id}":{"put":{"tags":["UBOs"],"summary":"Update Ubo","operationId":"update_ubo_ubos__ubo_id__put","parameters":[{"name":"ubo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ubo Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UBOUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UBOResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"UBOUpdate":{"properties":{"full_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Name"},"date_of_birth":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date Of Birth"},"nationality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nationality"},"ownership_percentage":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ownership Percentage"},"residential_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Residential Address"},"id_document_type":{"anyOf":[{"$ref":"#/components/schemas/DocumentType"},{"type":"null"}]},"id_document_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Number"},"id_document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Path"},"id_document_back_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Back Path"},"liveness_check_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Liveness Check Path"},"verification_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Notes"},"consent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consent"}},"type":"object","title":"UBOUpdate"},"DocumentType":{"type":"string","enum":["PASSPORT","NRIC","DRIVING_LICENSE","AADHAAR","PAN","BANK_STATEMENT","UTILITY_BILL"],"title":"DocumentType"},"UBOResponse":{"properties":{"session_id":{"type":"string","format":"uuid","title":"Session Id"},"full_name":{"type":"string","title":"Full Name"},"date_of_birth":{"type":"string","format":"date","title":"Date Of Birth"},"nationality":{"type":"string","title":"Nationality"},"ownership_percentage":{"type":"integer","title":"Ownership Percentage"},"residential_address":{"type":"string","title":"Residential Address"},"id_document_type":{"$ref":"#/components/schemas/DocumentType"},"id_document_number":{"type":"string","title":"Id Document Number"},"id_document_path":{"type":"string","title":"Id Document Path"},"id_document_back_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id Document Back Path"},"liveness_check_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Liveness Check Path"},"verification_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Notes"},"consent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consent","default":false},"id":{"type":"string","format":"uuid","title":"Id"}},"type":"object","required":["session_id","full_name","date_of_birth","nationality","ownership_percentage","residential_address","id_document_type","id_document_number","id_document_path","id"],"title":"UBOResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## DELETE /ubos/{ubo\_id}

> Delete Ubo

```json
{"openapi":"3.1.0","info":{"title":"BeetleLabs","version":"1.0.0"},"servers":[{"url":"https://beetlelabs.ai/beetlelabs-verification","description":"Local development server"}],"paths":{"/ubos/{ubo_id}":{"delete":{"tags":["UBOs"],"summary":"Delete Ubo","operationId":"delete_ubo_ubos__ubo_id__delete","parameters":[{"name":"ubo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ubo Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```
