Skip to main content

Create public car rental reservation (v1)

Method & Path

POST /api/v1/public/:workspaceSlug/carrental/reservations

Actual path: /v1/public/:workspaceSlug/carrental/reservations

Description

Create a rental reservation (status PENDING). Creates or finds customer by phone/email; optional document uploads (license, ID); returns reservationId and referenceCode.

Authentication

None – Public endpoint.

Headers

Content-Type: multipart/form-data

Path parameters

ParameterTypeRequiredDescription
workspaceSlugstringYesPublic slug from carrental-settings.

Request body (multipart fields)

FieldTypeRequiredDescription
fullNamestringYesCustomer full name.
phonestringYesCustomer phone.
emailstringNoCustomer email.
idNumberstringNoID number.
driverLicenseNumberstringNoDriver license number.
pickupAtstringYesISO 8601 datetime.
dropoffAtstringYesISO 8601 datetime.
pickupLocationTypestringYesBRANCH or DELIVERY.
dropoffLocationTypestringYesBRANCH or DELIVERY.
branchIdstringYesBranch ID (for BRANCH pickup/return).
vehicleIdstringYesVehicle ID.
pickupAddressstringNoAddress when DELIVERY.
dropoffAddressstringNoAddress when DELIVERY.
depositnumberNoDeposit amount.
notesstringNoNotes.
licenseDocfileNoDriver license image.
idDocfileNoID document image.
otherDocfileNoUp to 3 other documents.

Response 201 Created

{
"reservationId": "...",
"referenceCode": "ABC12XY"
}

Common errors

  • 400: Validation failed (missing required fields, invalid dates).
  • 404: Car rental not found for this slug, or vehicle/branch not found.
  • 500: Server error.