# updateCompanyIndividual

Source: /openapi/thomas-federated.openapi.json

## Operation

| Method | URL |
|---|---|
| PATCH | https://api.thomas.co/v1/company-individuals/{id} |

| Field | Value |
|---|---|
| operationId | updateCompanyIndividual |
| method | PATCH |
| server | https://api.thomas.co/v1 |
| path | /company-individuals/{id} |
| tags | `People Administration` |
| summary | Update company-individual |
| badges | `{"name":"Admin"}`, `{"name":"Owner"}` |

## Request Parameters

| Name | In | Required | Schema | Description |
|---|---|---|---|---|
| id | path | true | string |  |

## Request Body

| Content type | Schema refs |
|---|---|
| application/json | #/components/schemas/UpdateCompanyIndividualDto |

## Responses

| Status | Description | Schema refs |
|---|---|---|
| 200 | Company-individual updated | #/components/schemas/CompanyIndividualResponseDto |
| 400 | Invalid UUID format for id parameter or invalid payload | #/components/schemas/ApiErrorResponseDto |
| 401 | Invalid or missing authentication token (AUTH_TOKEN_INVALID) | #/components/schemas/ApiErrorResponseDto |
| 403 | Insufficient role — admin or owner required | #/components/schemas/ApiErrorResponseDto |
| 404 | Company-individual not found (or hidden from the caller — no existence leak) | #/components/schemas/ApiErrorResponseDto |
| 409 | Duplicate relationship (IDENTITY_COMPANY_INDIVIDUAL_DUPLICATE) or duplicate HRIS id (IDENTITY_HRIS_ID_DUPLICATE) | #/components/schemas/ApiErrorResponseDto |

## Artifact Examples

### Response 400 example

```json
{
  "statusCode": 400,
  "message": "Validation failed (uuid is expected)",
  "error": "HTTP_BAD_REQUEST"
}
```

### Response 401 example

```json
{
  "statusCode": 401,
  "message": "Invalid or missing authentication token",
  "error": "AUTH_TOKEN_INVALID"
}
```

### Response 403 example

```json
{
  "statusCode": 403,
  "message": "Insufficient role privileges",
  "error": "AUTH_INSUFFICIENT_ROLE"
}
```

### Response 404 example

```json
{
  "statusCode": 404,
  "message": "Company-individual not found",
  "error": "IDENTITY_COMPANY_INDIVIDUAL_NOT_FOUND"
}
```

### Response 409 example

```json
{
  "statusCode": 409,
  "message": "A company-individual relationship already exists",
  "error": "IDENTITY_COMPANY_INDIVIDUAL_DUPLICATE"
}
```
