Errors & Troubleshooting
When something goes wrong, the FairePlace API returns structured error responses with enough detail to diagnose and fix the issue.
Error response format
Every error follows this structure:
Code
| Field | Description |
|---|---|
error.code | HTTP status code |
error.type | Machine-readable error type (e.g., VALIDATION_ERROR, NOT_FOUND) |
error.message | Human-readable description |
error.details | Additional context (field names, constraints, etc.) |
meta.request_id | Unique request identifier — include this when contacting support |
meta.timestamp | When the error occurred |
HTTP status codes
| Code | Type | When it happens |
|---|---|---|
| 400 | Bad Request | Malformed JSON, invalid UUID format, missing required fields |
| 401 | Unauthorized | Missing, expired, or invalid API key |
| 403 | Forbidden | Valid token but insufficient permissions |
| 404 | Not Found | Resource doesn't exist or belongs to another tenant |
| 409 | Conflict | Cannot delete resource with dependencies (e.g., place with estates) |
| 422 | Unprocessable Entity | Valid JSON but business rule violation (e.g., rent exceeds cap) |
| 429 | Too Many Requests | Rate limit exceeded |
| 500 | Internal Server Error | Unexpected server error — contact support with request_id |
Common errors and fixes
400 — Invalid UUID format
Code
Fix: Use a valid UUID v4 format: 550e8400-e29b-41d4-a716-446655440000.
400 — Missing required field
Code
Fix: Check the API module documentation for required fields.
401 — Token expired
Code
Fix: Generate a new API key from the FairePlace dashboard. See Authentication for details.
403 — Permission denied
Code
Fix: Your token is missing the required permission. See Authentication for the full permissions table.
404 — Resource not found
Code
Common causes:
- The UUID is wrong or has a typo
- The resource belongs to a different tenant (cross-tenant access returns 404, not 403)
- The resource was deleted
409 — Dependency conflict
Code
Fix: Remove dependent resources first. For example, delete all estates in a place before deleting the place itself.
422 — Rent cap violation
Code
Fix: The rent per square meter exceeds the reference rent (loyer de reference majore) for the property's area. Lower the rent amount or check if a rent complement (complement de loyer) applies.
422 — Deposit limit exceeded
Code
Fix: French law limits the security deposit to 1 month's rent (excluding charges) for unfurnished leases, and 2 months for furnished leases.
422 — IRL revision violation
Code
Fix: Annual rent revisions are capped by the IRL index. Use New rent = Previous rent × (New IRL / Previous IRL).
429 — Rate limit exceeded
Code
Fix: Wait until the rate limit resets. Check these response headers:
| Header | Description |
|---|---|
X-RateLimit-Limit | Maximum requests per hour (1,000) |
X-RateLimit-Remaining | Requests remaining in current window |
X-RateLimit-Reset | Unix timestamp when the window resets |
Retry-After | Seconds to wait before retrying (on 429 responses) |
409 — Active lease dependency
Code
Fix: End or transfer all active leases for this tenant before deleting them.
Common pitfalls
- Expired API key → 401: Generate a new key from the dashboard
- Missing permission → 403: Check which permission the endpoint requires
- Rate limited → 429: Implement exponential backoff with
Retry-Afterheader - Compliance violation → 422 COMPLIANCE_ERROR: rent exceeds cap, deposit exceeds limit, IRL cap exceeded
- Dependency conflict → 409: Cannot delete resource with active dependencies
Retry strategy
For transient errors (429, 500), use exponential backoff:
Code
Do not retry 400, 401, 403, 404, 409, or 422 errors — these require fixing the request.
Python retry example
Code
Which errors to retry
| Code | Retry? | Strategy |
|---|---|---|
| 429 | Yes | Wait for Retry-After header value |
| 500 | Yes | Exponential backoff (1s, 2s, 4s) |
| 400, 401, 403, 404, 409, 422 | No | Fix the request |
Debugging checklist
When you get an unexpected error:
- Check the
request_id— Include it when contacting support - Verify your API key — Is it expired? Check the key status in your FairePlace dashboard under Parametres > Developpeur > Cles API
- Check the
tenant_id— Are you targeting the right organization? - Validate UUIDs — Ensure all IDs are valid UUID v4 format
- Review required fields — Check the API module docs for the endpoint you're calling
- Check dependencies — Does the parent resource exist? (e.g., does the
estate_idexist before creating a lease?) - Inspect the full error — The
detailsfield often tells you exactly what to fix
Known constraints
Things to be aware of when integrating:
| Constraint | Details |
|---|---|
| Rate limits | 1,000 req/hour on Starter plan. No burst pooling across keys. |
| No batch endpoints | Each resource must be created individually. No bulk create/update. |
| UUID references only | All cross-resource references use UUIDs. No slug or name-based lookups. |
| Deletion is hard | Resources with dependencies cannot be deleted. Remove children first. |
| No soft delete | Deleted resources are permanently removed. No trash or recovery. |
| PDF generation is synchronous | Large lease PDFs (20+ pages) may take 5-10 seconds. Plan for timeouts. |
| Signature credits are non-refundable | Credits are consumed at initiation, not completion. Cancelled/expired signatures are not refunded. |
| France only | Regulatory compliance covers French law only. No international support yet. |
| No webhooks for all events | Webhooks are currently limited to Stripe payment events. Signature status requires polling. |
| No real-time updates | Use polling for signature status. Recommended interval: every 30 seconds. |