Create Vehicle / Crear Vehiculo
POST
/external/vehiculo
const url = 'https://api-dev.zonaparqueo.com/external/vehiculo';const options = { method: 'POST', headers: {Authorization: '<Authorization>', 'Content-Type': 'application/json'}, body: '{"cliente_id":1,"placa":"example","nombre":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api-dev.zonaparqueo.com/external/vehiculo \ --header 'Authorization: <Authorization>' \ --header 'Content-Type: application/json' \ --data '{ "cliente_id": 1, "placa": "example", "nombre": "example" }'Creates a vehicle linking a license plate with a client. This is step 2
of onboarding: it requires the plate to already exist (see POST /external/placa).
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
cliente_id
required
Client identifier
integer
placa
required
License plate
string
nombre
Vehicle name or alias (optional)
string
Examplegenerated
{ "cliente_id": 1, "placa": "example", "nombre": "example"}Responses
Section titled “Responses”Vehicle created successfully
Media typeapplication/json
object
estado
string
data
object
id
Vehicle identifier
integer
nombre
Vehicle name or alias
string
placa
License plate
string
cliente_id
Client identifier
integer
activado
Activation status
integer
favorito
Marked as favorite
integer
Examples
Examplesuccess
{ "estado": "ok", "data": { "id": 10, "nombre": "Mi carro", "placa": "ABC123", "cliente_id": 5, "activado": 1, "favorito": 0 }}Validation error
Media typeapplication/json
object
estado
string
error
Error message
string
errores
Field-specific error details
object
Example
{ "estado": "fail"}