@bithomp/xrpl-api 2.7.15 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/common/errors/index.d.ts +2 -2
- package/lib/common/errors/index.js +3 -3
- package/lib/common/errors/validation_error.d.ts +2 -2
- package/lib/common/errors/validation_error.js +2 -2
- package/lib/common/errors/xrpl_api_error.d.ts +9 -0
- package/lib/common/errors/xrpl_api_error.js +28 -0
- package/lib/common/utils.d.ts +1 -0
- package/lib/common/utils.js +17 -1
- package/lib/ledger/account_info.js +7 -0
- package/lib/ledger/account_offers.d.ts +1 -1
- package/lib/ledger/ledger.d.ts +1 -1
- package/lib/ledger/transaction.d.ts +3 -3
- package/lib/ledger/transaction.js +4 -4
- package/lib/models/account_info.d.ts +1 -1
- package/lib/models/account_nfts.js +2 -1
- package/lib/models/account_object.d.ts +1 -1
- package/lib/models/account_offers.d.ts +9 -0
- package/lib/models/account_offers.js +2 -0
- package/lib/models/account_uritokens.d.ts +1 -1
- package/lib/models/path_find.d.ts +11 -0
- package/lib/models/path_find.js +2 -0
- package/lib/models/transaction.d.ts +1 -1
- package/lib/models/vl.js +1 -1
- package/lib/parse/index.d.ts +1 -0
- package/lib/parse/index.js +2 -1
- package/lib/parse/ledger/account-order.d.ts +1 -1
- package/lib/parse/ledger/account-order.js +1 -1
- package/lib/parse/ledger/account-trustline.d.ts +1 -1
- package/lib/parse/ledger/amount.d.ts +1 -1
- package/lib/parse/ledger/currency-amount.d.ts +1 -1
- package/lib/parse/ledger/emit_details.d.ts +1 -1
- package/lib/parse/ledger/import.d.ts +1 -1
- package/lib/parse/ledger/index.d.ts +1 -1
- package/lib/parse/ledger/index.js +2 -2
- package/lib/parse/ledger/ledger.d.ts +1 -1
- package/lib/parse/ledger/memos.d.ts +3 -2
- package/lib/parse/ledger/memos.js +12 -1
- package/lib/parse/ledger/nftoken-flags.d.ts +1 -1
- package/lib/parse/ledger/nftoken-flags.js +1 -1
- package/lib/parse/ledger/nftoken-offer-flags.d.ts +1 -1
- package/lib/parse/ledger/nftoken-offer-flags.js +1 -1
- package/lib/parse/ledger/orderbook-order.d.ts +7 -2
- package/lib/parse/ledger/orderbook-order.js +1 -1
- package/lib/parse/ledger/pathfind.d.ts +3 -3
- package/lib/parse/ledger/ripple-amount.d.ts +1 -1
- package/lib/parse/ledger/uritoken-flags.d.ts +1 -1
- package/lib/parse/ledger/uritoken-flags.js +1 -1
- package/lib/parse/outcome/balance_changes.js +1 -1
- package/lib/parse/outcome/channel_changes.js +1 -1
- package/lib/parse/outcome/escrow_changes.d.ts +1 -1
- package/lib/parse/outcome/escrow_changes.js +3 -4
- package/lib/parse/outcome/locked_balance_changes.js +1 -1
- package/lib/parse/outcome/orderbook_changes.js +1 -1
- package/lib/parse/outcome/unl_report_changes.js +1 -1
- package/lib/parse/outcome.d.ts +1 -1
- package/lib/parse/specification/account-delete.d.ts +1 -1
- package/lib/parse/specification/account-delete.js +13 -7
- package/lib/parse/specification/amendment.d.ts +1 -1
- package/lib/parse/specification/amendment.js +2 -5
- package/lib/parse/specification/check-cancel.d.ts +1 -1
- package/lib/parse/specification/check-cancel.js +2 -5
- package/lib/parse/specification/check-cash.d.ts +1 -1
- package/lib/parse/specification/check-cash.js +2 -2
- package/lib/parse/specification/check-create.d.ts +1 -1
- package/lib/parse/specification/check-create.js +13 -4
- package/lib/parse/specification/deposit-preauth.d.ts +1 -1
- package/lib/parse/specification/deposit-preauth.js +2 -5
- package/lib/parse/specification/escrow-cancel.d.ts +1 -1
- package/lib/parse/specification/escrow-cancel.js +2 -5
- package/lib/parse/specification/escrow-create.d.ts +1 -1
- package/lib/parse/specification/escrow-create.js +2 -5
- package/lib/parse/specification/escrow-finish.d.ts +1 -1
- package/lib/parse/specification/escrow-finish.js +2 -5
- package/lib/parse/specification/fee-update.d.ts +1 -1
- package/lib/parse/specification/fee-update.js +2 -2
- package/lib/parse/specification/import.d.ts +1 -1
- package/lib/parse/specification/import.js +2 -5
- package/lib/parse/specification/invoke.d.ts +1 -1
- package/lib/parse/specification/invoke.js +2 -5
- package/lib/parse/specification/nftoken-accept-offer.d.ts +1 -1
- package/lib/parse/specification/nftoken-accept-offer.js +2 -5
- package/lib/parse/specification/nftoken-burn.d.ts +1 -1
- package/lib/parse/specification/nftoken-burn.js +2 -5
- package/lib/parse/specification/nftoken-cancel-offer.d.ts +1 -1
- package/lib/parse/specification/nftoken-cancel-offer.js +2 -5
- package/lib/parse/specification/nftoken-create-offer.d.ts +1 -1
- package/lib/parse/specification/nftoken-create-offer.js +12 -3
- package/lib/parse/specification/nftoken-mint.d.ts +1 -1
- package/lib/parse/specification/nftoken-mint.js +2 -2
- package/lib/parse/specification/offer-cancel.d.ts +1 -1
- package/lib/parse/specification/offer-cancel.js +2 -5
- package/lib/parse/specification/offer-create.d.ts +1 -1
- package/lib/parse/specification/offer-create.js +2 -2
- package/lib/parse/specification/payment-channel-claim.d.ts +1 -1
- package/lib/parse/specification/payment-channel-claim.js +2 -2
- package/lib/parse/specification/payment-channel-create.d.ts +1 -1
- package/lib/parse/specification/payment-channel-create.js +13 -5
- package/lib/parse/specification/payment-channel-fund.d.ts +1 -1
- package/lib/parse/specification/payment-channel-fund.js +2 -2
- package/lib/parse/specification/payment.d.ts +1 -1
- package/lib/parse/specification/payment.js +3 -7
- package/lib/parse/specification/remit.d.ts +1 -1
- package/lib/parse/specification/remit.js +2 -2
- package/lib/parse/specification/settings.js +2 -2
- package/lib/parse/specification/ticket-create.d.ts +1 -1
- package/lib/parse/specification/ticket-create.js +2 -5
- package/lib/parse/specification/trustline.d.ts +1 -1
- package/lib/parse/specification/trustline.js +2 -5
- package/lib/parse/specification/unl-report.d.ts +1 -1
- package/lib/parse/specification/unl-report.js +2 -5
- package/lib/parse/specification/uritoken-burn.d.ts +1 -1
- package/lib/parse/specification/uritoken-burn.js +2 -5
- package/lib/parse/specification/uritoken-buy.d.ts +1 -1
- package/lib/parse/specification/uritoken-buy.js +2 -5
- package/lib/parse/specification/uritoken-cancel-sell-offer.d.ts +1 -1
- package/lib/parse/specification/uritoken-cancel-sell-offer.js +2 -5
- package/lib/parse/specification/uritoken-create-sell-offer.d.ts +2 -2
- package/lib/parse/specification/uritoken-create-sell-offer.js +12 -6
- package/lib/parse/specification/uritoken-mint.d.ts +3 -3
- package/lib/parse/specification/uritoken-mint.js +14 -5
- package/lib/parse/transaction.d.ts +19 -19
- package/lib/parse/utils.d.ts +10 -1
- package/lib/parse/utils.js +49 -1
- package/lib/types/account.d.ts +15 -0
- package/lib/types/account.js +2 -0
- package/lib/types/adjustments.d.ts +16 -0
- package/lib/types/adjustments.js +2 -0
- package/lib/types/amendments.d.ts +4 -0
- package/lib/types/amendments.js +2 -0
- package/lib/types/checks.d.ts +18 -0
- package/lib/types/checks.js +2 -0
- package/lib/types/deposits.d.ts +5 -0
- package/lib/types/deposits.js +2 -0
- package/lib/types/emit_details.d.ts +7 -0
- package/lib/types/emit_details.js +2 -0
- package/lib/types/escrows.d.ts +23 -0
- package/lib/types/escrows.js +2 -0
- package/lib/types/fees.d.ts +7 -0
- package/lib/types/fees.js +2 -0
- package/lib/types/flags.d.ts +5 -0
- package/lib/types/flags.js +8 -0
- package/lib/types/hooks.d.ts +14 -0
- package/lib/types/hooks.js +2 -0
- package/lib/types/import.d.ts +23 -0
- package/lib/types/import.js +2 -0
- package/lib/types/index.d.ts +24 -1
- package/lib/types/index.js +38 -0
- package/lib/types/invoke.d.ts +6 -0
- package/lib/types/invoke.js +2 -0
- package/lib/types/ledger.d.ts +45 -0
- package/lib/types/ledger.js +2 -0
- package/lib/types/ledger_data.d.ts +10 -0
- package/lib/types/ledger_data.js +2 -0
- package/lib/types/ledger_entries.d.ts +158 -0
- package/lib/types/ledger_entries.js +2 -0
- package/lib/types/memos.d.ts +12 -0
- package/lib/types/memos.js +2 -0
- package/lib/types/nftokens.d.ts +50 -0
- package/lib/types/nftokens.js +13 -0
- package/lib/types/offers.d.ts +15 -0
- package/lib/types/offers.js +2 -0
- package/lib/types/outcome.d.ts +33 -0
- package/lib/types/outcome.js +2 -0
- package/lib/types/path_find.d.ts +28 -0
- package/lib/types/path_find.js +2 -0
- package/lib/types/payment_channels.d.ts +25 -0
- package/lib/types/payment_channels.js +2 -0
- package/lib/types/payments.d.ts +11 -0
- package/lib/types/payments.js +2 -0
- package/lib/types/queue_data.d.ts +15 -0
- package/lib/types/queue_data.js +2 -0
- package/lib/types/remits.d.ts +18 -0
- package/lib/types/remits.js +2 -0
- package/lib/types/settings.d.ts +34 -0
- package/lib/types/settings.js +2 -0
- package/lib/types/signers.d.ts +6 -0
- package/lib/types/signers.js +2 -0
- package/lib/types/specification.d.ts +4 -0
- package/lib/types/specification.js +2 -0
- package/lib/types/tickets.d.ts +4 -0
- package/lib/types/tickets.js +2 -0
- package/lib/types/transactions.d.ts +21 -0
- package/lib/types/transactions.js +2 -0
- package/lib/types/trustlines.d.ts +38 -0
- package/lib/types/trustlines.js +2 -0
- package/lib/types/unl_reports.d.ts +7 -0
- package/lib/types/unl_reports.js +2 -0
- package/lib/types/uri_tokens.d.ts +7 -0
- package/lib/types/uri_tokens.js +6 -0
- package/lib/types/uritokens.d.ts +39 -0
- package/lib/types/uritokens.js +6 -0
- package/lib/v1/common/types/objects/account.d.ts +2 -2
- package/lib/v1/common/types/objects/checks.d.ts +3 -2
- package/lib/v1/common/types/objects/nftokens.d.ts +3 -1
- package/lib/v1/common/types/objects/payment_channels.d.ts +3 -3
- package/lib/v1/common/types/objects/uritokens.d.ts +5 -2
- package/lib/v1/common/types/objects/uritokens.js +1 -1
- package/lib/v1/transaction/payment.d.ts +2 -2
- package/lib/v1/transaction/payment.js +9 -9
- package/lib/v1/transaction/types.d.ts +1 -34
- package/lib/v1/transaction/utils.d.ts +2 -3
- package/lib/v1/transaction/utils.js +19 -15
- package/lib/v1/types.d.ts +9 -0
- package/lib/v1/types.js +2 -0
- package/lib/v1/utils.d.ts +7 -0
- package/lib/v1/utils.js +42 -0
- package/lib/validator.js +5 -4
- package/lib/wallet.d.ts +3 -0
- package/lib/wallet.js +26 -1
- package/package.json +20 -20
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export interface HookExecutionObjectInterface {
|
|
2
|
+
HookExecution: HookExecutionInterface;
|
|
3
|
+
}
|
|
4
|
+
export interface HookExecutionInterface {
|
|
5
|
+
HookAccount: string;
|
|
6
|
+
HookEmitCount: number;
|
|
7
|
+
HookExecutionIndex: number;
|
|
8
|
+
HookHash: string;
|
|
9
|
+
HookInstructionCount: string;
|
|
10
|
+
HookResult: number;
|
|
11
|
+
HookReturnCode: string;
|
|
12
|
+
HookReturnString: string;
|
|
13
|
+
HookStateChangeCount: number;
|
|
14
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { FormattedBaseSpecification } from "./specification";
|
|
2
|
+
import { FormattedSourceAddress } from "./account";
|
|
3
|
+
import { FormattedSpecification } from "../parse/transaction";
|
|
4
|
+
import { Outcome } from "./outcome";
|
|
5
|
+
export type FormattedImportBlobSpecification = {
|
|
6
|
+
ledger: number;
|
|
7
|
+
validation: {
|
|
8
|
+
data: any;
|
|
9
|
+
unl: any;
|
|
10
|
+
};
|
|
11
|
+
transaction: {
|
|
12
|
+
id: string;
|
|
13
|
+
tx: any;
|
|
14
|
+
meta: any;
|
|
15
|
+
proof: any;
|
|
16
|
+
specification: FormattedSpecification;
|
|
17
|
+
outcome?: Outcome;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
export type FormattedImportSpecification = {
|
|
21
|
+
source: FormattedSourceAddress;
|
|
22
|
+
blob: FormattedImportBlobSpecification | string;
|
|
23
|
+
} & FormattedBaseSpecification;
|
package/lib/types/index.d.ts
CHANGED
|
@@ -1 +1,24 @@
|
|
|
1
|
-
export
|
|
1
|
+
export * from "./adjustments";
|
|
2
|
+
export * from "./amounts";
|
|
3
|
+
export * from "./ledger";
|
|
4
|
+
export * from "./ledger_data";
|
|
5
|
+
export * from "./ledger_entries";
|
|
6
|
+
export * from "./memos";
|
|
7
|
+
export * from "./checks";
|
|
8
|
+
export * from "./deposits";
|
|
9
|
+
export * from "./escrows";
|
|
10
|
+
export * from "./offers";
|
|
11
|
+
export * from "./queue_data";
|
|
12
|
+
export * from "./settings";
|
|
13
|
+
export * from "./signers";
|
|
14
|
+
export * from "./transactions";
|
|
15
|
+
export * from "./trustlines";
|
|
16
|
+
export * from "./nftokens";
|
|
17
|
+
export * from "./uritokens";
|
|
18
|
+
export * from "./amendments";
|
|
19
|
+
export * from "./fees";
|
|
20
|
+
export * from "./import";
|
|
21
|
+
export * from "./invoke";
|
|
22
|
+
export * from "./unl_reports";
|
|
23
|
+
export * from "./remits";
|
|
24
|
+
export * from "./hooks";
|
package/lib/types/index.js
CHANGED
|
@@ -1,2 +1,40 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
2
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./adjustments"), exports);
|
|
18
|
+
__exportStar(require("./amounts"), exports);
|
|
19
|
+
__exportStar(require("./ledger"), exports);
|
|
20
|
+
__exportStar(require("./ledger_data"), exports);
|
|
21
|
+
__exportStar(require("./ledger_entries"), exports);
|
|
22
|
+
__exportStar(require("./memos"), exports);
|
|
23
|
+
__exportStar(require("./checks"), exports);
|
|
24
|
+
__exportStar(require("./deposits"), exports);
|
|
25
|
+
__exportStar(require("./escrows"), exports);
|
|
26
|
+
__exportStar(require("./offers"), exports);
|
|
27
|
+
__exportStar(require("./queue_data"), exports);
|
|
28
|
+
__exportStar(require("./settings"), exports);
|
|
29
|
+
__exportStar(require("./signers"), exports);
|
|
30
|
+
__exportStar(require("./transactions"), exports);
|
|
31
|
+
__exportStar(require("./trustlines"), exports);
|
|
32
|
+
__exportStar(require("./nftokens"), exports);
|
|
33
|
+
__exportStar(require("./uritokens"), exports);
|
|
34
|
+
__exportStar(require("./amendments"), exports);
|
|
35
|
+
__exportStar(require("./fees"), exports);
|
|
36
|
+
__exportStar(require("./import"), exports);
|
|
37
|
+
__exportStar(require("./invoke"), exports);
|
|
38
|
+
__exportStar(require("./unl_reports"), exports);
|
|
39
|
+
__exportStar(require("./remits"), exports);
|
|
40
|
+
__exportStar(require("./hooks"), exports);
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { FormattedBaseSpecification } from "./specification";
|
|
2
|
+
import { FormattedSourceAddress, FormattedDestinationAddress } from "./account";
|
|
3
|
+
export type FormattedInvokeSpecification = {
|
|
4
|
+
source: FormattedSourceAddress;
|
|
5
|
+
destination: FormattedDestinationAddress;
|
|
6
|
+
} & FormattedBaseSpecification;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
export interface Ledger {
|
|
2
|
+
account_hash: string;
|
|
3
|
+
close_time: number;
|
|
4
|
+
close_time_human: string;
|
|
5
|
+
close_time_resolution: number;
|
|
6
|
+
closed: boolean;
|
|
7
|
+
ledger_hash: string;
|
|
8
|
+
ledger_index: string;
|
|
9
|
+
parent_hash: string;
|
|
10
|
+
total_coins: string;
|
|
11
|
+
transaction_hash: string;
|
|
12
|
+
transactions: string[] | object[];
|
|
13
|
+
close_flags?: number;
|
|
14
|
+
parent_close_time?: number;
|
|
15
|
+
accountState?: any[];
|
|
16
|
+
validated?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export type FormattedLedger = {
|
|
19
|
+
stateHash: string;
|
|
20
|
+
closeTime: string;
|
|
21
|
+
closeTimeResolution: number;
|
|
22
|
+
closeFlags: number;
|
|
23
|
+
ledgerHash: string;
|
|
24
|
+
ledgerVersion: number;
|
|
25
|
+
parentLedgerHash: string;
|
|
26
|
+
parentCloseTime: string;
|
|
27
|
+
totalDrops: string;
|
|
28
|
+
transactionHash: string;
|
|
29
|
+
transactions?: object[];
|
|
30
|
+
transactionHashes?: string[];
|
|
31
|
+
rawState?: string;
|
|
32
|
+
stateHashes?: string[];
|
|
33
|
+
};
|
|
34
|
+
export type LedgerClosedEvent = {
|
|
35
|
+
type: "ledgerClosed";
|
|
36
|
+
fee_base: number;
|
|
37
|
+
fee_ref: number;
|
|
38
|
+
ledger_hash: string;
|
|
39
|
+
ledger_index: number;
|
|
40
|
+
ledger_time: number;
|
|
41
|
+
reserve_base: number;
|
|
42
|
+
reserve_inc: number;
|
|
43
|
+
txn_count: number;
|
|
44
|
+
validated_ledgers: string;
|
|
45
|
+
};
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
import { SignerEntry } from "./signers";
|
|
2
|
+
import { Amount } from "./amounts";
|
|
3
|
+
export interface AccountRootLedgerEntry {
|
|
4
|
+
LedgerEntryType: "AccountRoot";
|
|
5
|
+
Account: string;
|
|
6
|
+
Balance: string;
|
|
7
|
+
Flags: number;
|
|
8
|
+
OwnerCount: number;
|
|
9
|
+
PreviousTxnID: string;
|
|
10
|
+
PreviousTxnLgrSeq: number;
|
|
11
|
+
Sequence: number;
|
|
12
|
+
AccountTxnID?: string;
|
|
13
|
+
Domain?: string;
|
|
14
|
+
EmailHash?: string;
|
|
15
|
+
MessageKey?: string;
|
|
16
|
+
RegularKey?: string;
|
|
17
|
+
TickSize?: number;
|
|
18
|
+
TransferRate?: number;
|
|
19
|
+
WalletLocator?: string;
|
|
20
|
+
WalletSize?: number;
|
|
21
|
+
}
|
|
22
|
+
export interface AmendmentsLedgerEntry {
|
|
23
|
+
LedgerEntryType: "Amendments";
|
|
24
|
+
Amendments?: string[];
|
|
25
|
+
Majorities?: any[];
|
|
26
|
+
Flags: 0;
|
|
27
|
+
}
|
|
28
|
+
export interface CheckLedgerEntry {
|
|
29
|
+
LedgerEntryType: "Check";
|
|
30
|
+
Account: string;
|
|
31
|
+
Destination: any;
|
|
32
|
+
string: any;
|
|
33
|
+
Flags: 0;
|
|
34
|
+
OwnerNode: string;
|
|
35
|
+
PreviousTxnID: string;
|
|
36
|
+
PreviousTxnLgrSeq: number;
|
|
37
|
+
SendMax: string | object;
|
|
38
|
+
Sequence: number;
|
|
39
|
+
DestinationNode: string;
|
|
40
|
+
DestinationTag: number;
|
|
41
|
+
Expiration: number;
|
|
42
|
+
InvoiceID: string;
|
|
43
|
+
SourceTag: number;
|
|
44
|
+
}
|
|
45
|
+
export interface DepositPreauthLedgerEntry {
|
|
46
|
+
LedgerEntryType: "DepositPreauth";
|
|
47
|
+
Account: string;
|
|
48
|
+
Authorize: string;
|
|
49
|
+
OwnerNode: string;
|
|
50
|
+
PreviousTxnID: string;
|
|
51
|
+
PreviousTxnLgrSeq: number;
|
|
52
|
+
}
|
|
53
|
+
export interface DirectoryNodeLedgerEntry {
|
|
54
|
+
LedgerEntryType: "DirectoryNode";
|
|
55
|
+
Flags: number;
|
|
56
|
+
RootIndex: string;
|
|
57
|
+
Indexes: string[];
|
|
58
|
+
IndexNext?: number;
|
|
59
|
+
IndexPrevious?: number;
|
|
60
|
+
}
|
|
61
|
+
export interface OfferDirectoryNodeLedgerEntry extends DirectoryNodeLedgerEntry {
|
|
62
|
+
TakerPaysCurrency: string;
|
|
63
|
+
TakerPaysIssuer: string;
|
|
64
|
+
TakerGetsCurrency: string;
|
|
65
|
+
TakerGetsIssuer: string;
|
|
66
|
+
ExchangeRate?: number;
|
|
67
|
+
}
|
|
68
|
+
export interface OwnerDirectoryNodeLedgerEntry extends DirectoryNodeLedgerEntry {
|
|
69
|
+
Owner: string;
|
|
70
|
+
}
|
|
71
|
+
export interface EscrowLedgerEntry {
|
|
72
|
+
LedgerEntryType: "Escrow";
|
|
73
|
+
Account: string;
|
|
74
|
+
Destination: string;
|
|
75
|
+
Amount: string;
|
|
76
|
+
Condition?: string;
|
|
77
|
+
CancelAfter?: number;
|
|
78
|
+
FinishAfter?: number;
|
|
79
|
+
Flags: number;
|
|
80
|
+
SourceTag?: number;
|
|
81
|
+
DestinationTag?: number;
|
|
82
|
+
OwnerNode: string;
|
|
83
|
+
DestinationNode?: string;
|
|
84
|
+
PreviousTxnID: string;
|
|
85
|
+
PreviousTxnLgrSeq: number;
|
|
86
|
+
}
|
|
87
|
+
export interface FeeSettingsLedgerEntry {
|
|
88
|
+
LedgerEntryType: "FeeSettings";
|
|
89
|
+
BaseFee: string;
|
|
90
|
+
ReferenceFeeUnits: number;
|
|
91
|
+
ReserveBase: number;
|
|
92
|
+
ReserveIncrement: number;
|
|
93
|
+
Flags: number;
|
|
94
|
+
}
|
|
95
|
+
export interface LedgerHashesLedgerEntry {
|
|
96
|
+
LedgerEntryType: "LedgerHashes";
|
|
97
|
+
Hashes: string[];
|
|
98
|
+
Flags: number;
|
|
99
|
+
FirstLedgerSequence?: number;
|
|
100
|
+
LastLedgerSequence?: number;
|
|
101
|
+
}
|
|
102
|
+
export interface OfferLedgerEntry {
|
|
103
|
+
LedgerEntryType: "Offer";
|
|
104
|
+
Flags: number;
|
|
105
|
+
Account: string;
|
|
106
|
+
Sequence: number;
|
|
107
|
+
TakerPays: Amount;
|
|
108
|
+
TakerGets: Amount;
|
|
109
|
+
BookDirectory: string;
|
|
110
|
+
BookNode: string;
|
|
111
|
+
OwnerNode: string;
|
|
112
|
+
PreviousTxnID: string;
|
|
113
|
+
PreviousTxnLgrSeq: number;
|
|
114
|
+
Expiration?: number;
|
|
115
|
+
}
|
|
116
|
+
export interface PayChannelLedgerEntry {
|
|
117
|
+
LedgerEntryType: "PayChannel";
|
|
118
|
+
Sequence: number;
|
|
119
|
+
Account: string;
|
|
120
|
+
Amount: string;
|
|
121
|
+
Balance: string;
|
|
122
|
+
PublicKey: string;
|
|
123
|
+
Destination: string;
|
|
124
|
+
SettleDelay: number;
|
|
125
|
+
Expiration?: number;
|
|
126
|
+
CancelAfter?: number;
|
|
127
|
+
SourceTag?: number;
|
|
128
|
+
DestinationTag?: number;
|
|
129
|
+
OwnerNode: string;
|
|
130
|
+
PreviousTxnID: string;
|
|
131
|
+
PreviousTxnLgrSeq: number;
|
|
132
|
+
index: string;
|
|
133
|
+
}
|
|
134
|
+
export interface RippleStateLedgerEntry {
|
|
135
|
+
LedgerEntryType: "RippleState";
|
|
136
|
+
Flags: number;
|
|
137
|
+
Balance: Amount;
|
|
138
|
+
LowLimit: Amount;
|
|
139
|
+
HighLimit: Amount;
|
|
140
|
+
PreviousTxnID: string;
|
|
141
|
+
PreviousTxnLgrSeq: number;
|
|
142
|
+
LowNode?: string;
|
|
143
|
+
HighNode?: string;
|
|
144
|
+
LowQualityIn?: number;
|
|
145
|
+
LowQualityOut?: number;
|
|
146
|
+
HighQualityIn?: number;
|
|
147
|
+
HighQualityOut?: number;
|
|
148
|
+
}
|
|
149
|
+
export interface SignerListLedgerEntry {
|
|
150
|
+
LedgerEntryType: "SignerList";
|
|
151
|
+
OwnerNode: string;
|
|
152
|
+
SignerQuorum: number;
|
|
153
|
+
SignerEntries: SignerEntry[];
|
|
154
|
+
SignerListID: number;
|
|
155
|
+
PreviousTxnID: string;
|
|
156
|
+
PreviousTxnLgrSeq: number;
|
|
157
|
+
}
|
|
158
|
+
export type LedgerEntry = AccountRootLedgerEntry | AmendmentsLedgerEntry | CheckLedgerEntry | DepositPreauthLedgerEntry | DirectoryNodeLedgerEntry | OfferDirectoryNodeLedgerEntry | OwnerDirectoryNodeLedgerEntry | EscrowLedgerEntry | FeeSettingsLedgerEntry | LedgerHashesLedgerEntry | OfferLedgerEntry | PayChannelLedgerEntry | RippleStateLedgerEntry | SignerListLedgerEntry;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { NFTokenMintFlags, NFTokenCreateOfferFlags } from "xrpl";
|
|
2
|
+
import { FormattedBaseSpecification } from "./specification";
|
|
3
|
+
import { Amount } from "./amounts";
|
|
4
|
+
import { FormattedSourceAddress, FormattedDestinationAddress } from "./account";
|
|
5
|
+
export declare const NFTokenFlagsKeys: {
|
|
6
|
+
burnable: NFTokenMintFlags;
|
|
7
|
+
onlyXRP: NFTokenMintFlags;
|
|
8
|
+
trustLine: NFTokenMintFlags;
|
|
9
|
+
transferable: NFTokenMintFlags;
|
|
10
|
+
};
|
|
11
|
+
export interface NFTokenFlagsKeysInterface {
|
|
12
|
+
burnable?: boolean;
|
|
13
|
+
onlyXRP?: boolean;
|
|
14
|
+
trustLine?: boolean;
|
|
15
|
+
transferable?: boolean;
|
|
16
|
+
}
|
|
17
|
+
export declare const NFTokenOfferFlagsKeys: {
|
|
18
|
+
sellToken: NFTokenCreateOfferFlags;
|
|
19
|
+
};
|
|
20
|
+
export interface NFTokenOfferFlagsKeysInterface {
|
|
21
|
+
sellToken?: boolean;
|
|
22
|
+
}
|
|
23
|
+
export type FormattedNFTokenBurnSpecification = {
|
|
24
|
+
account: string;
|
|
25
|
+
nftokenID: string;
|
|
26
|
+
} & FormattedBaseSpecification;
|
|
27
|
+
export type FormattedNFTokenMintSpecification = {
|
|
28
|
+
nftokenTaxon: number;
|
|
29
|
+
issuer?: string;
|
|
30
|
+
transferFee?: number;
|
|
31
|
+
uri?: string;
|
|
32
|
+
flags?: NFTokenFlagsKeysInterface;
|
|
33
|
+
} & FormattedBaseSpecification;
|
|
34
|
+
export type FormattedNFTokenCancelOfferSpecification = {
|
|
35
|
+
nftokenOffers: string[];
|
|
36
|
+
} & FormattedBaseSpecification;
|
|
37
|
+
export type FormattedNFTokenCreateOfferSpecification = {
|
|
38
|
+
nftokenID: string;
|
|
39
|
+
amount: Amount;
|
|
40
|
+
owner?: string;
|
|
41
|
+
source?: FormattedSourceAddress;
|
|
42
|
+
destination?: FormattedDestinationAddress;
|
|
43
|
+
expiration?: number;
|
|
44
|
+
flags?: NFTokenOfferFlagsKeysInterface;
|
|
45
|
+
} & FormattedBaseSpecification;
|
|
46
|
+
export type FormattedNFTokenAcceptOfferSpecification = {
|
|
47
|
+
nftokenSellOffer?: string;
|
|
48
|
+
nftokenBuyOffer?: string;
|
|
49
|
+
nftokenBrokerFee?: string;
|
|
50
|
+
} & FormattedBaseSpecification;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.NFTokenOfferFlagsKeys = exports.NFTokenFlagsKeys = void 0;
|
|
4
|
+
const xrpl_1 = require("xrpl");
|
|
5
|
+
exports.NFTokenFlagsKeys = {
|
|
6
|
+
burnable: xrpl_1.NFTokenMintFlags.tfBurnable,
|
|
7
|
+
onlyXRP: xrpl_1.NFTokenMintFlags.tfOnlyXRP,
|
|
8
|
+
trustLine: xrpl_1.NFTokenMintFlags.tfTrustLine,
|
|
9
|
+
transferable: xrpl_1.NFTokenMintFlags.tfTransferable,
|
|
10
|
+
};
|
|
11
|
+
exports.NFTokenOfferFlagsKeys = {
|
|
12
|
+
sellToken: xrpl_1.NFTokenCreateOfferFlags.tfSellNFToken,
|
|
13
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { FormattedBaseSpecification } from "./specification";
|
|
2
|
+
import { FormattedIssuedCurrencyAmount } from "./amounts";
|
|
3
|
+
export type FormattedOfferCancelSpecification = {
|
|
4
|
+
orderSequence: number;
|
|
5
|
+
} & FormattedBaseSpecification;
|
|
6
|
+
export type FormattedOfferCreateSpecification = {
|
|
7
|
+
direction: string;
|
|
8
|
+
quantity: FormattedIssuedCurrencyAmount;
|
|
9
|
+
totalPrice: FormattedIssuedCurrencyAmount;
|
|
10
|
+
immediateOrCancel?: boolean;
|
|
11
|
+
fillOrKill?: boolean;
|
|
12
|
+
expirationTime?: string;
|
|
13
|
+
orderToReplace?: number;
|
|
14
|
+
passive?: boolean;
|
|
15
|
+
} & FormattedBaseSpecification;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export type Outcome = {
|
|
2
|
+
result?: string;
|
|
3
|
+
ledgerVersion?: number;
|
|
4
|
+
indexInLedger?: number;
|
|
5
|
+
fee?: string;
|
|
6
|
+
balanceChanges?: {
|
|
7
|
+
[key: string]: {
|
|
8
|
+
currency: string;
|
|
9
|
+
counterparty?: string;
|
|
10
|
+
value: string;
|
|
11
|
+
}[];
|
|
12
|
+
};
|
|
13
|
+
lockedBalanceChanges?: {
|
|
14
|
+
[key: string]: {
|
|
15
|
+
currency: string;
|
|
16
|
+
counterparty?: string;
|
|
17
|
+
value: string;
|
|
18
|
+
}[];
|
|
19
|
+
};
|
|
20
|
+
orderbookChanges?: object;
|
|
21
|
+
channelChanges?: object;
|
|
22
|
+
nftokenChanges?: object;
|
|
23
|
+
nftokenOfferChanges?: object;
|
|
24
|
+
uritokenChanges?: object;
|
|
25
|
+
uritokenSellOfferChanges?: object;
|
|
26
|
+
affectedObjects?: object;
|
|
27
|
+
deliveredAmount?: {
|
|
28
|
+
currency: string;
|
|
29
|
+
counterparty?: string;
|
|
30
|
+
value: string;
|
|
31
|
+
};
|
|
32
|
+
timestamp?: string;
|
|
33
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { FormattedIssuedCurrencyAmount } from "./amounts";
|
|
2
|
+
import { Adjustment, MaxAdjustment, MinAdjustment } from "./adjustments";
|
|
3
|
+
export type LaxLaxAmount = {
|
|
4
|
+
currency: string;
|
|
5
|
+
value?: string;
|
|
6
|
+
issuer?: string;
|
|
7
|
+
counterparty?: string;
|
|
8
|
+
};
|
|
9
|
+
export type Path = {
|
|
10
|
+
source: Adjustment | MaxAdjustment;
|
|
11
|
+
destination: Adjustment | MinAdjustment;
|
|
12
|
+
paths: string;
|
|
13
|
+
};
|
|
14
|
+
export type GetPaths = Path[];
|
|
15
|
+
export type PathFind = {
|
|
16
|
+
source: {
|
|
17
|
+
address: string;
|
|
18
|
+
amount?: FormattedIssuedCurrencyAmount;
|
|
19
|
+
currencies?: {
|
|
20
|
+
currency: string;
|
|
21
|
+
counterparty?: string;
|
|
22
|
+
}[];
|
|
23
|
+
};
|
|
24
|
+
destination: {
|
|
25
|
+
address: string;
|
|
26
|
+
amount: LaxLaxAmount;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { FormattedBaseSpecification } from "./specification";
|
|
2
|
+
import { FormattedAmount } from "./amounts";
|
|
3
|
+
import { FormattedSourceAddress, FormattedDestinationAddress } from "./account";
|
|
4
|
+
export type FormattedPaymentChannelClaimSpecification = {
|
|
5
|
+
channel: string;
|
|
6
|
+
balance?: FormattedAmount;
|
|
7
|
+
amount?: FormattedAmount;
|
|
8
|
+
signature: string;
|
|
9
|
+
publicKey: string;
|
|
10
|
+
renew?: boolean;
|
|
11
|
+
close?: boolean;
|
|
12
|
+
} & FormattedBaseSpecification;
|
|
13
|
+
export type FormattedPaymentChannelCreateSpecification = {
|
|
14
|
+
source?: FormattedSourceAddress;
|
|
15
|
+
destination?: FormattedDestinationAddress;
|
|
16
|
+
amount?: FormattedAmount;
|
|
17
|
+
settleDelay: number;
|
|
18
|
+
publicKey?: string;
|
|
19
|
+
cancelAfter?: string;
|
|
20
|
+
} & FormattedBaseSpecification;
|
|
21
|
+
export type FormattedPaymentChannelFundSpecification = {
|
|
22
|
+
channel: string;
|
|
23
|
+
amount?: FormattedAmount;
|
|
24
|
+
expiration?: string;
|
|
25
|
+
} & FormattedBaseSpecification;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FormattedBaseSpecification } from "./specification";
|
|
2
|
+
import { FormattedSourceAddress, FormattedDestinationAddress } from "./account";
|
|
3
|
+
export type FormattedPaymentSpecification = {
|
|
4
|
+
source: FormattedSourceAddress;
|
|
5
|
+
destination: FormattedDestinationAddress;
|
|
6
|
+
invoiceID?: string;
|
|
7
|
+
paths?: string;
|
|
8
|
+
allowPartialPayment?: boolean;
|
|
9
|
+
noDirectRipple?: boolean;
|
|
10
|
+
limitQuality?: boolean;
|
|
11
|
+
} & FormattedBaseSpecification;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface QueueTransaction {
|
|
2
|
+
auth_change: boolean;
|
|
3
|
+
fee: string;
|
|
4
|
+
fee_level: string;
|
|
5
|
+
max_spend_drops: string;
|
|
6
|
+
seq: number;
|
|
7
|
+
}
|
|
8
|
+
export interface QueueData {
|
|
9
|
+
txn_count: number;
|
|
10
|
+
auth_change_queued?: boolean;
|
|
11
|
+
lowest_sequence?: number;
|
|
12
|
+
highest_sequence?: number;
|
|
13
|
+
max_spend_drops_total?: string;
|
|
14
|
+
transactions?: QueueTransaction[];
|
|
15
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { FormattedBaseSpecification } from "./specification";
|
|
2
|
+
import { FormattedDestinationAddress, FormattedSourceAddress } from "./account";
|
|
3
|
+
import { Amount } from "./amounts";
|
|
4
|
+
import { URITokenFlagsKeysInterface } from "./uritokens";
|
|
5
|
+
export type FormattedRemitsSpecification = {
|
|
6
|
+
source: FormattedSourceAddress;
|
|
7
|
+
destination: FormattedDestinationAddress;
|
|
8
|
+
amounts?: Amount[];
|
|
9
|
+
uritokenIDs?: string[];
|
|
10
|
+
uritokenMint?: {
|
|
11
|
+
uri: string;
|
|
12
|
+
flags?: URITokenFlagsKeysInterface;
|
|
13
|
+
digest?: string;
|
|
14
|
+
};
|
|
15
|
+
blob?: string;
|
|
16
|
+
inform?: string;
|
|
17
|
+
invoiceID?: string;
|
|
18
|
+
} & FormattedBaseSpecification;
|