API reference
Bank accounts
Manage the settlement RIBs that MyTPE pays your collected funds into.
A bank account is the RIB that settlements are paid into. The account_number is the 20‑digit
Algerian RIB; MyTPE derives bank_code from it. Every bank account belongs to one
identification and must be accepted before it can back a
payment instance.
Statuses reference
Bank account status values (pending, accepted, refused) are defined in
Statuses & enums → KYC.
Endpoints
| Method | Path | Description |
|---|---|---|
GET | /bank-accounts | List bank accounts (paginated). |
POST | /bank-accounts | Create a bank account. |
GET | /bank-accounts/{id} | Retrieve one bank account. |
PUT | /bank-accounts/{id} | Update a bank account. |
DELETE | /bank-accounts/{id} | Delete a bank account. |
The bank account object
| Field | Type | Description |
|---|---|---|
id | string (uuid) | Unique identifier. |
account_number | string | 20‑digit RIB. |
bank_code | string | Bank code derived from the RIB. |
status | string | KYC status — see statuses. |
reason | string | null | Reason when refused. |
identification_id | string (uuid) | Parent identification. |
identification | object | { id, name } when loaded. |
created_at / updated_at | string (ISO 8601) | Timestamps. |
List bank accounts
Query parameters: search, sort_by, sort_dir, per_page.
curl "https://api.mytpe.appp/api/ext/bank-accounts?per_page=15" \
-H "X-Api-Key: $MYTPE_API_KEY" \
-H "X-Api-Secret: $MYTPE_API_SECRET"{
"data": [
{
"id": "2d3e4f5a-6b7c-8d9e-0f1a-2b3c4d5e6f7a",
"account_number": "00799999000123456789",
"bank_code": "007",
"status": "accepted",
"reason": null,
"identification_id": "0b1d2e3f-4a5b-6c7d-8e9f-0a1b2c3d4e5f",
"created_at": "2026-06-09T10:10:00.000000Z",
"updated_at": "2026-06-09T11:00:00.000000Z"
}
],
"links": { "first": "...?page=1", "last": "...?page=1", "prev": null, "next": null },
"meta": { "current_page": 1, "from": 1, "to": 1, "per_page": 15, "last_page": 1, "total": 1 }
}Create a bank account
| Field | Type | Required | Notes |
|---|---|---|---|
account_number | string | yes | Exactly 20 digits, valid RIB checksum. |
identification_id | uuid | yes | Must be an existing identification. |
curl -X POST https://api.mytpe.appp/api/ext/bank-accounts \
-H "X-Api-Key: $MYTPE_API_KEY" \
-H "X-Api-Secret: $MYTPE_API_SECRET" \
-H "Content-Type: application/json" \
-d '{
"account_number": "00799999000123456789",
"identification_id": "0b1d2e3f-4a5b-6c7d-8e9f-0a1b2c3d4e5f"
}'{
"data": {
"id": "2d3e4f5a-6b7c-8d9e-0f1a-2b3c4d5e6f7a",
"account_number": "00799999000123456789",
"bank_code": "007",
"status": "pending",
"reason": null,
"identification_id": "0b1d2e3f-4a5b-6c7d-8e9f-0a1b2c3d4e5f",
"created_at": "2026-06-09T10:10:00.000000Z",
"updated_at": "2026-06-09T10:10:00.000000Z"
}
}Retrieve a bank account
curl https://api.mytpe.appp/api/ext/bank-accounts/2d3e4f5a-6b7c-8d9e-0f1a-2b3c4d5e6f7a \
-H "X-Api-Key: $MYTPE_API_KEY" \
-H "X-Api-Secret: $MYTPE_API_SECRET"{
"data": {
"id": "2d3e4f5a-6b7c-8d9e-0f1a-2b3c4d5e6f7a",
"account_number": "00799999000123456789",
"bank_code": "007",
"status": "accepted",
"reason": null,
"identification_id": "0b1d2e3f-4a5b-6c7d-8e9f-0a1b2c3d4e5f",
"identification": { "id": "0b1d2e3f-4a5b-6c7d-8e9f-0a1b2c3d4e5f", "name": "Boutique Centrale SARL" },
"created_at": "2026-06-09T10:10:00.000000Z",
"updated_at": "2026-06-09T11:00:00.000000Z"
}
}Update a bank account
Accepts the same fields as create.
curl -X PUT https://api.mytpe.appp/api/ext/bank-accounts/2d3e4f5a-6b7c-8d9e-0f1a-2b3c4d5e6f7a \
-H "X-Api-Key: $MYTPE_API_KEY" \
-H "X-Api-Secret: $MYTPE_API_SECRET" \
-H "Content-Type: application/json" \
-d '{ "account_number": "00811111000987654321" }'{
"data": {
"id": "2d3e4f5a-6b7c-8d9e-0f1a-2b3c4d5e6f7a",
"account_number": "00811111000987654321",
"bank_code": "008",
"status": "pending",
"reason": null,
"identification_id": "0b1d2e3f-4a5b-6c7d-8e9f-0a1b2c3d4e5f",
"created_at": "2026-06-09T10:10:00.000000Z",
"updated_at": "2026-06-09T12:00:00.000000Z"
}
}Delete a bank account
curl -X DELETE https://api.mytpe.appp/api/ext/bank-accounts/2d3e4f5a-6b7c-8d9e-0f1a-2b3c4d5e6f7a \
-H "X-Api-Key: $MYTPE_API_KEY" \
-H "X-Api-Secret: $MYTPE_API_SECRET"{ "message": "Bank account deleted." }A bank account that a payment instance depends on cannot be deleted while the instance exists.