Deployment
Get Deployment Options
Read the choices and limits that apply before deploying a market
GET
/
lending-external-securities-v2
/
api
/
markets
/
deployment-options
curl "https://api.trusset.org/lending-external-securities-v2/api/markets/deployment-options" \
-H "X-API-Key: trusset_your_key_here"
const res = await fetch(
'https://api.trusset.org/lending-external-securities-v2/api/markets/deployment-options',
{ headers: { 'X-API-Key': 'trusset_your_key_here' } }
);
const { data } = await res.json();
const ceiling = data.rateOffering.creatorRateCeilingBps;
{
"success": true,
"data": {
"factory": {
"address": "0xf1ad12f5698f58badd8a662acffccb067a2ddb8a",
"openToAnyCurator": true,
"creatorRateCeilingBps": 50000
},
"priceSources": {
"options": ["NAV", "MARKET", "ORACLE"],
"default": "NAV",
"marketRequiresIdentityRegistry": true,
"identityRegistryAlwaysOptional": false,
"oracleRequiresFeedAddress": true,
"oracleInitialPriceFromFeed": true
},
"identityGates": {
"borrowerGateRequiredFor": ["MARKET"],
"providerGateOpensPool": false,
"providerGateReadByVaults": true,
"poolClosedWithoutProviderGate": true,
"adjustableByAdmin": true,
"acceptedShapes": ["bool", "tuple"]
},
"rateOffering": {
"modes": ["CURVE", "CLAMPED", "FIXED"],
"default": "CURVE",
"creatorRateCeilingBps": 50000,
"fixedRequiresTerms": true,
"capSuspendsBorrows": false
},
"operatorShare": {
"fixed": true,
"bps": 800,
"afterInfrastructureFee": true,
"acceptedAtDeployment": false
},
"distributorShare": {
"fixed": true,
"bps": 500,
"afterInfrastructureFee": true,
"paidTo": "the distributors behind each vault depositor, the operator for liquidity no distributor brought"
},
"liquidity": {
"directDepositors": ["OPERATOR_WALLET", "REGISTERED_VAULTS"],
"thirdPartiesThroughVaults": true
},
"termOffering": {
"maxLoanDurationDaysRange": [1, 3650],
"termGracePeriodDaysRange": [1, 30],
"graceDefaultDays": 3,
"newLoansOnly": true
},
"identityRegistry": {
"mode": "TRUSSET",
"instanceRegister": "0x9e3c8a15f4d70b2681c5a3f9027d4be8115c7d21",
"unavailableReason": null
}
}
}
Returns what a deployment on this instance can choose and what the factory fixes, before any calldata is built. Read it before Deploy Market. It carries the factory’s live rate ceiling and the fixed fee shares. It also carries the ranges the term offering accepts and the identity register this instance resolves to.
Most of the answer is fixed by the contracts and the backend, and is returned so a deployment form does not hard-code it. Three values are read live from the factory:
creatorRateCeilingBps and the two share bps figures. A factory that cannot be read answers null in those fields rather than failing the request.
Response Fields
object
Show child attributes
Show child attributes
object
The lending factory this instance deploys to.
Show child attributes
Show child attributes
string
Factory address, lowercased.
null when no factory is configured for this network.boolean
Whether the factory accepts markets offered beyond their named candidates.
null when no factory is configured.integer
The highest floor, cap or fixed rate a deployment may carry, in basis points.
null when the factory could not be read.object
Show child attributes
Show child attributes
array
NAV, MARKET and ORACLE.string
NAV.boolean
true. A MARKET deployment must name a borrower register.boolean
false, for the same reason.boolean
true. An ORACLE deployment must name its feed in oracleAddress.boolean
true. An ORACLE market takes its first price from the feed, so it takes no initialPrice.object
How the market’s two registers behave. See Get Identity Gates.
Show child attributes
Show child attributes
array
Price sources that require a borrower register:
["MARKET"].boolean
false. A provider register admits nobody to deposit directly into the market.boolean
true. Every vault registered on the market examines its depositors against the provider register before it routes their money in.boolean
true.boolean
true. The market admin can change both registers after adoption.array
The answers to
isVerified(address) a register may give: bool or tuple.object
object
The share of repaid interest paid to the wallet that takes the lender-of-record role.
Show child attributes
Show child attributes
object
The share of repaid interest paid to distributors.
object
object
object
The identity register this instance resolves to. Nothing installs it on a market by default. A deployment or an adoption uses it only when it names it.
Show child attributes
Show child attributes
curl "https://api.trusset.org/lending-external-securities-v2/api/markets/deployment-options" \
-H "X-API-Key: trusset_your_key_here"
const res = await fetch(
'https://api.trusset.org/lending-external-securities-v2/api/markets/deployment-options',
{ headers: { 'X-API-Key': 'trusset_your_key_here' } }
);
const { data } = await res.json();
const ceiling = data.rateOffering.creatorRateCeilingBps;
{
"success": true,
"data": {
"factory": {
"address": "0xf1ad12f5698f58badd8a662acffccb067a2ddb8a",
"openToAnyCurator": true,
"creatorRateCeilingBps": 50000
},
"priceSources": {
"options": ["NAV", "MARKET", "ORACLE"],
"default": "NAV",
"marketRequiresIdentityRegistry": true,
"identityRegistryAlwaysOptional": false,
"oracleRequiresFeedAddress": true,
"oracleInitialPriceFromFeed": true
},
"identityGates": {
"borrowerGateRequiredFor": ["MARKET"],
"providerGateOpensPool": false,
"providerGateReadByVaults": true,
"poolClosedWithoutProviderGate": true,
"adjustableByAdmin": true,
"acceptedShapes": ["bool", "tuple"]
},
"rateOffering": {
"modes": ["CURVE", "CLAMPED", "FIXED"],
"default": "CURVE",
"creatorRateCeilingBps": 50000,
"fixedRequiresTerms": true,
"capSuspendsBorrows": false
},
"operatorShare": {
"fixed": true,
"bps": 800,
"afterInfrastructureFee": true,
"acceptedAtDeployment": false
},
"distributorShare": {
"fixed": true,
"bps": 500,
"afterInfrastructureFee": true,
"paidTo": "the distributors behind each vault depositor, the operator for liquidity no distributor brought"
},
"liquidity": {
"directDepositors": ["OPERATOR_WALLET", "REGISTERED_VAULTS"],
"thirdPartiesThroughVaults": true
},
"termOffering": {
"maxLoanDurationDaysRange": [1, 3650],
"termGracePeriodDaysRange": [1, 30],
"graceDefaultDays": 3,
"newLoansOnly": true
},
"identityRegistry": {
"mode": "TRUSSET",
"instanceRegister": "0x9e3c8a15f4d70b2681c5a3f9027d4be8115c7d21",
"unavailableReason": null
}
}
}
Error Codes
This endpoint has no refusals of its own beyond authentication, rate limiting and credits. Unreadable factory values come back asnull instead of an error.⌘I
curl "https://api.trusset.org/lending-external-securities-v2/api/markets/deployment-options" \
-H "X-API-Key: trusset_your_key_here"
const res = await fetch(
'https://api.trusset.org/lending-external-securities-v2/api/markets/deployment-options',
{ headers: { 'X-API-Key': 'trusset_your_key_here' } }
);
const { data } = await res.json();
const ceiling = data.rateOffering.creatorRateCeilingBps;
{
"success": true,
"data": {
"factory": {
"address": "0xf1ad12f5698f58badd8a662acffccb067a2ddb8a",
"openToAnyCurator": true,
"creatorRateCeilingBps": 50000
},
"priceSources": {
"options": ["NAV", "MARKET", "ORACLE"],
"default": "NAV",
"marketRequiresIdentityRegistry": true,
"identityRegistryAlwaysOptional": false,
"oracleRequiresFeedAddress": true,
"oracleInitialPriceFromFeed": true
},
"identityGates": {
"borrowerGateRequiredFor": ["MARKET"],
"providerGateOpensPool": false,
"providerGateReadByVaults": true,
"poolClosedWithoutProviderGate": true,
"adjustableByAdmin": true,
"acceptedShapes": ["bool", "tuple"]
},
"rateOffering": {
"modes": ["CURVE", "CLAMPED", "FIXED"],
"default": "CURVE",
"creatorRateCeilingBps": 50000,
"fixedRequiresTerms": true,
"capSuspendsBorrows": false
},
"operatorShare": {
"fixed": true,
"bps": 800,
"afterInfrastructureFee": true,
"acceptedAtDeployment": false
},
"distributorShare": {
"fixed": true,
"bps": 500,
"afterInfrastructureFee": true,
"paidTo": "the distributors behind each vault depositor, the operator for liquidity no distributor brought"
},
"liquidity": {
"directDepositors": ["OPERATOR_WALLET", "REGISTERED_VAULTS"],
"thirdPartiesThroughVaults": true
},
"termOffering": {
"maxLoanDurationDaysRange": [1, 3650],
"termGracePeriodDaysRange": [1, 30],
"graceDefaultDays": 3,
"newLoansOnly": true
},
"identityRegistry": {
"mode": "TRUSSET",
"instanceRegister": "0x9e3c8a15f4d70b2681c5a3f9027d4be8115c7d21",
"unavailableReason": null
}
}
}
