Customer accounts: sign-up and sign-in
An external website’s customer area: sign-up, sign-in, session, profile, forgotten password, the signed-in customer’s bookings.
The /car-rental/accounts/… routes give your website (or app) a customer area: sign-up, sign-in, forgotten password, driver profile, and the signed-in customer’s bookings. Scope: rental_accounts — a QuoRent or QuoSuite key.
1. Two account realms
| Request | Accounts | Requires |
|---|---|---|
without siteId | API channel accounts, specific to your integrations | car rental |
with siteId | accounts of the rental website’s customer area: a customer registered on the site also signs in on yours, same password | the Website module |
The two are kept separate: one email can have an account in each, with two passwords. Every account is backed by the ERP customer record found by email (created otherwise) — the one bookings, agreements and invoices point to (customerId).
2. Sign up, sign in
POST/car-rental/accounts/register
curl -X POST 'https://quosuite.com/api/public/v1/quosuite/car-rental/accounts/register' \
-H "Authorization: Bearer $QUOSUITE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"email": "leila@example.tn",
"password": "a-strong-password",
"firstName": "Leila",
"lastName": "Trabelsi",
"phone": "+216 22 000 000",
"locale": "en"
}'The response carries session: the customer is signed in. Send it back in the X-Rental-Session header of every /car-rental/accounts/me… route. It lasts 30 days, extended on each use.
POST/car-rental/accounts/login
curl -X POST 'https://quosuite.com/api/public/v1/quosuite/car-rental/accounts/login' \
-H "Authorization: Bearer $QUOSUITE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"email": "leila@example.tn",
"password": "a-strong-password"
}'| Case | Response |
|---|---|
| wrong email or password, disabled account | 401 CUSTOMER_AUTH_FAILED — without saying which |
| address already registered (sign-up) | 409 CONFLICT, detail.rule: EMAIL_UNAVAILABLE |
| session missing, expired, closed | 401 CUSTOMER_SESSION_INVALID |
3. The account
GET /car-rental/accounts/me returns contact details and driver documents; PATCH updates them. These documents prefill your bookings’ driver; the ERP record follows the name and phone, and its documents are only filled where empty.
curl -X PATCH 'https://quosuite.com/api/public/v1/quosuite/car-rental/accounts/me' \
-H "Authorization: Bearer $QUOSUITE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"phone": "+216 98 000 000",
"birthDate": "1992-03-04",
"drivingLicenseNumber": "TN-998877"
}'4. Book, follow, cancel
POST /car-rental/accounts/me/bookings takes the same body as POST /car-rental/bookings (same mandatory Idempotency-Key, same refusals); the booking is attached to the account: its customer record, its site — or none for an API channel account. A customerId or siteId naming something else is refused (400).
POST/car-rental/accounts/me/bookings
# One key per operation, reused as is on every retry.
curl -X POST 'https://quosuite.com/api/public/v1/quosuite/car-rental/accounts/me/bookings' \
-H "Authorization: Bearer $QUOSUITE_API_KEY" \
-H 'Idempotency-Key: 3f1c2a9e-5b7d-4e8a-9c1f-2d6b8e4a7c30' \
-H 'Content-Type: application/json' \
-d '{
"vehicleId": "0b3c5d7e-9f1a-4b2c-8d4e-6f7a8b9c0d1e",
"startAt": "2026-12-20T09:00:00Z",
"endAt": "2026-12-27T09:00:00Z",
"driver": {
"firstName": "Leila",
"lastName": "Trabelsi",
"email": "leila@example.tn",
"phone": "+216 98 000 000",
"birthDate": "1992-03-04",
"drivingLicenseNumber": "TN-998877",
"drivingLicenseIssuedAt": "2014-06-01"
},
"payment": {
"mode": "AGENCY"
},
"acceptTerms": true
}'Then: GET /car-rental/accounts/me/bookings (their bookings, in the shape of GET /car-rental/bookings), the detail, the PDF (…/documents/voucher|contract|invoice) and cancellation by the customer, under the channel’s cancellation policy (deadline, fees, refund). Another customer’s booking answers 404.
POST/car-rental/accounts/me/bookings/{id}/cancel
# One key per operation, reused as is on every retry.
curl -X POST 'https://quosuite.com/api/public/v1/quosuite/car-rental/accounts/me/bookings/9f8e7d6c-5b4a-4392-8170-6f5e4d3c2b1a/cancel' \
-H "Authorization: Bearer $QUOSUITE_API_KEY" \
-H 'Idempotency-Key: 3f1c2a9e-5b7d-4e8a-9c1f-2d6b8e4a7c30' \
-H 'Content-Type: application/json' \
-d '{
"reason": "Change of plans"
}'5. Forgotten password
POST/car-rental/accounts/password/forgot
curl -X POST 'https://quosuite.com/api/public/v1/quosuite/car-rental/accounts/password/forgot' \
-H "Authorization: Bearer $QUOSUITE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"email": "leila@example.tn",
"resetUrl": "https://rental.example.com/account/new-password"
}'If the address has an account, the customer receives a link valid for 60 minutes to your page resetUrl, with token as a parameter; the response is the same in every case. Without siteId, resetUrl is mandatory; for a site account, the link leads to the site’s page by default. Your page then sends back the token and the new password — all the account’s sessions are closed:
POST/car-rental/accounts/password/reset
curl -X POST 'https://quosuite.com/api/public/v1/quosuite/car-rental/accounts/password/reset' \
-H "Authorization: Bearer $QUOSUITE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"token": "R8x…received-in-the-link",
"password": "new-password"
}'- POST
/car-rental/accounts/registerRegister a customer - POST
/car-rental/accounts/loginSign a customer in - POST
/car-rental/accounts/logoutSign a customer out - GET
/car-rental/accounts/meSigned-in customer’s account - PATCH
/car-rental/accounts/meUpdate the signed-in customer’s account - POST
/car-rental/accounts/me/passwordChange the password - POST
/car-rental/accounts/password/forgotForgotten password - POST
/car-rental/accounts/password/resetNew password (link received) - GET
/car-rental/accounts/me/bookingsSigned-in customer’s bookings - GET
/car-rental/accounts/me/bookings/{id}One of the signed-in customer’s bookings - POST
/car-rental/accounts/me/bookingsBook for the signed-in customer - POST
/car-rental/accounts/me/bookings/{id}/cancelCancel one of the signed-in customer’s bookings - GET
/car-rental/accounts/me/bookings/{id}/documents/{kind}PDF of one of the signed-in customer’s bookings
Customer rentals
GET /car-rental/accounts/me/rentals lists contracts linked to the authenticated account’s bookings in its realm; GET /car-rental/accounts/me/rentals/{id} returns one. Both require X-Rental-Session and rental_accounts:read. Another account’s rental returns 404. QuoRent cannot call tenant-wide booking, reservation, contract or driver routes.