# Employee Bank Account Configuration

These endpoints let you manage bank account configurations specific to employees in the system. It allows you to retrieve, create, update, and delete employee-specific bank account configuration records.

## Get Employee Bank Account Configuration

> This endpoint is deprecated. Please use /v1/employees/{employeeId}/bank-account-configurations/histories instead.

```json
{"openapi":"3.0.0","info":{"title":"CATAPA API","version":"1.0.0"},"tags":[{"name":"employee-bank-account-configuration","description":"These endpoints let you manage bank account configurations specific to employees in the system.\nIt allows you to retrieve, create, update, and delete employee-specific bank account configuration records.\n"}],"servers":[{"url":"https://api.catapa.com","description":"Production server"}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer authentication header of the form `Bearer <token>`."}}},"paths":{"/core/v1/employees/{employeeId}/bank-account-configurations":{"get":{"tags":["employee-bank-account-configuration"],"summary":"Get Employee Bank Account Configuration","deprecated":true,"description":"This endpoint is deprecated. Please use /v1/employees/{employeeId}/bank-account-configurations/histories instead.","parameters":[{"in":"path","name":"employeeId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"employee":{"type":"object","properties":{"id":{"type":"string"},"identificationNumber":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"}}},"paymentMethod":{"type":"string","enum":["CASH","TRANSFER","NONE"]},"updatedDate":{"type":"integer","format":"timestamp in milliseconds"},"effectiveDate":{"type":"string","format":"date","description":"YYYY-MM-DD"},"distributionMethod":{"type":"string"},"defaultBankAccount":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"bankId":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}},"bankBranchId":{"type":"string"},"bankBranch":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"code":{"type":"string"},"address":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}}}},"accountNumber":{"type":"string"},"accountName":{"type":"string"},"beneficiaryId":{"type":"string"},"priority":{"type":"number"},"currency":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"baseCurrency":{"type":"boolean"}}},"percentage":{"type":"number"},"amount":{"type":"number"}}},"bankAccounts":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"bankId":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}},"bankBranchId":{"type":"string"},"bankBranch":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"code":{"type":"string"},"address":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}}}},"accountNumber":{"type":"string"},"accountName":{"type":"string"},"beneficiaryId":{"type":"string"},"priority":{"type":"number"},"currency":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"baseCurrency":{"type":"boolean"}}},"percentage":{"type":"number"},"amount":{"type":"number"}}}},"source":{"type":"object","properties":{"id":{"type":"string"}}},"approvalStatus":{"type":"string","enum":["APPROVED","REJECTED","OPEN","WAITING_FOR_APPROVAL"]}}}}}},"400":{"description":"Bad Request"}}}}}}
```

## Update Bank Account Configuration

> This endpoint is deprecated. Please use /v1/bank-account-configurations/approvals instead.

```json
{"openapi":"3.0.0","info":{"title":"CATAPA API","version":"1.0.0"},"tags":[{"name":"employee-bank-account-configuration","description":"These endpoints let you manage bank account configurations specific to employees in the system.\nIt allows you to retrieve, create, update, and delete employee-specific bank account configuration records.\n"}],"servers":[{"url":"https://api.catapa.com","description":"Production server"}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer authentication header of the form `Bearer <token>`."}}},"paths":{"/core/v1/employees/{employeeId}/bank-account-configurations":{"put":{"tags":["employee-bank-account-configuration"],"summary":"Update Bank Account Configuration","deprecated":true,"description":"This endpoint is deprecated. Please use /v1/bank-account-configurations/approvals instead.","parameters":[{"in":"path","name":"employeeId","schema":{"type":"string"},"required":true}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"employee":{"type":"object","properties":{"id":{"type":"string"},"identificationNumber":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"}}},"paymentMethod":{"type":"string","enum":["CASH","TRANSFER","NONE"]},"updatedDate":{"type":"integer","format":"timestamp in milliseconds"},"effectiveDate":{"type":"string","format":"date","description":"YYYY-MM-DD"},"distributionMethod":{"type":"string"},"defaultBankAccount":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"bankId":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}},"bankBranchId":{"type":"string"},"bankBranch":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"code":{"type":"string"},"address":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}}}},"accountNumber":{"type":"string"},"accountName":{"type":"string"},"beneficiaryId":{"type":"string"},"priority":{"type":"number"},"currency":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"baseCurrency":{"type":"boolean"}}},"percentage":{"type":"number"},"amount":{"type":"number"}}},"bankAccounts":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"bankId":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}},"bankBranchId":{"type":"string"},"bankBranch":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"code":{"type":"string"},"address":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}}}},"accountNumber":{"type":"string"},"accountName":{"type":"string"},"beneficiaryId":{"type":"string"},"priority":{"type":"number"},"currency":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"baseCurrency":{"type":"boolean"}}},"percentage":{"type":"number"},"amount":{"type":"number"}}}},"source":{"type":"object","properties":{"id":{"type":"string"}}},"approvalStatus":{"type":"string","enum":["APPROVED","REJECTED","OPEN","WAITING_FOR_APPROVAL"]}}}}}},"400":{"description":"Bad Request"}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"employee":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier"}},"required":["id"]},"effectiveDate":{"type":"string","format":"date","description":"YYYY-MM-DD"},"paymentMethod":{"type":"string","enum":["CASH","TRANSFER","NONE"]},"distributionMethod":{"type":"string","enum":["PERCENTAGE","FIXED_AMOUNT"]},"bankAccounts":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"companyBankAccount":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier"}},"required":["id"]},"bankId":{"type":"string"},"bankBranchId":{"type":"string"},"accountNumber":{"type":"string","description":"Numeric"},"accountName":{"type":"string","minLength":3,"maxLength":255},"beneficiaryId":{"type":"string","maxLength":255},"priority":{"type":"number","minimum":1},"currency":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier"}},"required":["id"]},"percentage":{"type":"number","minimum":0,"maximum":100},"amount":{"type":"number","minimum":0}},"required":["bankId","accountNumber","accountName","priority","currency","percentage","amount"]}},"source":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier"}},"required":["id"]}},"required":["paymentMethod"]}}}}}}}}
```

