Mocks (Sandbox)
The API is still in development phase, therefore, this manual is subject to changes.
The homologation (sandbox) environment has a mock system that simulates different SNG/B3 response scenarios during lien registration. The behavior is controlled by the borrower's name field when creating the debt (POST /debt).
Any name that is not in the scenario list below will follow the default success flow: the lien will be registered (reserved), followed by automatic contract creation (pending_registration_confirmation) and progression to disbursement. Two webhooks are sent in sequence: reservation.status_change (status reserved) and contract.status_change (status pending_registration_confirmation). For details on the webhook structure, see the Webhooks page.
Available Scenarios
Field Validation Error (HTTP 400)
When using the name bob, the lien creation is rejected with field validation errors in the payload.
| Name | Stage | Resulting Status | Webhook |
|---|---|---|---|
bob | Lien creation | pending_requester_action | Yes |
Full webhook example
{
"event_key": "a23bc45d-67ef-8901-abcd-234567890abc",
"event_type": "laas.vehicle_collateral.reservation.status_change",
"origin": "vehicle_collateral",
"origin_key": "<reservation_key>",
"person_key": "<requester_key>",
"receiver_contact": null,
"data": {
"callback": {
"webhook_type": "laas.vehicle_collateral.reservation.status_change",
"status": "pending_requester_action",
"event_datetime": "2026-04-08T15:30:00.000Z",
"data": {
"contract_number": "CTR-2026-001",
"rejection_details": [
{
"campo": "logradouroDevedor",
"mensagem": "caracter inválido / acima do tamanho permitido / tipo inválido / Ausência do campo"
},
{
"campo": "numTelDevedor",
"mensagem": "caracter inválido / acima do tamanho permitido"
}
]
}
}
}
}
Business Errors During Lien Confirmation
The scenarios below are triggered during the status confirmation stage. All result in pending_requester_action and send a webhook with error_code.
| Name | Error | error_code |
|---|---|---|
carol | Vehicle already has a registered financial restriction | vehicle_has_financial_restriction_already_registered |
dave | Chassis not found in BIN | chassis_not_found_in_bin |
frank | Plate in BIN, provide the vehicle plate | plate_in_bin_inform_plate_of_vehicle |
george | Plate divergent from BIN base | plate_informed_different_from_plate_informed_by_uf_of_registration_in_bin_base |
ian | Property number does not match the postal code | property_number_does_not_correspond_to_informed_postal_code |
jack | RENAVAM divergent | renavam_informed_different_from_renavam_informed_by_uf_of_registration_in_bin_base |
kate | Invalid property state | property_uf_invalid |
mary | Address with invalid fill | financied_address_with_invalid_fill |
olive | Model year divergent from BIN | model_year_informed_different_from_model_year_in_bin |
quinn | Open protocol in licensing state | protocol_open_in_uf_of_registration |
sara | Invalid borrower name and address | financied_name_and_address_with_invalid_fill |
taylor | Invalid borrower name | financied_name_with_invalid_fill |
vincent | Vehicle already reserved in state base | vehicle_already_reserved_in_state_base |
Full webhook example (carol scenario)
{
"event_key": "<uuid>",
"event_type": "laas.vehicle_collateral.reservation.status_change",
"origin": "vehicle_collateral",
"origin_key": "<reservation_key>",
"person_key": "<requester_key>",
"receiver_contact": null,
"data": {
"callback": {
"webhook_type": "laas.vehicle_collateral.reservation.status_change",
"key": "<reservation_key>",
"status": "pending_requester_action",
"event_datetime": "2026-04-08T15:30:00.000Z",
"data": {
"contract_number": "CTR-2026-001",
"error_code": "vehicle_has_financial_restriction_already_registered",
"error_reason_en": "Vehicle has financial restriction already registered",
"error_reason_pt": "Veículo com restrição financeira já cadastrada"
}
}
}
}
Definitive Refusal (no webhook)
In these cases, the reservation is definitively refused. No webhook is sent to the client.
| Name | Error | Resulting Status |
|---|---|---|
eve | Restriction in manufacturing BIN | refused |
robert | Vehicle with restriction | refused |
Automatic Reprocessing (no webhook)
In these cases, the message is returned for automatic reprocessing. No webhook is sent to the client.
| Name | Error | Behavior |
|---|---|---|
gabriel | Unknown error | Automatic reprocessing |
henry | Owner divergent in sale communication | Automatic reprocessing |
linda | Restriction in licensing state | Automatic reprocessing |
nancy | Address name exceeds 30 characters | Automatic reprocessing |
paul | Phone number exceeds 9 characters | Automatic reprocessing |
william | Unknown error | Automatic reprocessing |
Summary Table
| Name | Stage | Resulting Status | Webhook | Type |
|---|---|---|---|---|
bob | Creation (HTTP 400) | pending_requester_action | Yes | reservation.status_change with rejection_details |
carol | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
dave | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
eve | Confirmation | refused | No | — |
frank | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
george | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
gabriel | Confirmation | Reprocessing | No | — |
henry | Confirmation | Reprocessing | No | — |
ian | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
jack | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
kate | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
linda | Confirmation | Reprocessing | No | — |
mary | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
nancy | Confirmation | Reprocessing | No | — |
olive | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
paul | Confirmation | Reprocessing | No | — |
quinn | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
robert | Confirmation | refused | No | — |
sara | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
taylor | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
vincent | Confirmation | pending_requester_action | Yes | reservation.status_change with error_code |
william | Confirmation | Reprocessing | No | — |
| (other) | — | reserved + pending_registration_confirmation | Yes (2x) | reservation.status_change + contract.status_change |
The mocks above simulate only the lien registration (reservation) stage. The contract registration and image submission flow does not have dedicated mocks in the homologation environment.