API ReferenceLOC lifecycleFunction
getLetterOfCredits()
function getLetterOfCredits(ctx, params?, options?): Promise<LetterOfCreditPage>;Reads canonical LOCs in ascending numeric id order, with an exact continuation cursor. Continuations preserve the initial deployment and block and must reuse the same filters and profile.
Parameters
| Parameter | Type | Description |
|---|---|---|
ctx | SDKContext | The configured SDK context. |
params | GetLetterOfCreditsParams | Collection filters and a page size from 1 to 1000. |
options | ReadExecutionOptions | Cancellation controls for the complete page. |
Returns
Promise<LetterOfCreditPage>
An all-or-nothing page at one indexed boundary.
Throws
SubgraphCompatibilityError If the endpoint or any returned entity cannot support the canonical model.
Throws
InvalidArgumentError If the filters, limit, or cursor are invalid or mismatched.
Throws
ConfigError If no subgraph endpoint is configured.
Example
const page = await getLetterOfCredits(sdk, { creators: [creator], limit: 50 });const next = page.nextCursor && await getLetterOfCredits(sdk, { creators: [creator], cursor: page.nextCursor, limit: 50,});