## Get Employee Bank Account Configuration Histories

> Use this endpoint as a replacement for /v1/employees/{employeeId}/bank-account-configurations.

```json
{"openapi":"3.0.0","info":{"title":"CATAPA API","version":"1.0.0"},"tags":[{"name":"employee-bank-account-configuration","description":"These endpoints let you manage bank account configurations specific to employees in the system.\nIt allows you to retrieve, create, update, and delete employee-specific bank account configuration records.\n"}],"servers":[{"url":"https://api.catapa.com","description":"Production server"}],"security":[{"BearerAuth":[]}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer authentication header of the form `Bearer <token>`."}}},"paths":{"/core/v1/employees/{employeeId}/bank-account-configurations/histories":{"get":{"tags":["employee-bank-account-configuration"],"summary":"Get Employee Bank Account Configuration Histories","description":"Use this endpoint as a replacement for /v1/employees/{employeeId}/bank-account-configurations.","parameters":[{"in":"path","name":"employeeId","schema":{"type":"string"},"required":true},{"in":"query","name":"page","description":"Page number","schema":{"type":"integer","minimum":0,"default":0}},{"in":"query","name":"size","description":"Page size","schema":{"type":"integer","minimum":1,"default":10,"maximum":50}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"allOf":[{"type":"object","required":["totalPages","last","totalElements","numberOfElements","first","size","number"],"properties":{"totalPages":{"type":"integer","description":"Total number of pages available"},"last":{"type":"boolean","description":"Indicates whether this is the last page"},"totalElements":{"type":"integer","description":"Total number of elements across all pages"},"numberOfElements":{"type":"integer","description":"Number of elements in the current page"},"sort":{"allOf":[{"type":"array","items":{"type":"object","required":["direction","property"],"properties":{"direction":{"type":"string"},"property":{"type":"string"},"ignoreCase":{"type":"boolean"},"nullHandling":{"type":"string"},"ascending":{"type":"boolean"},"descending":{"type":"boolean"}}}}],"description":"Sorting information for the page. Will be present when the request includes a sort parameter."},"first":{"type":"boolean","description":"Indicates whether this is the first page"},"size":{"type":"integer","description":"Size of the page (number of elements per page)"},"number":{"type":"integer","description":"Current page number (zero-indexed)"}}},{"type":"object","properties":{"content":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"employee":{"type":"object","properties":{"id":{"type":"string"},"identificationNumber":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"}}},"paymentMethod":{"type":"string","enum":["CASH","TRANSFER","NONE"]},"updatedDate":{"type":"integer","format":"timestamp in milliseconds"},"effectiveDate":{"type":"string","format":"date","description":"YYYY-MM-DD"},"distributionMethod":{"type":"string"},"defaultBankAccount":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"bankId":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}},"bankBranchId":{"type":"string"},"bankBranch":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"code":{"type":"string"},"address":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}}}},"accountNumber":{"type":"string"},"accountName":{"type":"string"},"beneficiaryId":{"type":"string"},"priority":{"type":"number"},"currency":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"baseCurrency":{"type":"boolean"}}},"percentage":{"type":"number"},"amount":{"type":"number"}}},"bankAccounts":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"bankId":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}},"bankBranchId":{"type":"string"},"bankBranch":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"name":{"type":"string"},"code":{"type":"string"},"address":{"type":"string"},"bank":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"llg":{"type":"string"}}}}},"accountNumber":{"type":"string"},"accountName":{"type":"string"},"beneficiaryId":{"type":"string"},"priority":{"type":"number"},"currency":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"code":{"type":"string"},"name":{"type":"string"},"baseCurrency":{"type":"boolean"}}},"percentage":{"type":"number"},"amount":{"type":"number"}}}},"source":{"type":"object","properties":{"id":{"type":"string"}}},"approvalStatus":{"type":"string","enum":["APPROVED","REJECTED","OPEN","WAITING_FOR_APPROVAL"]}}}}}}]}}}},"400":{"description":"Bad Request"}}}}}}
```
