-
Notifications
You must be signed in to change notification settings - Fork 2
/
assets.ts
42 lines (34 loc) · 1.28 KB
/
assets.ts
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
import esplora, { assets } from '../src/index';
const init = async () => {
await esplora.config({
endpoint: 'https://blockstream.info/liquid/api',
});
const asset = await assets.getAsset({
asset_id: `6f0279e9ed041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d`,
});
console.log(asset);
const assetTxs = await assets.getAssetTxs({
asset_id: `6f0279e9ed041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d`,
});
console.log(assetTxs);
const assetTxsMempool = await assets.getAssetTxsMempool({
asset_id: `6f0279e9ed041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d`,
});
console.log(assetTxsMempool);
const assetSupplyDecimal = await assets.getAssetSupplyDecimal({
asset_id: `6f0279e9e
console.log(asset);d041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d`,
});
console.log(assetSupplyDecimal);
const assetSupply = await assets.getAssetSupply({
asset_id: `6f0279e9ed041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d`,
});
console.log(assetSupply);
const assetTxsChain = await assets.getAssetTxsChain({
asset_id: `6f0279e9ed041c3d710a9f57d0c02928416460c4b722ae3457a11eec381c526d`,
});
console.log(assetTxsChain);
const assetRegistry = await assets.getAssetRegistry({});
console.log(assetRegistry);
};
init();