Cliquéalo for developers

Loan quotes

List your loan products and quote a car with a PDF, emailed to the customer or returned to your system.

With the cotizaciones:crear permission. Your system only quotes your dealership's published cars, with your dealership's loan products and the same conditions as your ad.

Your loan products

curl https://www.cliquealo.mx/api/v1/cotizaciones/productos \
  -H "x-cliquealo-api-key: $CLIQUEALO_API_KEY"
{ "ok": true, "productos": [ { "id": "ac63bb03-…", "nombre": "Crédito Auto", "descripcion": "De 12 a 60 meses, enganche desde 25%", "banco": { "nombre": "Banco", "slug": "banco" }, "tasa_anual": 14.99, "comision_apertura": 2.5, "enganche_minimo_porcentaje": 25, "plazo_min_meses": 12, "plazo_max_meses": 60, "monto_min_mxn": 50000, "monto_max_mxn": 2000000, "seguro_obligatorio": false, "promocion": null } ] }

Rates and percentages are in percent and amounts in pesos. When a product has an active season, promocion says which one and when it ends, and the rate already includes it. This list counts toward the same hourly limit as quotes: keep it on your side.

Quote

curl https://www.cliquealo.mx/api/v1/cotizaciones \
  -H "x-cliquealo-api-key: $CLIQUEALO_API_KEY" -H "content-type: application/json" \
  -d '{"publicacion_slug":"toyota-corolla-2023","producto_credito_id":"ac63bb03-…","enganche_mxn":70000,"plazo_meses":48,"modo":"email","contacto_email":"customer@email.com"}'
FieldNotes
publicacion_slugA published car from your dealership
producto_credito_idOne of your products
enganche_mxnDown payment in pesos. It's adjusted to the product's range; the response has the one used
plazo_mesesWithin the product's term
modoemail: we email the PDF to the customer. pdf: we return the PDF and send nothing
contacto_emailRequired with email; optional with pdf
pruebatrue for tests: the quote doesn't count as real demand

With modo: "email" it responds 201 with the quote:

{ "ok": true, "id": "…", "email_enviado": true, "cotizacion": { "folio": "D259CABF", "precio_mxn": 159000, "enganche_mxn": 50000, "monto_financiado_mxn": 109000, "plazo_meses": 48, "tasa_anual": 14.99, "comision_apertura_mxn": 2725, "pago_mensual_mxn": 3033, "total_credito_mxn": 148308.94, "costo_total_mxn": 198308.94 } }

With modo: "pdf" it responds 201 with the PDF and the Cliquealo-Cotizacion-Id, Cliquealo-Cotizacion-Folio, and Cliquealo-Pago-Mensual-Mxn headers. Without contacto_email the quote is recorded as a simulation.

The customer gets the same email as when they quote from your ad, with the reference number and who follows up. In your panel, the quote shows up on the car as «Desde tu sistema» ("From your system").

Errors

StatuscodigoWhat happened
400campo_invalido, campo_desconocido, cuerpo_invalidoA field is missing, extra, or has a value that isn't accepted; campo says which
404no_encontradaThe car doesn't exist, isn't published, or belongs to another dealership
404producto_no_encontradoThe product doesn't exist, isn't active, or doesn't apply to that car
422no_aplicaThe product doesn't apply: term, financed amount, price, year, mileage, make, model, or origin of the car. error has the reason and campo the field
429limite_contactoThat address already got 4 emailed quotes in the last hour (counting your ad's). Retry-After says how long to wait
502correo_no_enviadoThe quote was recorded (id), but the email didn't go out. Ask for the PDF with modo: "pdf"