forked from veridatum-labs/earnproof-backend
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstellar.types.ts
More file actions
42 lines (38 loc) · 909 Bytes
/
Copy pathstellar.types.ts
File metadata and controls
42 lines (38 loc) · 909 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
export type HorizonPaymentRecord = {
id: string;
type: string;
transaction_hash: string;
created_at: string;
from?: string;
to?: string;
asset_type?: string;
asset_code?: string;
asset_issuer?: string;
amount?: string;
};
export type HorizonCollection<TRecord> = {
_embedded?: {
records?: TRecord[];
};
};
export type HorizonTransactionRecord = {
hash?: string;
memo_type?: string;
memo?: string | Uint8Array;
};
export type NormalizedMemo =
| { type: "none" }
| { type: "text"; value: string; truncated: boolean }
| { type: "id"; value: string }
| { type: "hash"; value: string }
| { type: "return_hash"; value: string };
export type NormalizedPayment = {
operationId: string;
stellarTransactionHash: string;
sourceAddress: string;
destinationAddress: string;
assetCode: string;
assetIssuer: string | null;
amount: string;
occurredAt: Date;
};