> For the complete documentation index, see [llms.txt](https://docs.creditcoop.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.creditcoop.xyz/developer-api-docs/models.md).

# Models

## The ErrorResponse object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"ErrorResponse":{"type":"object","required":["error"],"properties":{"error":{"type":"string"},"message":{"type":"string"},"statusCode":{"type":"integer"}}}}}}
```

## The Organization object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"Organization":{"type":"object","required":["id","name","slug"],"properties":{"id":{"type":"string","format":"uuid","description":"Organization unique identifier"},"name":{"type":"string","maxLength":255,"description":"Organization display name"},"slug":{"type":"string","maxLength":100,"description":"URL-friendly identifier"},"header":{"type":"string","nullable":true,"description":"Short tagline or headline for the organization profile"},"description":{"type":"string","nullable":true,"description":"Brief summary of the organization"},"overview":{"type":"string","nullable":true,"description":"Long-form organization description (may contain Markdown)"},"links":{"type":"array","description":"Organization links and image assets. Labels starting with \"#\" are image assets (e.g. \"#logo\", \"#header\"); all others are external links (e.g. \"Twitter\", \"Website\").","items":{"type":"object","required":["id","label","url"],"properties":{"id":{"type":"string","format":"uuid","description":"Link unique identifier"},"label":{"type":"string","description":"Link type. \"#logo\" and \"#header\" denote image assets; other values (e.g. \"Twitter\", \"Website\") denote external links."},"linkText":{"type":"string","nullable":true,"description":"Display text for external links (e.g. \"@raincards\", \"rain.xyz\")"},"iconUrl":{"type":"string","nullable":true,"description":"Icon image URL for external links"},"url":{"type":"string","description":"Target URL (image URL for asset links, destination URL for external links)"}}}}}}}}}
```

## The Pagination object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"Pagination":{"type":"object","required":["total","limit","offset"],"properties":{"total":{"type":"integer","description":"Total number of records matching the query"},"limit":{"type":"integer","description":"Maximum number of records returned per page"},"offset":{"type":"integer","description":"Number of records skipped from the start"}}}}}}
```

## The IdParam object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"IdParam":{"type":"object","required":["id"],"properties":{"id":{"type":"string","format":"uuid","description":"Resource ID"}}}}}}
```

## The OrganizationIdParam object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"OrganizationIdParam":{"type":"object","required":["organizationId"],"properties":{"organizationId":{"type":"string","format":"uuid","description":"Organization ID"}}}}}}
```

## The Token object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"Token":{"type":"object","required":["id","address","networkId","symbol","decimals"],"properties":{"id":{"type":"string","format":"uuid","description":"Token unique identifier"},"address":{"type":"string","description":"Token contract address"},"networkId":{"type":"string","description":"CAIP-2 network identifier"},"symbol":{"type":"string","description":"Token ticker symbol (e.g. \"USDC\", \"WETH\")"},"name":{"type":"string","nullable":true,"description":"Full token name"},"decimals":{"type":"integer","minimum":0,"maximum":255,"description":"Number of decimal places for the token"},"wraps":{"type":"string","nullable":true,"description":"Underlying asset this token represents (e.g. \"USD\" for USDC, \"ETH\" for WETH)"},"iconUrl":{"type":"string","nullable":true,"description":"URL of the token icon image"},"coingeckoId":{"type":"string","nullable":true,"description":"CoinGecko API identifier for price lookups"}}}}}}
```

## The Network object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"Network":{"type":"object","required":["networkId","displayName"],"properties":{"networkId":{"type":"string","description":"CAIP-2 network identifier"},"displayName":{"type":"string","description":"Human-readable network name (e.g. \"Ethereum Mainnet\")"},"explorerUrl":{"type":"string","nullable":true,"description":"Block explorer base URL"},"rpcUrl":{"type":"string","nullable":true,"description":"RPC endpoint URL"},"iconUrl":{"type":"string","nullable":true,"description":"URL of the network icon image"},"nativeCurrencySymbol":{"type":"string","nullable":true,"description":"Native currency ticker (e.g. \"ETH\")"},"nativeCurrencyDecimals":{"type":"integer","nullable":true,"description":"Native currency decimal places"}}}}}}
```

## The Vault object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"Vault":{"type":"object","required":["id","address","networkId","protocolVersion","label","organizationId","deployedAt"],"properties":{"id":{"type":"string","format":"uuid","description":"Vault unique identifier"},"address":{"type":"string","description":"Vault contract address"},"networkId":{"type":"string","description":"CAIP-2 network identifier"},"protocolVersion":{"type":"string","nullable":true,"description":"Credit Coop protocol/contract generation (e.g. \"v1\", \"v2\"). Null when not classified."},"label":{"type":"string","nullable":true,"description":"Display label for the vault. Always present; null if not configured."},"organizationId":{"type":"string","format":"uuid","nullable":true,"description":"Vault curator organization ID"},"deployedAt":{"type":"string","format":"date-time","nullable":true,"description":"Timestamp when the vault contract was deployed"},"organization":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/Organization"}],"description":"Organization details with links. Only included when expand includes \"organization\"."},"relatedAddresses":{"type":"object","nullable":true,"description":"On-chain related addresses. Only included when expand includes \"related-addresses\".","properties":{"creditStrategy":{"type":"string","nullable":true,"description":"CreditStrategy contract address. Manages credit allocation from vault funds to credit facilities."},"liquidStrategy":{"type":"string","nullable":true,"description":"LiquidStrategy contract address. Manages liquid asset reserves in the vault."},"vaultCurator":{"type":"string","nullable":true,"description":"Vault curator (manager) address of the CreditStrategy contract. Retrieved by calling manager() on the creditStrategy."},"whitelister":{"type":"string","nullable":true,"description":"Access-control authority that gates the vault deposit whitelist. Set per vault. Null for v2 vaults."}}},"assets":{"type":"object","nullable":true,"description":"Asset information. Only included when expand includes \"assets\".","properties":{"assetToken":{"type":"string","nullable":true,"description":"Asset token address"},"shareToken":{"type":"string","nullable":true,"description":"Share token address"},"decimals":{"type":"integer","nullable":true,"description":"Asset token decimals"},"totalAssets":{"type":"string","nullable":true,"description":"Total assets in the vault (raw uint256 — divide by 10^decimals to get human-readable value)"},"totalLiquidAssets":{"type":"string","nullable":true,"description":"Total liquid assets. Vault's balance - total pending deposits - claimable redeem assets + liquid strategy total assets + uninvested credit strategy assets (raw uint256 — divide by 10^decimals to get human-readable value)"},"totalSupply":{"type":"string","nullable":true,"description":"Total supply of vault shares (raw uint256 — divide by 10^decimals to get human-readable value)"},"sharePrice":{"type":"string","nullable":true,"description":"Share price of the vault (raw uint256 — divide by 10^decimals to get human-readable value)"},"baseUnit":{"type":"string","nullable":true,"description":"Minimum accounting unit used by the CreditStrategy for scaling interest calculations (raw uint256). Equal to 10^decimals."},"totalActiveCredit":{"type":"string","nullable":true,"description":"Total active credit from CreditStrategy. Deposits plus accrued and repaid interest for all credit lines (raw uint256 — divide by 10^decimals to get human-readable value)"},"uninvestedCreditAssets":{"type":"string","nullable":true,"description":"Uninvested credit assets. Asset token balance held by CreditStrategy (raw uint256 — divide by 10^decimals to get human-readable value)"}}},"apy":{"type":"object","nullable":true,"description":"APY data from historical sharePrice snapshots. Only included when expand includes \"apy\".","properties":{"apyPct30D":{"type":"number","nullable":true,"description":"30-day APY in percent (e.g. 5.0 = 5%). Null if insufficient snapshot data."}}},"fees":{"type":"object","nullable":true,"description":"Credit strategy fees in basis points. Only included when expand includes \"fees\".","properties":{"managementFee":{"type":"integer","description":"Management fee in basis points (e.g. 200 = 2%)"},"performanceFee":{"type":"integer","description":"Performance fee in basis points (e.g. 1000 = 10%)"}}}}},"Organization":{"type":"object","required":["id","name","slug"],"properties":{"id":{"type":"string","format":"uuid","description":"Organization unique identifier"},"name":{"type":"string","maxLength":255,"description":"Organization display name"},"slug":{"type":"string","maxLength":100,"description":"URL-friendly identifier"},"header":{"type":"string","nullable":true,"description":"Short tagline or headline for the organization profile"},"description":{"type":"string","nullable":true,"description":"Brief summary of the organization"},"overview":{"type":"string","nullable":true,"description":"Long-form organization description (may contain Markdown)"},"links":{"type":"array","description":"Organization links and image assets. Labels starting with \"#\" are image assets (e.g. \"#logo\", \"#header\"); all others are external links (e.g. \"Twitter\", \"Website\").","items":{"type":"object","required":["id","label","url"],"properties":{"id":{"type":"string","format":"uuid","description":"Link unique identifier"},"label":{"type":"string","description":"Link type. \"#logo\" and \"#header\" denote image assets; other values (e.g. \"Twitter\", \"Website\") denote external links."},"linkText":{"type":"string","nullable":true,"description":"Display text for external links (e.g. \"@raincards\", \"rain.xyz\")"},"iconUrl":{"type":"string","nullable":true,"description":"Icon image URL for external links"},"url":{"type":"string","description":"Target URL (image URL for asset links, destination URL for external links)"}}}}}}}}}
```

## The CreditFacility object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"CreditFacility":{"type":"object","required":["id","address","networkId","protocolVersion","label","organizationId"],"properties":{"id":{"type":"string","format":"uuid","description":"Credit facility unique identifier"},"address":{"type":"string","description":"SecuredLine contract address"},"networkId":{"type":"string","description":"CAIP-2 network identifier"},"protocolVersion":{"type":"string","nullable":true,"description":"Credit Coop protocol/contract generation (e.g. \"v1\", \"v2\"). Null when not classified."},"label":{"type":"string","nullable":true,"description":"Display label for the credit facility. Always present; null if not configured."},"organizationId":{"type":"string","format":"uuid","nullable":true,"description":"Borrower organization ID"},"organization":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/Organization"}],"description":"Organization details with links. Only included when expand includes \"organization\"."},"relatedAddresses":{"type":"object","nullable":true,"description":"On-chain related addresses. Only included when expand includes \"related-addresses\".","properties":{"spigot":{"type":"string","nullable":true,"description":"v1/v2 only. Spigot contract address. Captures and routes borrower revenue to debt repayment. Null for v3 facilities (no spigot layer)."},"borrower":{"type":"string","nullable":true,"description":"Address authorized to borrow, repay, and close credit lines. Present on all versions."},"admin":{"type":"string","nullable":true,"description":"v1/v2 only. Credit facility administrator address. Null for v3 facilities."},"spigotOperator":{"type":"string","nullable":true,"description":"v1/v2 only. Address authorized to execute revenue claims on the Spigot. Null for v3 facilities."},"escrow":{"type":"string","nullable":true,"description":"v2 only. Escrow contract address. Holds collateral posted by the borrower and enforces the minimum collateral ratio. Null for v1/v3 facilities (v3 collateral lives on the Servicing contract)."},"servicing":{"type":"string","nullable":true,"description":"v3 only. The facility's bound Servicing contract — the per-borrower hub for covenants, collateral, and cross-default. Null for v1/v2 facilities."},"servicingId":{"type":"string","format":"uuid","nullable":true,"description":"v3 only. Resource ID of the bound Servicing (use with GET /v3/servicings/:id). Null when the Servicing address is not registered, or for v1/v2 facilities."}}},"fees":{"type":"object","nullable":true,"description":"Fee configuration for the Credit Facility. Only included when expand includes \"fees\".","required":["originationFee","swapFee","servicingFee","drawFee","repayFee"],"properties":{"originationFee":{"type":"string","nullable":true,"description":"Origination fee (basis points). Present on v2 and v3."},"swapFee":{"type":"string","nullable":true,"description":"v2 only. Swap fee (basis points). Null for v3."},"servicingFee":{"type":"string","nullable":true,"description":"v2 only. Servicing fee (basis points). Null for v3."},"drawFee":{"type":"string","nullable":true,"description":"v3 only. Per-draw fee (basis points, FEE_DRAW). Null for v1/v2."},"repayFee":{"type":"string","nullable":true,"description":"v3 only. Per-repay fee (basis points, FEE_REPAY). Null for v1/v2."}}},"counts":{"type":"object","nullable":true,"description":"Active credit lines and open proposals counts. Only included when expand includes \"counts\".","required":["activeCreditLines","openProposals"],"properties":{"activeCreditLines":{"type":"integer","description":"Number of active credit lines"},"openProposals":{"type":"integer","description":"Number of open mutual consent proposals"}}},"status":{"type":"object","nullable":true,"description":"On-chain status for this facility. Only included when expand includes \"status\". An open facility may report LIQUIDATABLE when its borrower is in cross-default; once a facility is closed it reports REPAID and reflects only its own terminal outcome, never absorbing the borrower's wider default state. Borrower-wide default and covenant breach levels are reported per cross-default group on GET /v3/borrowers (expand=status).","required":["code","label","facilityClosed"],"properties":{"code":{"type":"integer","description":"Numeric status code (0: UNINITIALIZED, 1: ACTIVE, 2: LIQUIDATABLE, 3: REPAID, 4: INSOLVENT, 5: ABORTED)"},"label":{"type":"string","enum":["UNINITIALIZED","ACTIVE","LIQUIDATABLE","REPAID","INSOLVENT","ABORTED","UNKNOWN"],"description":"Human-readable status label. UNKNOWN is returned when the on-chain status code is outside the known range (e.g., a new status added by a future contract version)."},"facilityClosed":{"type":"boolean","description":"Whether this specific facility is closed (terminal). Always present whenever status is present (the entire status object is omitted when unavailable). For a closed facility code/label report REPAID; for an open facility they may additionally reflect borrower-wide cross-default (LIQUIDATABLE)."}}},"collateral":{"type":"object","nullable":true,"description":"On-chain collateral state from the Escrow contract. Only included when expand includes \"collateral\". Null when the facility has no escrow, RPC is unavailable, or the facility predates the Escrow architecture.","required":["maxLtvBps","totalOutstandingDebt","collateralValue","ltvBps","targetLtvBps","collateralTokens"],"properties":{"maxLtvBps":{"type":"string","nullable":true,"description":"Maximum loan-to-value ratio allowed for this facility, in basis points (10000 = 100%). Computed server-side as 10000² / minimumCollateralRatio (integer floor). Null when the facility does not enforce a collateral requirement."},"totalOutstandingDebt":{"type":"string","nullable":true,"description":"Total outstanding debt in USD as a formatted decimal string with trailing zeros trimmed (e.g. \"1234.56\"). The debt token's decimals are read from the first active credit position and applied server-side. \"0\" when there are no active positions. Null when the facility does not enforce a collateral requirement."},"collateralValue":{"type":"string","nullable":true,"description":"Collateral value in USD as a formatted decimal string with trailing zeros trimmed (e.g. \"2000\" or \"1999.99\"). Formatted server-side. Null when the facility does not enforce a collateral requirement."},"ltvBps":{"type":"string","nullable":true,"description":"Current loan-to-value ratio in basis points: (totalOutstandingDebt × 10000) / collateralValue, computed server-side from raw on-chain values (decimals normalized before division). \"0\" when there is no outstanding debt. \"999999999\" (sentinel) when debt is positive but on-chain collateral value is 0 — the facility is effectively infinitely undercollateralized. Null when the facility does not enforce a collateral requirement, or when debt decimals could not be resolved."},"targetLtvBps":{"type":"string","nullable":true,"description":"Target LTV in basis points. Defines the minimum collateral value required to back the facility's credit limit (min collateral ≈ creditLimit × 10000 / targetLtvBps). Null when no target is configured for this facility."},"collateralTokens":{"type":"array","description":"Every token ever enabled as collateral on the Escrow, with its current on-chain amount and USD value. May be empty if EnableCollateral events have not been ingested for this Escrow.","items":{"type":"object","required":["address","amount","decimals","usdValue"],"properties":{"address":{"type":"string","description":"Collateral token address (ERC-20)."},"amount":{"type":"string","nullable":true,"description":"Current on-chain collateral amount (raw uint256; divide by `decimals` to get human-readable value). Null if the on-chain `getCollateralData` read failed."},"decimals":{"type":"integer","nullable":true,"description":"Decimals of the collateral token itself (for rendering `amount`). Null if ERC-20 metadata could not be fetched."},"usdValue":{"type":"string","nullable":true,"description":"USD value of the current collateral amount as a human-readable decimal string (e.g. \"1234.56\"), up to 6 decimal places with trailing zeros trimmed. Null if amount, price, or decimals is unavailable."}}}}}}}},"Organization":{"type":"object","required":["id","name","slug"],"properties":{"id":{"type":"string","format":"uuid","description":"Organization unique identifier"},"name":{"type":"string","maxLength":255,"description":"Organization display name"},"slug":{"type":"string","maxLength":100,"description":"URL-friendly identifier"},"header":{"type":"string","nullable":true,"description":"Short tagline or headline for the organization profile"},"description":{"type":"string","nullable":true,"description":"Brief summary of the organization"},"overview":{"type":"string","nullable":true,"description":"Long-form organization description (may contain Markdown)"},"links":{"type":"array","description":"Organization links and image assets. Labels starting with \"#\" are image assets (e.g. \"#logo\", \"#header\"); all others are external links (e.g. \"Twitter\", \"Website\").","items":{"type":"object","required":["id","label","url"],"properties":{"id":{"type":"string","format":"uuid","description":"Link unique identifier"},"label":{"type":"string","description":"Link type. \"#logo\" and \"#header\" denote image assets; other values (e.g. \"Twitter\", \"Website\") denote external links."},"linkText":{"type":"string","nullable":true,"description":"Display text for external links (e.g. \"@raincards\", \"rain.xyz\")"},"iconUrl":{"type":"string","nullable":true,"description":"Icon image URL for external links"},"url":{"type":"string","description":"Target URL (image URL for asset links, destination URL for external links)"}}}}}}}}}
```

## The CreditLine object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"CreditLine":{"type":"object","required":["lineTokenId"],"properties":{"lineTokenId":{"type":"string","description":"Credit line token ID"},"deposit":{"type":"string","nullable":true,"description":"Deposit amount (raw uint256 — divide by 10^decimals to get human-readable value)"},"creditLimit":{"type":"string","nullable":true,"description":"Credit limit (raw uint256 — divide by 10^decimals to get human-readable value). For open lines: equals current deposit. For closed lines: deposit from the most recent AddCredit or IncreaseCredit event."},"principal":{"type":"string","nullable":true,"description":"Principal amount borrowed (raw uint256 — divide by 10^decimals to get human-readable value)"},"interestBalance":{"type":"string","nullable":true,"description":"Total interest held by the credit line: the sum of interestAccrued and interestRepaid (raw uint256 — divide by 10^decimals to get human-readable value). v3: equals interestAccrued (repaid proceeds are reported via the claimable field)."},"interestAccrued":{"type":"string","nullable":true,"description":"Interest accrued and owed by the borrower but not yet repaid (raw uint256 — divide by 10^decimals to get human-readable value). v3: equals interestBalance."},"interestRepaid":{"type":"string","nullable":true,"description":"Interest already repaid into the credit line and held for the lender to claim/withdraw (raw uint256 — divide by 10^decimals to get human-readable value). Null for v3 — repaid proceeds are reported in aggregate (principal + interest) via the claimable field."},"token":{"type":"string","nullable":true,"description":"Token address for this credit line"},"decimals":{"type":"integer","nullable":true,"description":"Token decimals"},"isOpen":{"type":"boolean","nullable":true,"description":"Whether the credit line is open"},"isRestricted":{"type":"boolean","nullable":true,"description":"Whether the credit line is restricted. Null for v3 (no equivalent)."},"earlyWithdrawalFee":{"type":"string","nullable":true,"description":"Early withdrawal fee in basis points. Null for v3 (no equivalent)."},"deadline":{"type":"string","format":"date-time","nullable":true,"description":"Credit line deadline"},"drawRate":{"type":"string","nullable":true,"description":"Draw rate in basis points (interest rate on borrowed principal)"},"facilityRate":{"type":"string","nullable":true,"description":"Facility rate in basis points (interest rate on unused deposit)"},"apyPct":{"type":"number","nullable":true,"description":"Computed APY as a percentage (e.g. 5.0 = 5.0%). Weighted average of drawRate on principal and facilityRate on unused deposit."},"createdTxHash":{"type":"string","nullable":true,"description":"Transaction hash of the AddCredit event that created this line"},"createdBlockNumber":{"type":"integer","nullable":true,"description":"Block number when this credit line was created"},"createdAt":{"type":"string","format":"date-time","nullable":true,"description":"Timestamp when this credit line was created. May be null for refinanced commitments."},"commitmentValue":{"type":"string","nullable":true,"description":"v3 only. Canonical par value of the commitment (drawn + interestOwed + claimable + undrawn residual), raw uint256. Null for v2. As of the last on-chain accrual checkpoint."},"claimable":{"type":"string","nullable":true,"description":"v3 only. Repaid/closed proceeds currently claimable by the commitment owner, raw uint256. Null for v2."},"facilityType":{"type":"string","nullable":true,"description":"v3 only. Facility type (\"RCF\" | \"TLA\" | \"DDTL\" | \"TIERED\"). Null for v2."},"isDefaulted":{"type":"boolean","nullable":true,"description":"v3 only. Cross-default (impairment) flag for the position's borrower. Null for v2."},"fees":{"type":"object","nullable":true,"description":"Only included when expand=fees is specified. Null if fetching failed.","required":["originationFees"],"properties":{"originationFees":{"type":"string","nullable":true,"description":"Origination fees for this credit line (raw uint256 — divide by 10^decimals to get human-readable value). Null if unavailable."}}},"error":{"type":"string","nullable":true,"description":"Error message if fetching this credit line failed. Other fields will be null."}}}}}}
```

## The Servicing object

```json
{"openapi":"3.0.3","info":{"title":"Credit Coop API","version":"3.0.0"},"components":{"schemas":{"Servicing":{"type":"object","required":["id","address","networkId","organizationId"],"properties":{"id":{"type":"string","format":"uuid","description":"Servicing unique identifier"},"address":{"type":"string","description":"Servicing contract address"},"networkId":{"type":"string","description":"CAIP-2 network identifier"},"organizationId":{"type":"string","format":"uuid","nullable":true,"description":"Borrower organization ID"},"status":{"type":"object","nullable":true,"description":"On-chain cross-default health of the servicing. Only included when expand includes \"status\".","required":["closed","isDefaulted","breachLevel"],"properties":{"closed":{"type":"boolean","nullable":true,"description":"Whether the servicing has been wound down (terminal). Null when unavailable."},"isDefaulted":{"type":"boolean","nullable":true,"description":"Whether the borrower is in cross-default — one covenant breach gates every facility under this servicing. Null when unavailable."},"breachLevel":{"type":"string","nullable":true,"enum":["NONE","CURING","DEFAULTED"],"description":"Worst covenant breach level across the servicing. Null when it cannot be determined."}}},"asset":{"type":"object","nullable":true,"description":"The accounting unit every raw amount on this servicing (collateral value, capacity) is denominated in. Only included when expand includes \"asset\".","required":["token","decimals"],"properties":{"token":{"type":"string","nullable":true,"description":"Address of the accounting asset. Null when the servicing has no facilities yet or it could not be resolved."},"decimals":{"type":"integer","nullable":true,"description":"Decimals of the accounting asset — divide any raw uint256 amount by 10^decimals to get a human-readable value. Null when unavailable."}}},"organization":{"nullable":true,"allOf":[{"$ref":"#/components/schemas/Organization"}],"description":"Organization details with links. Only included when expand includes \"organization\"."},"relatedAddresses":{"type":"object","nullable":true,"description":"Borrower and trustee addresses. Only included when expand includes \"related-addresses\".","required":["borrower","trustee"],"properties":{"borrower":{"type":"string","nullable":true,"description":"The borrower this servicing serves."},"trustee":{"type":"string","nullable":true,"description":"Recipient of seized collateral on liquidation."}}},"collateral":{"type":"array","nullable":true,"description":"The shared collateral pool, one entry per registered collateral. Only included when expand includes \"collateral\".","items":{"type":"object","required":["address","advanceRateBps","value","valueUsd","level"],"properties":{"address":{"type":"string","description":"Collateral contract address."},"advanceRateBps":{"type":"integer","nullable":true,"description":"Share of this collateral's value that counts toward the borrowing base, in basis points (10000 = 100%). Null if unavailable."},"value":{"type":"string","nullable":true,"description":"Raw mark-to-market value (uint256 in the accounting unit — divide by 10^decimals). Null if unavailable."},"valueUsd":{"type":"string","nullable":true,"description":"USD value as a human-readable decimal string. Null when the accounting asset is unpriced."},"level":{"type":"string","nullable":true,"enum":["NONE","CURING","DEFAULTED"],"description":"Breach level reported by this collateral. Null if unavailable."}}}},"facilities":{"type":"array","nullable":true,"description":"The facilities bound to this servicing. Only included when expand includes \"facilities\".","items":{"type":"object","required":["address","facilityId","organizationId"],"properties":{"address":{"type":"string","description":"Facility contract address."},"facilityId":{"type":"string","format":"uuid","nullable":true,"description":"Resource ID of the facility (use with GET /v3/credit-facilities/:id). Null when the facility address is not registered."},"organizationId":{"type":"string","format":"uuid","nullable":true,"description":"Organization ID of the facility, when registered."}}}},"capacity":{"type":"object","nullable":true,"description":"Shared borrowing-base aggregates across every facility. Only included when expand includes \"capacity\". All amounts are raw uint256 in the accounting unit — divide by 10^decimals.","required":["totalAdvancedValue","totalDrawn","totalCommitted","remainingDrawCapacity","remainingOriginationCapacity"],"properties":{"totalAdvancedValue":{"type":"string","nullable":true,"description":"The shared borrowing base. Null if unavailable."},"totalDrawn":{"type":"string","nullable":true,"description":"Total drawn across all facilities. Null if unavailable."},"totalCommitted":{"type":"string","nullable":true,"description":"Total committed across all facilities. Null if unavailable."},"remainingDrawCapacity":{"type":"string","nullable":true,"description":"Borrowing base remaining for new draws (floored at 0). Null when an input is unavailable."},"remainingOriginationCapacity":{"type":"string","nullable":true,"description":"Borrowing base remaining for new originations (floored at 0). Null when an input is unavailable."}}},"covenants":{"type":"array","nullable":true,"description":"Per-covenant breach levels behind the cross-default status. Only included when expand includes \"covenants\".","items":{"type":"object","required":["address","level"],"properties":{"address":{"type":"string","description":"Covenant contract address."},"level":{"type":"string","nullable":true,"enum":["NONE","CURING","DEFAULTED"],"description":"Breach level for this covenant. Null if unavailable."}}}}}},"Organization":{"type":"object","required":["id","name","slug"],"properties":{"id":{"type":"string","format":"uuid","description":"Organization unique identifier"},"name":{"type":"string","maxLength":255,"description":"Organization display name"},"slug":{"type":"string","maxLength":100,"description":"URL-friendly identifier"},"header":{"type":"string","nullable":true,"description":"Short tagline or headline for the organization profile"},"description":{"type":"string","nullable":true,"description":"Brief summary of the organization"},"overview":{"type":"string","nullable":true,"description":"Long-form organization description (may contain Markdown)"},"links":{"type":"array","description":"Organization links and image assets. Labels starting with \"#\" are image assets (e.g. \"#logo\", \"#header\"); all others are external links (e.g. \"Twitter\", \"Website\").","items":{"type":"object","required":["id","label","url"],"properties":{"id":{"type":"string","format":"uuid","description":"Link unique identifier"},"label":{"type":"string","description":"Link type. \"#logo\" and \"#header\" denote image assets; other values (e.g. \"Twitter\", \"Website\") denote external links."},"linkText":{"type":"string","nullable":true,"description":"Display text for external links (e.g. \"@raincards\", \"rain.xyz\")"},"iconUrl":{"type":"string","nullable":true,"description":"Icon image URL for external links"},"url":{"type":"string","description":"Target URL (image URL for asset links, destination URL for external links)"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.creditcoop.xyz/developer-api-docs/models.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
