---
title: "Create Delegation"
method: POST
path: "/api/delegations"
---

# Create Delegation

`POST /api/delegations`

## Request

- Base URL: `https://api.kojiru.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.kojiru.com/api/delegations`
- Auth: HTTP bearer

Create an ERC-7710 scoped delegation for a lender's pool.

## Request body

- DelegationCreate
  - `scope` DelegationScope, required
    - `max_per_loan` number: Max KOJIRU per single loan
    - `max_per_day` number: Max total disbursement per day
    - `max_per_week` number: Max total disbursement per week
    - `max_total_pool` number: Total lending pool budget
    - `min_credit_score` integer: Minimum borrower credit score
    - `max_concurrent_loans` integer: Max active loans at once
    - `collateral_required` boolean: Require collateral for disbursement
    - `min_collateral_ratio` number: Min collateral-to-loan ratio (e.g. 1.2 = 120%)
    - `allowed_purposes` string[]: Restrict to specific loan purposes (empty = all)
    - `time_window_start` string, nullable: ISO datetime — delegation active from
    - `time_window_end` string, nullable: ISO datetime — delegation expires at
    - `auto_revoke_on_default` boolean: Revoke borrower access on default
  - `label` string, nullable

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/kojiru/apis/kojiru-api.md) · [All operations](https://skmtc.dev/kojiru/apis/kojiru-api/llms.txt) · [OpenAPI document](https://skmtc.dev/kojiru/apis/kojiru-api/revisions/7974409f57cd?raw)
