Embedded credit API for Dinie partners. Enables customer registration, credit offer management, loan origination, and event delivery via webhooks.
Dinie API (2026-03-01)
OAuth2 Client Credentials authentication and API key management.
Each client_id / client_secret pair represents an access credential. Exchange the credentials for a JWT token via POST /auth/token and send the token as Bearer in all requests. The token expires in 1 hour.
You can create multiple credentials for different environments and revoke them individually.
The Customer resource (cust_) represents a credit borrower on the platform. The lifecycle follows: registration → KYC document submission → review → activation.
Two processes happen in parallel:
- Credit analysis — starts automatically upon registration
- KYC verification — the customer completes at their own pace
CreditOffer (available) → Simulation → Loan- Check the offers available for a customer
- Simulate different scenarios of amount and term
- Create the loan from the simulation chosen by the customer
# 1. List available offers
offers = client.customers.list_credit_offers("cust_abc123",
status: "available"
)
offer = offers.data.first
# offer.id => "co_550e8400..."
# offer.approved_amount => "50000.00"
# offer.min_amount => "5000.00"
# offer.interest_rate => 2.5 (% per month)
# offer.valid_until => "2026-04-01T00:00:00Z"
# 2. Simulate with different amounts
sim_25k = client.credit_offers.simulate(offer.id,
requested_amount: "25000.00",
installment_count: 6
)
sim_40k = client.credit_offers.simulate(offer.id,
requested_amount: "40000.00",
installment_count: 12
)
# 3. Present options to the customer
puts sim_25k.installments_value # "4550.00" per installment
puts sim_25k.cet_percentage # 35.2% per year
puts sim_40k.installments_value # "3800.00" per installment
puts sim_40k.cet_percentage # 32.8% per yearThe simulation calculates all loan costs before contracting:
| Field | Description |
|---|---|
requested_amount | Amount requested by the customer |
amount | Net amount the customer receives |
interest_amount | Total interest |
fees_amount | Total fees |
iof_amount | Calculated IOF |
total_loan_amount | Total amount (principal + interest + fees + IOF) |
installments_value | Fixed amount of each installment |
cet_percentage | Annualized Total Effective Cost |
first_due_date | Due date of the first installment |
| Event | When it fires |
|---|---|
credit_offer.available | New offer generated for the customer |
credit_offer.expired | Offer expired (valid_until exceeded) |
Request
Lists the available credit offers for a specific customer. Filterable by status (available, accepted, expired). Use this endpoint after receiving the customer.active webhook to check for pre-approved offers. Pagination uses cursor with starting_after + limit.
- Mock serverhttps://dinie.nexaedge.dev/_mock/apis/openapi/customers/{customer_id}/credit-offers
- Productionhttps://api.dinie.com.br/v3/customers/{customer_id}/credit-offers
- Sandboxhttps://sandbox.api.dinie.com.br/v3/customers/{customer_id}/credit-offers
- curl
- Python
- Node.js
- Ruby
curl "https://api.dinie.com.br/v3/customers/cust_550e8400e29b41d4a716446655440000/credit-offers?status=available" \
-H "Authorization: Bearer $DINIE_API_TOKEN"List of credit offers
| Enum Value | Description |
|---|---|
| available | Offer is active and can be accepted by the customer |
| accepted | Customer accepted the offer and a loan was created |
| expired | Offer passed the valid_until date without being accepted |
Decimal encoded as a string with exactly 2 decimal places (BRL).
Number of installments. When the product supports a range, this field is replaced by min_installments/max_installments
{ "data": [ { "id": "co_550e8400e29b41d4a716446655440000", "customer_id": "cust_550e8400e29b41d4a716446655440000", "status": "available", "approved_amount": "50000.00", "min_amount": "1000.00", "interest_rate": 3.5, "installments": 12, "due_date_rule": null, "valid_until": "2026-04-01T23:59:59Z", "created_at": "2026-03-04T10:00:00Z", "updated_at": "2026-03-04T10:00:00Z" } ], "has_more": false }
Request
Lists credit offers for all customers of the authenticated partner. Supports filters by customer_id and status to locate specific offers. Useful for dashboards and reports that need a consolidated view. For offers of a specific customer, prefer GET /customers/{customer_id}/credit-offers.
- Mock serverhttps://dinie.nexaedge.dev/_mock/apis/openapi/credit-offers
- Productionhttps://api.dinie.com.br/v3/credit-offers
- Sandboxhttps://sandbox.api.dinie.com.br/v3/credit-offers
- curl
- Python
- Node.js
- Ruby
# List all available credit offers
curl "https://api.dinie.com.br/v3/credit-offers?status=available&limit=10" \
-H "Authorization: Bearer $DINIE_API_TOKEN"List of credit offers
| Enum Value | Description |
|---|---|
| available | Offer is active and can be accepted by the customer |
| accepted | Customer accepted the offer and a loan was created |
| expired | Offer passed the valid_until date without being accepted |
Decimal encoded as a string with exactly 2 decimal places (BRL).
Number of installments. When the product supports a range, this field is replaced by min_installments/max_installments
{ "data": [ { "id": "co_550e8400e29b41d4a716446655440000", "customer_id": "cust_550e8400e29b41d4a716446655440000", "status": "available", "approved_amount": "50000.00", "min_amount": "1000.00", "interest_rate": 3.5, "installments": 12, "due_date_rule": null, "valid_until": "2026-04-01T23:59:59Z", "created_at": "2026-03-04T10:00:00Z", "updated_at": "2026-03-04T10:00:00Z" } ], "has_more": false }
Request
Returns the complete credit offer object, including approved amount (approved_amount), minimum amount, interest rate (interest_rate), maximum number of installments, and expiration date (valid_until). Query the offer before creating a simulation to present the limits to the customer.
- Mock serverhttps://dinie.nexaedge.dev/_mock/apis/openapi/credit-offers/{credit_offer_id}
- Productionhttps://api.dinie.com.br/v3/credit-offers/{credit_offer_id}
- Sandboxhttps://sandbox.api.dinie.com.br/v3/credit-offers/{credit_offer_id}
- curl
- Python
- Node.js
- Ruby
curl https://api.dinie.com.br/v3/credit-offers/co_550e8400e29b41d4a716446655440000 \
-H "Authorization: Bearer $DINIE_API_TOKEN"Credit offer details
| Enum Value | Description |
|---|---|
| available | Offer is active and can be accepted by the customer |
| accepted | Customer accepted the offer and a loan was created |
| expired | Offer passed the valid_until date without being accepted |
Decimal encoded as a string with exactly 2 decimal places (BRL).
Number of installments. When the product supports a range, this field is replaced by min_installments/max_installments
{ "id": "co_550e8400e29b41d4a716446655440000", "customer_id": "cust_550e8400e29b41d4a716446655440000", "status": "available", "approved_amount": "50000.00", "min_amount": "1000.00", "interest_rate": 3.5, "installments": 12, "due_date_rule": null, "valid_until": "2026-04-01T23:59:59Z", "created_at": "2026-03-04T10:00:00Z", "updated_at": "2026-03-04T10:00:00Z" }
Request
Fires when Dinie generates a new pre-approved credit offer for the customer. Includes approved amount, interest rate, installments, and offer expiration date. Use it to notify the customer about credit availability and start the simulation flow via POST /credit-offers/{id}/simulations.
Decimal encoded as a string with exactly 2 decimal places (BRL).
- Mock serverhttps://dinie.nexaedge.dev/_mock/apis/openapi/credit_offer.available
- Productionhttps://api.dinie.com.br/v3/credit_offer.available
- Sandboxhttps://sandbox.api.dinie.com.br/v3/credit_offer.available
Request
Fires when a credit offer expires after exceeding its expiration date (valid_until). Includes the full offer data with expired status. Use it to remove the offer from the customer interface. New offers may be generated in the future via credit_offer.available.
Decimal encoded as a string with exactly 2 decimal places (BRL).
- Mock serverhttps://dinie.nexaedge.dev/_mock/apis/openapi/credit_offer.expired
- Productionhttps://api.dinie.com.br/v3/credit_offer.expired
- Sandboxhttps://sandbox.api.dinie.com.br/v3/credit_offer.expired
Manage the endpoints that receive event notifications (we_). Dinie follows the Standard Webhooks specification.
Events for each resource are documented in the Customers, Credit Offers, and Loans sections. This section covers only endpoint management.