@integraledger/lcp/ack
The exports of @integraledger/lcp/ack.
Interfaces
AckBody
The 402 body.
Properties
AckPaymentOption
An ACK payment option as the seller wrote it.
Indexable
[
k:string]:Json
Properties
AckValues
What the seller's stack places: the Payment Request's id, and the legal context beside the request, with the
agreement URL after the link when one is given.
Properties
| Property | Type |
|---|---|
legalContext | object |
legalContext.legalContextAgreementUrl? | string |
legalContext.legalContextUrl | string |
legalContext.type | "sha256" |
legalContext.value | `0x${string}` |
paymentRequestId | string |
Variables
paymentRequest
constpaymentRequest:Readonly<{advertise: (_doc,h,link,offer,agreementUrl?) =>Refusal|AckValues;bound: (_presented) =>Promise<Refusal>;build: (_doc,_h) =>Promise<Refusal>;claims:boolean;id:"ack/payment-request";pattern:LcpPattern;read: (doc) =>Refusal| {agreement?:string;h:`0x${string}`;link:string;offer: {options: readonlyJson[]; }; };tie: (options) => ["ack", {paymentOptions: readonlyAckPaymentOption[]; }];unplaced: (option) =>AckPaymentOption; }>
Functions
fromReceipt()
fromReceipt(
credentialSubject):`0x${string}`|Refusal
The hash in a receipt: the id of the Payment Request token embedded in its credentialSubject. Verifies nothing;
a party calls it on a receipt it has verified.
Parameters
| Parameter | Type |
|---|---|
credentialSubject | unknown |
Returns
`0x${string}` | Refusal
tie()
tie(
options): ["ack", {paymentOptions: readonlyAckPaymentOption[]; }]
The binding slot: the Payment Request's options exactly as issued.
Parameters
| Parameter | Type |
|---|---|
options | readonly AckPaymentOption[] |
Returns
["ack", { paymentOptions: readonly AckPaymentOption[]; }]
Last updated on