1 | import { FormattedOrderSpecification, FormattedTrustlineSpecification, Adjustment, RippledAmount, Memo, FormattedSettings } from '../common/types/objects';
|
2 | import { ApiMemo } from './utils';
|
3 | export declare type TransactionJSON = {
|
4 | Account: string;
|
5 | TransactionType: string;
|
6 | Memos?: {
|
7 | Memo: ApiMemo;
|
8 | }[];
|
9 | Flags?: number;
|
10 | Fulfillment?: string;
|
11 | [Field: string]: string | number | Array<any> | RippledAmount | undefined;
|
12 | };
|
13 | export declare type Instructions = {
|
14 | sequence?: number;
|
15 | ticketSequence?: number;
|
16 | fee?: string;
|
17 | maxFee?: string;
|
18 | maxLedgerVersion?: number;
|
19 | maxLedgerVersionOffset?: number;
|
20 | signersCount?: number;
|
21 | };
|
22 | export declare type Prepare = {
|
23 | txJSON: string;
|
24 | instructions: {
|
25 | fee: string;
|
26 | sequence?: number;
|
27 | ticketSequence?: number;
|
28 | maxLedgerVersion?: number;
|
29 | };
|
30 | };
|
31 | export declare type Submit = {
|
32 | success: boolean;
|
33 | engineResult: string;
|
34 | engineResultCode: number;
|
35 | engineResultMessage?: string;
|
36 | txBlob?: string;
|
37 | txJson?: object;
|
38 | };
|
39 | export interface OfferCreateTransaction extends TransactionJSON {
|
40 | TransactionType: 'OfferCreate';
|
41 | Account: string;
|
42 | Fee: string;
|
43 | Flags: number;
|
44 | LastLedgerSequence: number;
|
45 | Sequence: number;
|
46 | TakerGets: RippledAmount;
|
47 | TakerPays: RippledAmount;
|
48 | Expiration?: number;
|
49 | OfferSequence?: number;
|
50 | Memos?: {
|
51 | Memo: ApiMemo;
|
52 | }[];
|
53 | }
|
54 | export interface SettingsTransaction extends TransactionJSON {
|
55 | TransferRate?: number;
|
56 | }
|
57 | export declare type KeyPair = {
|
58 | publicKey: string;
|
59 | privateKey: string;
|
60 | };
|
61 | export declare type SignOptions = {
|
62 | signAs: string;
|
63 | };
|
64 | export declare type Outcome = {
|
65 | result: string;
|
66 | ledgerVersion: number;
|
67 | indexInLedger: number;
|
68 | fee: string;
|
69 | balanceChanges: {
|
70 | [key: string]: {
|
71 | currency: string;
|
72 | counterparty?: string;
|
73 | value: string;
|
74 | }[];
|
75 | };
|
76 | orderbookChanges: object;
|
77 | deliveredAmount?: {
|
78 | currency: string;
|
79 | counterparty?: string;
|
80 | value: string;
|
81 | };
|
82 | timestamp?: string;
|
83 | };
|
84 | export declare type FormattedOrderCancellation = {
|
85 | orderSequence: number;
|
86 | };
|
87 | export declare type FormattedPayment = {
|
88 | source: Adjustment;
|
89 | destination: Adjustment;
|
90 | paths?: string;
|
91 | memos?: Array<Memo>;
|
92 | invoiceID?: string;
|
93 | allowPartialPayment?: boolean;
|
94 | noDirectRipple?: boolean;
|
95 | limitQuality?: boolean;
|
96 | };
|
97 | export declare type FormattedPaymentTransaction = {
|
98 | type: string;
|
99 | specification: FormattedPayment;
|
100 | outcome: Outcome;
|
101 | id: string;
|
102 | address: string;
|
103 | sequence: number;
|
104 | };
|
105 | export declare type FormattedOrderTransaction = {
|
106 | type: string;
|
107 | specification: FormattedOrderSpecification;
|
108 | outcome: Outcome;
|
109 | id: string;
|
110 | address: string;
|
111 | sequence: number;
|
112 | };
|
113 | export declare type FormattedOrderCancellationTransaction = {
|
114 | type: string;
|
115 | specification: FormattedOrderCancellation;
|
116 | outcome: Outcome;
|
117 | id: string;
|
118 | address: string;
|
119 | sequence: number;
|
120 | };
|
121 | export declare type FormattedTrustlineTransaction = {
|
122 | type: string;
|
123 | specification: FormattedTrustlineSpecification;
|
124 | outcome: Outcome;
|
125 | id: string;
|
126 | address: string;
|
127 | sequence: number;
|
128 | };
|
129 | export declare type FormattedSettingsTransaction = {
|
130 | type: string;
|
131 | specification: FormattedSettings;
|
132 | outcome: Outcome;
|
133 | id: string;
|
134 | address: string;
|
135 | sequence: number;
|
136 | };
|
137 | export declare type FormattedTransactionType = FormattedPaymentTransaction | FormattedOrderTransaction | FormattedOrderCancellationTransaction | FormattedTrustlineTransaction | FormattedSettingsTransaction;
|
138 |
|
\ | No newline at end of file |