> ## Documentation Index
> Fetch the complete documentation index at: https://api-docs.anzi.finance/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Guarantee

> API error codes for Create Guarantee (POST /guarantees)

# Error Codes

The API returns structured errors with a `code` and `message`. This page documents the error codes you may receive when calling **[Create Guarantee](/api-reference/guarantees/create-guarantee)** (POST /guarantees) and how to resolve them.

***

## Create Guarantee (POST /guarantees)

These codes are returned in the response body with HTTP status **400** when a guarantee cannot be created due to validation or business rules.

| Code    | Message                                                                                                                                                          |
| ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| LI\_01  | License Not Active                                                                                                                                               |
| GUA\_06 | This credit reference has already been used. Use a new one so we can process this guarantee.                                                                     |
| GUA\_08 | Premium percentage is out of range                                                                                                                               |
| GUA\_16 | Disbursement date is invalid: it is before the previous month or after today.                                                                                    |
| GUA\_26 | Enter the coverage value. Please provide it to continue with the guarantee creation.                                                                             |
| GUA\_27 | The total loan amount associated with guarantees exceeds the Portfolio Coverage Cap allowed by the license. Please adjust it to continue creating the guarantee. |
| GUA\_28 | The credit coverage exceeds the maximum amount allowed by the license. Please adjust it to complete the guarantee creation.                                      |
| GUA\_29 | Invalid loan amount for this license. Modify it so it falls within the allowed range                                                                             |
| GUA\_30 | Invalid loan durations                                                                                                                                           |
| GUA\_37 | It is not possible to calculate the guarantee premium. Check the data and try again                                                                              |
| GUA\_52 | Invalid disbursement date format                                                                                                                                 |
| GUA\_67 | Calculated premium percentage is out of range for this license                                                                                                   |
| GE\_01  | Bad Request                                                                                                                                                      |

***

## Cause and resolution

### LI\_01 — License not active

**What happened:** The license associated with your API key or the `license` query parameter is not currently active.

**What to do:** Verify that the license UID is correct and that the license has been activated. Contact your Anzi representative if the license should be active.

***

### GUA\_06 — Duplicate external reference

**What happened:** The `externalReference` you sent is already associated with an existing guarantee for this license.

**What to do:** Use a unique value for `externalReference` per guarantee (e.g. your internal credit or loan ID). Do not reuse the same reference across different guarantee creation requests.

***

### GUA\_08 — Premium percentage out of range

**What happened:** The `premiumPercentage` in the request is outside the min/max range defined in the [License](/core-concepts/license) configuration.

**What to do:** Check your License terms for the allowed premium percentage range. Ensure the value you send is within that range (inclusive).

***

### GUA\_16 — Disbursement date before previous month or after today

**What happened:** The `disbursementDate` is either before the previous calendar month or after the current date.

**What to do:** Use a disbursement date that is within the previous month or the current month (not in the future and not older than the previous month).

***

### GUA\_26 — Missing coverage value (SURETY)

**What happened:** For a SURETY-type license, the system could not compute a coverage value for this guarantee.

**What to do:** Ensure the loan amount and license configuration allow the coverage calculation to produce a valid result. Contact your Anzi representative if this error persists.

***

### GUA\_27 — Portfolio / coverage cap exceeded (SURETY)

**What happened:** For a SURETY-type license, the sum of `loanAmount` already associated with existing guarantees plus the `loanAmount` of the new guarantee would exceed the **Portfolio Coverage Cap** allowed by the License.

**What to do:** Reduce the `loanAmount` of this guarantee, or wait until other guarantees free up cap (e.g. closed or novated). You can also contact your Anzi representative if you need to adjust the license cap.

***

### GUA\_28 — Coverage exceeds maximum allowed

**What happened:** The coverage amount for this guarantee (derived from loan amount and coverage rules) exceeds the maximum **per-guarantee** coverage allowed by the License.

**What to do:** Lower the loan amount or the effective coverage so it stays within the license's maximum coverage per guarantee.

***

### GUA\_29 — Invalid loan amount

**What happened:** The `loanAmount` does not comply with the License configuration (e.g. below minimum, above maximum, or not allowed by product rules).

**What to do:** Check the License's min/max loan amount and product rules. Send a `loanAmount` within the allowed range and that matches the license terms.

***

### GUA\_30 — Invalid loan durations

**What happened:** The combination of dates or terms (e.g. `disbursementDate`, `paymentTerm`, or implied loan duration) is not allowed by the License (e.g. duration too short or too long).

**What to do:** Ensure `disbursementDate` and `paymentTerm` (and any other term-related fields) result in a loan duration that is within the License's allowed range.

***

### GUA\_37 — Cannot calculate guarantee premium

**What happened:** The premium could not be calculated, usually because required data for variable premium calculation is missing or invalid (e.g. loan terms, rates, or dates).

**What to do:** Verify that all fields required for premium calculation are present and valid (amounts, dates, terms). For variable premium licenses, ensure interest rate and payment schedule data are correct and consistent.

***

### GUA\_52 — Invalid disbursement date format

**What happened:** The `disbursementDate` value could not be parsed as a valid date.

**What to do:** Send `disbursementDate` in ISO 8601 format (e.g. `2025-09-05T00:00:00.000Z`). Ensure the date string is well-formed and represents a real calendar date.

***

### GUA\_67 — Calculated premium out of license bounds

**What happened:** The premium percentage that was automatically calculated (based on loan term and the license's rate table) falls outside the license's configured minimum/maximum premium bounds.

**What to do:** Adjust the loan term or amount so the resulting premium percentage falls within the license's allowed range. Contact your Anzi representative if you believe the license rate table needs updating.

***

### GE\_01 — Bad Request (generic)

**What happened:** The request failed a general validation or business rule that is not mapped to a specific GUA\_xx code.

**What to do:** Review the request body against the [Create Guarantee](/api-reference/guarantees/create-guarantee) schema and the [Guarantee Overview](/core-concepts/guarantee-overview). Check required fields, formats (e.g. dates, IDs), and license constraints. If the issue persists, use the exact `code` and `message` when contacting support.
