@avalabs/glacier-sdk 3.1.0-canary.3d0fcb3.0 → 3.1.0-canary.3d27bb6.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/dist/index.cjs +1 -1
- package/dist/index.d.ts +571 -29
- package/esm/generated/Glacier.js +1 -1
- package/esm/generated/core/CancelablePromise.js +1 -1
- package/esm/generated/core/OpenAPI.js +1 -1
- package/esm/generated/core/request.js +1 -1
- package/esm/generated/models/AvaxSupplyResponse.d.ts +48 -0
- package/esm/generated/models/Blockchain.d.ts +5 -3
- package/esm/generated/models/BlockchainInfo.d.ts +3 -1
- package/esm/generated/models/Erc1155Transfer.d.ts +5 -1
- package/esm/generated/models/Erc20Transfer.d.ts +5 -1
- package/esm/generated/models/Erc721Transfer.d.ts +5 -1
- package/esm/generated/models/EvmBlock.d.ts +9 -1
- package/esm/generated/models/EvmGenesisAllocDto.d.ts +16 -0
- package/esm/generated/models/EvmGenesisAllowListConfigDto.d.ts +20 -0
- package/esm/generated/models/EvmGenesisConfigDto.d.ts +96 -0
- package/esm/generated/models/EvmGenesisDto.d.ts +75 -0
- package/esm/generated/models/EvmGenesisFeeConfigDto.d.ts +36 -0
- package/esm/generated/models/EvmGenesisWarpConfigDto.d.ts +16 -0
- package/esm/generated/models/FullNativeTransactionDetails.d.ts +9 -1
- package/esm/generated/models/GetEvmBlockResponse.d.ts +9 -1
- package/esm/generated/models/InternalTransaction.d.ts +5 -1
- package/esm/generated/models/LastActivityTimestamp.d.ts +29 -0
- package/esm/generated/models/NativeTransaction.d.ts +9 -1
- package/esm/generated/models/PChainTransaction.d.ts +1 -1
- package/esm/generated/models/PChainUtxo.d.ts +4 -0
- package/esm/generated/models/PrimaryNetworkAddressesBodyDto.d.ts +8 -0
- package/esm/generated/models/SignatureAggregatorRequest.d.ts +21 -1
- package/esm/generated/models/Utxo.d.ts +4 -0
- package/esm/generated/models/UtxosSortByOption.d.ts +6 -0
- package/esm/generated/models/UtxosSortByOption.js +1 -0
- package/esm/generated/services/AvaxSupplyService.d.ts +3 -2
- package/esm/generated/services/EvmBlocksService.d.ts +1 -1
- package/esm/generated/services/EvmChainsService.d.ts +1 -1
- package/esm/generated/services/EvmTransactionsService.d.ts +40 -1
- package/esm/generated/services/EvmTransactionsService.js +1 -1
- package/esm/generated/services/HealthCheckService.d.ts +9 -2
- package/esm/generated/services/HealthCheckService.js +1 -1
- package/esm/generated/services/PrimaryNetworkUtxOsService.d.ts +94 -1
- package/esm/generated/services/PrimaryNetworkUtxOsService.js +1 -1
- package/esm/index.d.ts +10 -0
- package/esm/index.js +1 -1
- package/package.json +2 -2
package/esm/generated/Glacier.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{FetchHttpRequest as e}from"./core/FetchHttpRequest.js";import{AvaxSupplyService as r}from"./services/AvaxSupplyService.js";import{DataApiUsageMetricsService as s}from"./services/DataApiUsageMetricsService.js";import{DefaultService as i}from"./services/DefaultService.js";import{EvmBalancesService as t}from"./services/EvmBalancesService.js";import{EvmBlocksService as o}from"./services/EvmBlocksService.js";import{EvmChainsService as a}from"./services/EvmChainsService.js";import{EvmContractsService as c}from"./services/EvmContractsService.js";import{EvmTransactionsService as m}from"./services/EvmTransactionsService.js";import{HealthCheckService as n}from"./services/HealthCheckService.js";import{InterchainMessagingService as h}from"./services/InterchainMessagingService.js";import{NfTsService as v}from"./services/NfTsService.js";import{NotificationsService as p}from"./services/NotificationsService.js";import{OperationsService as w}from"./services/OperationsService.js";import{PrimaryNetworkService as S}from"./services/PrimaryNetworkService.js";import{PrimaryNetworkBalancesService as u}from"./services/PrimaryNetworkBalancesService.js";import{PrimaryNetworkBlocksService as N}from"./services/PrimaryNetworkBlocksService.js";import{PrimaryNetworkRewardsService as k}from"./services/PrimaryNetworkRewardsService.js";import{PrimaryNetworkTransactionsService as f}from"./services/PrimaryNetworkTransactionsService.js";import{PrimaryNetworkUtxOsService as E}from"./services/PrimaryNetworkUtxOsService.js";import{PrimaryNetworkVerticesService as l}from"./services/PrimaryNetworkVerticesService.js";import{SignatureAggregatorService as q}from"./services/SignatureAggregatorService.js";import{TeleporterService as j}from"./services/TeleporterService.js";import{WebhooksService as y}from"./services/WebhooksService.js";class g{avaxSupply;dataApiUsageMetrics;default;evmBalances;evmBlocks;evmChains;evmContracts;evmTransactions;healthCheck;interchainMessaging;nfTs;notifications;operations;primaryNetwork;primaryNetworkBalances;primaryNetworkBlocks;primaryNetworkRewards;primaryNetworkTransactions;primaryNetworkUtxOs;primaryNetworkVertices;signatureAggregator;teleporter;webhooks;request;constructor(g,A=e){this.request=new A({BASE:g?.BASE??"https://
|
|
1
|
+
import{FetchHttpRequest as e}from"./core/FetchHttpRequest.js";import{AvaxSupplyService as r}from"./services/AvaxSupplyService.js";import{DataApiUsageMetricsService as s}from"./services/DataApiUsageMetricsService.js";import{DefaultService as i}from"./services/DefaultService.js";import{EvmBalancesService as t}from"./services/EvmBalancesService.js";import{EvmBlocksService as o}from"./services/EvmBlocksService.js";import{EvmChainsService as a}from"./services/EvmChainsService.js";import{EvmContractsService as c}from"./services/EvmContractsService.js";import{EvmTransactionsService as m}from"./services/EvmTransactionsService.js";import{HealthCheckService as n}from"./services/HealthCheckService.js";import{InterchainMessagingService as h}from"./services/InterchainMessagingService.js";import{NfTsService as v}from"./services/NfTsService.js";import{NotificationsService as p}from"./services/NotificationsService.js";import{OperationsService as w}from"./services/OperationsService.js";import{PrimaryNetworkService as S}from"./services/PrimaryNetworkService.js";import{PrimaryNetworkBalancesService as u}from"./services/PrimaryNetworkBalancesService.js";import{PrimaryNetworkBlocksService as N}from"./services/PrimaryNetworkBlocksService.js";import{PrimaryNetworkRewardsService as k}from"./services/PrimaryNetworkRewardsService.js";import{PrimaryNetworkTransactionsService as f}from"./services/PrimaryNetworkTransactionsService.js";import{PrimaryNetworkUtxOsService as E}from"./services/PrimaryNetworkUtxOsService.js";import{PrimaryNetworkVerticesService as l}from"./services/PrimaryNetworkVerticesService.js";import{SignatureAggregatorService as q}from"./services/SignatureAggregatorService.js";import{TeleporterService as j}from"./services/TeleporterService.js";import{WebhooksService as y}from"./services/WebhooksService.js";class g{avaxSupply;dataApiUsageMetrics;default;evmBalances;evmBlocks;evmChains;evmContracts;evmTransactions;healthCheck;interchainMessaging;nfTs;notifications;operations;primaryNetwork;primaryNetworkBalances;primaryNetworkBlocks;primaryNetworkRewards;primaryNetworkTransactions;primaryNetworkUtxOs;primaryNetworkVertices;signatureAggregator;teleporter;webhooks;request;constructor(g,A=e){this.request=new A({BASE:g?.BASE??"https://data-api-dev.avax.network",VERSION:g?.VERSION??"1.0.0",WITH_CREDENTIALS:g?.WITH_CREDENTIALS??!1,CREDENTIALS:g?.CREDENTIALS??"include",TOKEN:g?.TOKEN,USERNAME:g?.USERNAME,PASSWORD:g?.PASSWORD,HEADERS:g?.HEADERS,ENCODE_PATH:g?.ENCODE_PATH}),this.avaxSupply=new r(this.request),this.dataApiUsageMetrics=new s(this.request),this.default=new i(this.request),this.evmBalances=new t(this.request),this.evmBlocks=new o(this.request),this.evmChains=new a(this.request),this.evmContracts=new c(this.request),this.evmTransactions=new m(this.request),this.healthCheck=new n(this.request),this.interchainMessaging=new h(this.request),this.nfTs=new v(this.request),this.notifications=new p(this.request),this.operations=new w(this.request),this.primaryNetwork=new S(this.request),this.primaryNetworkBalances=new u(this.request),this.primaryNetworkBlocks=new N(this.request),this.primaryNetworkRewards=new k(this.request),this.primaryNetworkTransactions=new f(this.request),this.primaryNetworkUtxOs=new E(this.request),this.primaryNetworkVertices=new l(this.request),this.signatureAggregator=new q(this.request),this.teleporter=new j(this.request),this.webhooks=new y(this.request)}}export{g as Glacier};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
class e extends Error{constructor(e){super(e),this.name="CancelError"}get isCancelled(){return!0}}class s{#e;#s;#t;#i;#l;#r;#c;constructor(e){this.#e=!1,this.#s=!1,this.#t=!1,this.#i=[],this.#l=new Promise((s,t)=>{this.#r=s,this.#c=t;const i=e=>{this.#e||this.#s||this.#t||this.#i.push(e)};return Object.defineProperty(i,"isResolved",{get:()=>this.#e}),Object.defineProperty(i,"isRejected",{get:()=>this.#s}),Object.defineProperty(i,"isCancelled",{get:()=>this.#t}),e(e=>{this.#e||this.#s||this.#t||(this.#e=!0,this.#r?.(e))},e=>{this.#e||this.#s||this.#t||(this.#s=!0,this.#c?.(e))},i)})}get[Symbol.toStringTag](){return"Cancellable Promise"}then(e,s){return this.#l.then(e,s)}catch(e){return this.#l.catch(e)}finally(e){return this.#l.finally(e)}cancel(){if(!(this.#e||this.#s||this.#t)){if(this.#t=!0,this.#i.length)try{for(const e of this.#i)e()}catch(e){return void console.warn("Cancellation threw an error",e)}this.#i.length=0,this.#c?.(new e("Request aborted"))}}get isCancelled(){return this.#t}}export{e as CancelError,s as CancelablePromise};
|
|
1
|
+
class e extends Error{constructor(e){super(e),this.name="CancelError"}get isCancelled(){return!0}}class s{#e;#s;#t;#i;#l;#r;#c;constructor(e){this.#e=!1,this.#s=!1,this.#t=!1,this.#i=[],this.#l=new Promise(((s,t)=>{this.#r=s,this.#c=t;const i=e=>{this.#e||this.#s||this.#t||this.#i.push(e)};return Object.defineProperty(i,"isResolved",{get:()=>this.#e}),Object.defineProperty(i,"isRejected",{get:()=>this.#s}),Object.defineProperty(i,"isCancelled",{get:()=>this.#t}),e((e=>{this.#e||this.#s||this.#t||(this.#e=!0,this.#r?.(e))}),(e=>{this.#e||this.#s||this.#t||(this.#s=!0,this.#c?.(e))}),i)}))}get[Symbol.toStringTag](){return"Cancellable Promise"}then(e,s){return this.#l.then(e,s)}catch(e){return this.#l.catch(e)}finally(e){return this.#l.finally(e)}cancel(){if(!(this.#e||this.#s||this.#t)){if(this.#t=!0,this.#i.length)try{for(const e of this.#i)e()}catch(e){return void console.warn("Cancellation threw an error",e)}this.#i.length=0,this.#c?.(new e("Request aborted"))}}get isCancelled(){return this.#t}}export{e as CancelError,s as CancelablePromise};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const E={BASE:"https://
|
|
1
|
+
const E={BASE:"https://data-api-dev.avax.network",VERSION:"1.0.0",WITH_CREDENTIALS:!1,CREDENTIALS:"include",TOKEN:void 0,USERNAME:void 0,PASSWORD:void 0,HEADERS:void 0,ENCODE_PATH:void 0};export{E as OpenAPI};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ApiError as t}from"./ApiError.js";import{CancelablePromise as e}from"./CancelablePromise.js";const o=t=>null!=t,r=t=>"string"==typeof t,n=t=>r(t)&&""!==t,a=t=>"object"==typeof t&&"string"==typeof t.type&&"function"==typeof t.stream&&"function"==typeof t.arrayBuffer&&"function"==typeof t.constructor&&"string"==typeof t.constructor.name&&/^(Blob|File)$/.test(t.constructor.name)&&/^(Blob|File)$/.test(t[Symbol.toStringTag]),i=t=>t instanceof FormData,s=t=>{const e=[],r=(t,n)=>{o(n)&&(Array.isArray(n)?n.forEach(e=>{r(t,e)}):"object"==typeof n?Object.entries(n).forEach(([e,o])=>{r(`${t}[${e}]`,o)}):((t,o)=>{e.push(`${encodeURIComponent(t)}=${encodeURIComponent(String(o))}`)})(t,n))};return Object.entries(t).forEach(([t,e])=>{r(t,e)}),e.length>0?`?${e.join("&")}`:""},c=async(t,e)=>"function"==typeof e?e(t):e,y=async(t,e)=>{const s=await c(e,t.TOKEN),y=await c(e,t.USERNAME),p=await c(e,t.PASSWORD),f=await c(e,t.HEADERS),d=Object.entries({Accept:"application/json",...f,...e.headers}).filter(([t,e])=>o(e)).reduce((t,[e,o])=>({...t,[e]:String(o)}),{});if(n(s)&&(d.Authorization=`Bearer ${s}`),n(y)&&n(p)){const t=(t=>{try{return btoa(t)}catch(e){return Buffer.from(t).toString("base64")}})(`${y}:${p}`);d.Authorization=`Basic ${t}`}return e.body&&(e.mediaType?d["Content-Type"]=e.mediaType:a(e.body)?d["Content-Type"]=e.body.type||"application/octet-stream":r(e.body)?d["Content-Type"]="text/plain":i(e.body)||(d["Content-Type"]="application/json")),new Headers(d)},p=async(t,e,o,r,n,a,i)=>{const s=new AbortController,c={headers:a,body:r??n,method:e.method,signal:s.signal};return t.WITH_CREDENTIALS&&(c.credentials=t.CREDENTIALS),i(()=>s.abort()),await fetch(o,c)},f=(n,c)=>new e(async(e,f,d)=>{try{const f=((t,e)=>{const o=t.ENCODE_PATH||encodeURI,r=e.url.replace("{api-version}",t.VERSION).replace(/{(.*?)}/g,(t,r)=>e.path?.hasOwnProperty(r)?o(String(e.path[r])):t),n=`${t.BASE}${r}`;return e.query?`${n}${s(e.query)}`:n})(n,c),u=(t=>{if(t.formData){const e=new FormData,n=(t,o)=>{r(o)||a(o)?e.append(t,o):e.append(t,JSON.stringify(o))};return Object.entries(t.formData).filter(([t,e])=>o(e)).forEach(([t,e])=>{Array.isArray(e)?e.forEach(e=>n(t,e)):n(t,e)}),e}})(c),l=(t=>{if(void 0!==t.body)return t.mediaType?.includes("/json")?JSON.stringify(t.body):r(t.body)||a(t.body)||i(t.body)?t.body:JSON.stringify(t.body)})(c),b=await y(n,c);if(!d.isCancelled){const o=await p(n,c,f,l,u,b,d),a=await(async t=>{if(204!==t.status)try{const e=t.headers.get("Content-Type");if(e)return["application/json","application/problem+json"].some(t=>e.toLowerCase().startsWith(t))?await t.json():await t.text()}catch(t){console.error(t)}})(o),i=((t,e)=>{if(e){const o=t.headers.get(e);if(r(o))return o}})(o,c.responseHeader),s={url:f,ok:o.ok,status:o.status,statusText:o.statusText,body:i??a};((e,o)=>{const r={400:"Bad Request",401:"Unauthorized",403:"Forbidden",404:"Not Found",500:"Internal Server Error",502:"Bad Gateway",503:"Service Unavailable",...e.errors}[o.status];if(r)throw new t(e,o,r);if(!o.ok)throw new t(e,o,"Generic Error")})(c,s),e(s.body)}}catch(t){f(t)}});export{f as request,p as sendRequest};
|
|
1
|
+
import{ApiError as t}from"./ApiError.js";import{CancelablePromise as e}from"./CancelablePromise.js";const o=t=>null!=t,r=t=>"string"==typeof t,n=t=>r(t)&&""!==t,a=t=>"object"==typeof t&&"string"==typeof t.type&&"function"==typeof t.stream&&"function"==typeof t.arrayBuffer&&"function"==typeof t.constructor&&"string"==typeof t.constructor.name&&/^(Blob|File)$/.test(t.constructor.name)&&/^(Blob|File)$/.test(t[Symbol.toStringTag]),i=t=>t instanceof FormData,s=t=>{const e=[],r=(t,n)=>{o(n)&&(Array.isArray(n)?n.forEach((e=>{r(t,e)})):"object"==typeof n?Object.entries(n).forEach((([e,o])=>{r(`${t}[${e}]`,o)})):((t,o)=>{e.push(`${encodeURIComponent(t)}=${encodeURIComponent(String(o))}`)})(t,n))};return Object.entries(t).forEach((([t,e])=>{r(t,e)})),e.length>0?`?${e.join("&")}`:""},c=async(t,e)=>"function"==typeof e?e(t):e,y=async(t,e)=>{const s=await c(e,t.TOKEN),y=await c(e,t.USERNAME),p=await c(e,t.PASSWORD),f=await c(e,t.HEADERS),d=Object.entries({Accept:"application/json",...f,...e.headers}).filter((([t,e])=>o(e))).reduce(((t,[e,o])=>({...t,[e]:String(o)})),{});if(n(s)&&(d.Authorization=`Bearer ${s}`),n(y)&&n(p)){const t=(t=>{try{return btoa(t)}catch(e){return Buffer.from(t).toString("base64")}})(`${y}:${p}`);d.Authorization=`Basic ${t}`}return e.body&&(e.mediaType?d["Content-Type"]=e.mediaType:a(e.body)?d["Content-Type"]=e.body.type||"application/octet-stream":r(e.body)?d["Content-Type"]="text/plain":i(e.body)||(d["Content-Type"]="application/json")),new Headers(d)},p=async(t,e,o,r,n,a,i)=>{const s=new AbortController,c={headers:a,body:r??n,method:e.method,signal:s.signal};return t.WITH_CREDENTIALS&&(c.credentials=t.CREDENTIALS),i((()=>s.abort())),await fetch(o,c)},f=(n,c)=>new e((async(e,f,d)=>{try{const f=((t,e)=>{const o=t.ENCODE_PATH||encodeURI,r=e.url.replace("{api-version}",t.VERSION).replace(/{(.*?)}/g,((t,r)=>e.path?.hasOwnProperty(r)?o(String(e.path[r])):t)),n=`${t.BASE}${r}`;return e.query?`${n}${s(e.query)}`:n})(n,c),u=(t=>{if(t.formData){const e=new FormData,n=(t,o)=>{r(o)||a(o)?e.append(t,o):e.append(t,JSON.stringify(o))};return Object.entries(t.formData).filter((([t,e])=>o(e))).forEach((([t,e])=>{Array.isArray(e)?e.forEach((e=>n(t,e))):n(t,e)})),e}})(c),l=(t=>{if(void 0!==t.body)return t.mediaType?.includes("/json")?JSON.stringify(t.body):r(t.body)||a(t.body)||i(t.body)?t.body:JSON.stringify(t.body)})(c),b=await y(n,c);if(!d.isCancelled){const o=await p(n,c,f,l,u,b,d),a=await(async t=>{if(204!==t.status)try{const e=t.headers.get("Content-Type");if(e)return["application/json","application/problem+json"].some((t=>e.toLowerCase().startsWith(t)))?await t.json():await t.text()}catch(t){console.error(t)}})(o),i=((t,e)=>{if(e){const o=t.headers.get(e);if(r(o))return o}})(o,c.responseHeader),s={url:f,ok:o.ok,status:o.status,statusText:o.statusText,body:i??a};((e,o)=>{const r={400:"Bad Request",401:"Unauthorized",403:"Forbidden",404:"Not Found",500:"Internal Server Error",502:"Bad Gateway",503:"Service Unavailable",...e.errors}[o.status];if(r)throw new t(e,o,r);if(!o.ok)throw new t(e,o,"Generic Error")})(c,s),e(s.body)}}catch(t){f(t)}}));export{f as request,p as sendRequest};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
type AvaxSupplyResponse = {
|
|
2
|
+
/**
|
|
3
|
+
* The circulating supply of AVAX.
|
|
4
|
+
*/
|
|
5
|
+
circulatingSupply: string;
|
|
6
|
+
/**
|
|
7
|
+
* The total supply of AVAX.
|
|
8
|
+
*/
|
|
9
|
+
totalSupply: string;
|
|
10
|
+
/**
|
|
11
|
+
* Represents the total amount of AVAX burned on the P-Chain. This value includes AVAX lost when the sum of input UTXOs exceeds the sum of output UTXOs—potentially by more than the expected transaction fee, such as in malformed or improperly constructed transactions—as well as all L1 validator fees that have been burned to date.
|
|
12
|
+
*/
|
|
13
|
+
totalPBurned: string;
|
|
14
|
+
/**
|
|
15
|
+
* Represents the total amount of AVAX burned on the C-Chain. This value includes the total amount of AVAX burned on the C-Chain in evm txns and the total amount of AVAX burned on the C-Chain in atomic txns.
|
|
16
|
+
*/
|
|
17
|
+
totalCBurned: string;
|
|
18
|
+
/**
|
|
19
|
+
* The total X-chain burned fees of AVAX.
|
|
20
|
+
*/
|
|
21
|
+
totalXBurned: string;
|
|
22
|
+
/**
|
|
23
|
+
* The total staked AVAX.
|
|
24
|
+
*/
|
|
25
|
+
totalStaked: string;
|
|
26
|
+
/**
|
|
27
|
+
* The total locked AVAX.
|
|
28
|
+
*/
|
|
29
|
+
totalLocked: string;
|
|
30
|
+
/**
|
|
31
|
+
* The total rewards AVAX.
|
|
32
|
+
*/
|
|
33
|
+
totalRewards: string;
|
|
34
|
+
/**
|
|
35
|
+
* The last updated time of the AVAX supply.
|
|
36
|
+
*/
|
|
37
|
+
lastUpdated: string;
|
|
38
|
+
/**
|
|
39
|
+
* The genesis unlock amount of the AVAX supply.
|
|
40
|
+
*/
|
|
41
|
+
genesisUnlock: string;
|
|
42
|
+
/**
|
|
43
|
+
* The total L1 validator fees of AVAX.
|
|
44
|
+
*/
|
|
45
|
+
l1ValidatorFees: string;
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
export type { AvaxSupplyResponse };
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { EvmGenesisDto } from './EvmGenesisDto.js';
|
|
2
|
+
|
|
1
3
|
type Blockchain = {
|
|
2
4
|
createBlockTimestamp: number;
|
|
3
5
|
createBlockNumber: string;
|
|
@@ -8,11 +10,11 @@ type Blockchain = {
|
|
|
8
10
|
/**
|
|
9
11
|
* EVM Chain ID for the EVM-based chains. This field is extracted from genesis data, and may be present for non-EVM chains as well.
|
|
10
12
|
*/
|
|
11
|
-
evmChainId
|
|
13
|
+
evmChainId?: number;
|
|
12
14
|
/**
|
|
13
|
-
* The genesis data of the blockchain.
|
|
15
|
+
* The genesis data of the blockchain. Can be either a parsed EvmGenesisDto object or a raw JSON string.
|
|
14
16
|
*/
|
|
15
|
-
genesisData?:
|
|
17
|
+
genesisData?: (EvmGenesisDto | string);
|
|
16
18
|
};
|
|
17
19
|
|
|
18
20
|
export type { Blockchain };
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
+
import { EvmGenesisDto } from './EvmGenesisDto.js';
|
|
2
|
+
|
|
1
3
|
type BlockchainInfo = {
|
|
2
4
|
chainName: string;
|
|
3
5
|
vmId: string;
|
|
4
6
|
/**
|
|
5
7
|
* The genesis data of the blockchain. Present for CreateChainTx. EVM based chains will return the genesis data as an object. Non-EVM based chains will return the genesis data as an encoded string. The encoding depends on the VM
|
|
6
8
|
*/
|
|
7
|
-
genesisData?:
|
|
9
|
+
genesisData?: (EvmGenesisDto | string);
|
|
8
10
|
};
|
|
9
11
|
|
|
10
12
|
export type { BlockchainInfo };
|
|
@@ -7,9 +7,13 @@ type Erc1155Transfer = {
|
|
|
7
7
|
*/
|
|
8
8
|
blockNumber: string;
|
|
9
9
|
/**
|
|
10
|
-
* The block
|
|
10
|
+
* The block creation (proposal) timestamp in seconds
|
|
11
11
|
*/
|
|
12
12
|
blockTimestamp: number;
|
|
13
|
+
/**
|
|
14
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
15
|
+
*/
|
|
16
|
+
blockTimestampMilliseconds?: number;
|
|
13
17
|
/**
|
|
14
18
|
* The block hash identifier.
|
|
15
19
|
*/
|
|
@@ -7,9 +7,13 @@ type Erc20Transfer = {
|
|
|
7
7
|
*/
|
|
8
8
|
blockNumber: string;
|
|
9
9
|
/**
|
|
10
|
-
* The block
|
|
10
|
+
* The block creation (proposal) timestamp in seconds
|
|
11
11
|
*/
|
|
12
12
|
blockTimestamp: number;
|
|
13
|
+
/**
|
|
14
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
15
|
+
*/
|
|
16
|
+
blockTimestampMilliseconds?: number;
|
|
13
17
|
/**
|
|
14
18
|
* The block hash identifier.
|
|
15
19
|
*/
|
|
@@ -7,9 +7,13 @@ type Erc721Transfer = {
|
|
|
7
7
|
*/
|
|
8
8
|
blockNumber: string;
|
|
9
9
|
/**
|
|
10
|
-
* The block
|
|
10
|
+
* The block creation (proposal) timestamp in seconds
|
|
11
11
|
*/
|
|
12
12
|
blockTimestamp: number;
|
|
13
|
+
/**
|
|
14
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
15
|
+
*/
|
|
16
|
+
blockTimestampMilliseconds?: number;
|
|
13
17
|
/**
|
|
14
18
|
* The block hash identifier.
|
|
15
19
|
*/
|
|
@@ -8,9 +8,17 @@ type EvmBlock = {
|
|
|
8
8
|
*/
|
|
9
9
|
blockNumber: string;
|
|
10
10
|
/**
|
|
11
|
-
* The block
|
|
11
|
+
* The block creation (proposal) timestamp in seconds
|
|
12
12
|
*/
|
|
13
13
|
blockTimestamp: number;
|
|
14
|
+
/**
|
|
15
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
16
|
+
*/
|
|
17
|
+
blockTimestampMilliseconds?: number;
|
|
18
|
+
/**
|
|
19
|
+
* Minimum block delay in milliseconds. Available only after Granite upgrade.
|
|
20
|
+
*/
|
|
21
|
+
blockMinDelayExcess?: number;
|
|
14
22
|
/**
|
|
15
23
|
* The block hash identifier.
|
|
16
24
|
*/
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type EvmGenesisAllocDto = {
|
|
2
|
+
/**
|
|
3
|
+
* Account balance in hex format
|
|
4
|
+
*/
|
|
5
|
+
balance?: string;
|
|
6
|
+
/**
|
|
7
|
+
* Contract bytecode in hex format
|
|
8
|
+
*/
|
|
9
|
+
code?: string;
|
|
10
|
+
/**
|
|
11
|
+
* Contract storage slots
|
|
12
|
+
*/
|
|
13
|
+
storage?: Record<string, string>;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export type { EvmGenesisAllocDto };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
type EvmGenesisAllowListConfigDto = {
|
|
2
|
+
/**
|
|
3
|
+
* Block timestamp
|
|
4
|
+
*/
|
|
5
|
+
blockTimestamp?: number;
|
|
6
|
+
/**
|
|
7
|
+
* Admin addresses
|
|
8
|
+
*/
|
|
9
|
+
adminAddresses?: Array<string>;
|
|
10
|
+
/**
|
|
11
|
+
* Manager addresses
|
|
12
|
+
*/
|
|
13
|
+
managerAddresses?: Array<string>;
|
|
14
|
+
/**
|
|
15
|
+
* Enabled addresses
|
|
16
|
+
*/
|
|
17
|
+
enabledAddresses?: Array<string>;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export type { EvmGenesisAllowListConfigDto };
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { EvmGenesisAllowListConfigDto } from './EvmGenesisAllowListConfigDto.js';
|
|
2
|
+
import { EvmGenesisFeeConfigDto } from './EvmGenesisFeeConfigDto.js';
|
|
3
|
+
import { EvmGenesisWarpConfigDto } from './EvmGenesisWarpConfigDto.js';
|
|
4
|
+
|
|
5
|
+
type EvmGenesisConfigDto = {
|
|
6
|
+
/**
|
|
7
|
+
* Berlin block number
|
|
8
|
+
*/
|
|
9
|
+
berlinBlock?: number;
|
|
10
|
+
/**
|
|
11
|
+
* Byzantium block number
|
|
12
|
+
*/
|
|
13
|
+
byzantiumBlock?: number;
|
|
14
|
+
/**
|
|
15
|
+
* Chain ID
|
|
16
|
+
*/
|
|
17
|
+
chainId?: number;
|
|
18
|
+
/**
|
|
19
|
+
* Constantinople block number
|
|
20
|
+
*/
|
|
21
|
+
constantinopleBlock?: number;
|
|
22
|
+
/**
|
|
23
|
+
* EIP-150 block number
|
|
24
|
+
*/
|
|
25
|
+
eip150Block?: number;
|
|
26
|
+
/**
|
|
27
|
+
* EIP-150 hash
|
|
28
|
+
*/
|
|
29
|
+
eip150Hash?: string;
|
|
30
|
+
/**
|
|
31
|
+
* EIP-155 block number
|
|
32
|
+
*/
|
|
33
|
+
eip155Block?: number;
|
|
34
|
+
/**
|
|
35
|
+
* EIP-158 block number
|
|
36
|
+
*/
|
|
37
|
+
eip158Block?: number;
|
|
38
|
+
/**
|
|
39
|
+
* Fee configuration
|
|
40
|
+
*/
|
|
41
|
+
feeConfig?: EvmGenesisFeeConfigDto;
|
|
42
|
+
/**
|
|
43
|
+
* Homestead block number
|
|
44
|
+
*/
|
|
45
|
+
homesteadBlock?: number;
|
|
46
|
+
/**
|
|
47
|
+
* Istanbul block number
|
|
48
|
+
*/
|
|
49
|
+
istanbulBlock?: number;
|
|
50
|
+
/**
|
|
51
|
+
* London block number
|
|
52
|
+
*/
|
|
53
|
+
londonBlock?: number;
|
|
54
|
+
/**
|
|
55
|
+
* Muir Glacier block number
|
|
56
|
+
*/
|
|
57
|
+
muirGlacierBlock?: number;
|
|
58
|
+
/**
|
|
59
|
+
* Petersburg block number
|
|
60
|
+
*/
|
|
61
|
+
petersburgBlock?: number;
|
|
62
|
+
/**
|
|
63
|
+
* Subnet EVM timestamp
|
|
64
|
+
*/
|
|
65
|
+
subnetEVMTimestamp?: number;
|
|
66
|
+
/**
|
|
67
|
+
* Allow fee recipients
|
|
68
|
+
*/
|
|
69
|
+
allowFeeRecipients?: boolean;
|
|
70
|
+
/**
|
|
71
|
+
* Warp configuration
|
|
72
|
+
*/
|
|
73
|
+
warpConfig?: EvmGenesisWarpConfigDto;
|
|
74
|
+
/**
|
|
75
|
+
* Transaction allow list configuration
|
|
76
|
+
*/
|
|
77
|
+
txAllowListConfig?: EvmGenesisAllowListConfigDto;
|
|
78
|
+
/**
|
|
79
|
+
* Contract deployer allow list configuration
|
|
80
|
+
*/
|
|
81
|
+
contractDeployerAllowListConfig?: EvmGenesisAllowListConfigDto;
|
|
82
|
+
/**
|
|
83
|
+
* Contract native minter configuration
|
|
84
|
+
*/
|
|
85
|
+
contractNativeMinterConfig?: EvmGenesisAllowListConfigDto;
|
|
86
|
+
/**
|
|
87
|
+
* Fee manager configuration
|
|
88
|
+
*/
|
|
89
|
+
feeManagerConfig?: EvmGenesisAllowListConfigDto;
|
|
90
|
+
/**
|
|
91
|
+
* Reward manager configuration
|
|
92
|
+
*/
|
|
93
|
+
rewardManagerConfig?: EvmGenesisAllowListConfigDto;
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
export type { EvmGenesisConfigDto };
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { EvmGenesisAllocDto } from './EvmGenesisAllocDto.js';
|
|
2
|
+
import { EvmGenesisConfigDto } from './EvmGenesisConfigDto.js';
|
|
3
|
+
|
|
4
|
+
type EvmGenesisDto = {
|
|
5
|
+
/**
|
|
6
|
+
* Airdrop amount
|
|
7
|
+
*/
|
|
8
|
+
airdropAmount?: number | null;
|
|
9
|
+
/**
|
|
10
|
+
* Airdrop hash
|
|
11
|
+
*/
|
|
12
|
+
airdropHash?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Allocation of accounts and balances
|
|
15
|
+
*/
|
|
16
|
+
alloc?: Record<string, EvmGenesisAllocDto>;
|
|
17
|
+
/**
|
|
18
|
+
* Base fee per gas
|
|
19
|
+
*/
|
|
20
|
+
baseFeePerGas?: number | null;
|
|
21
|
+
/**
|
|
22
|
+
* Blob gas used
|
|
23
|
+
*/
|
|
24
|
+
blobGasUsed?: string | null;
|
|
25
|
+
/**
|
|
26
|
+
* Coinbase address
|
|
27
|
+
*/
|
|
28
|
+
coinbase?: string;
|
|
29
|
+
/**
|
|
30
|
+
* Genesis configuration
|
|
31
|
+
*/
|
|
32
|
+
config?: EvmGenesisConfigDto;
|
|
33
|
+
/**
|
|
34
|
+
* Difficulty
|
|
35
|
+
*/
|
|
36
|
+
difficulty?: string;
|
|
37
|
+
/**
|
|
38
|
+
* Excess blob gas
|
|
39
|
+
*/
|
|
40
|
+
excessBlobGas?: string | null;
|
|
41
|
+
/**
|
|
42
|
+
* Extra data
|
|
43
|
+
*/
|
|
44
|
+
extraData?: string;
|
|
45
|
+
/**
|
|
46
|
+
* Gas limit
|
|
47
|
+
*/
|
|
48
|
+
gasLimit?: string;
|
|
49
|
+
/**
|
|
50
|
+
* Gas used
|
|
51
|
+
*/
|
|
52
|
+
gasUsed?: string;
|
|
53
|
+
/**
|
|
54
|
+
* Mix hash
|
|
55
|
+
*/
|
|
56
|
+
mixHash?: string;
|
|
57
|
+
/**
|
|
58
|
+
* Nonce
|
|
59
|
+
*/
|
|
60
|
+
nonce?: string;
|
|
61
|
+
/**
|
|
62
|
+
* Block number
|
|
63
|
+
*/
|
|
64
|
+
number?: string;
|
|
65
|
+
/**
|
|
66
|
+
* Parent hash
|
|
67
|
+
*/
|
|
68
|
+
parentHash?: string;
|
|
69
|
+
/**
|
|
70
|
+
* Block timestamp
|
|
71
|
+
*/
|
|
72
|
+
timestamp?: string;
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
export type { EvmGenesisDto };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
type EvmGenesisFeeConfigDto = {
|
|
2
|
+
/**
|
|
3
|
+
* Base fee change denominator
|
|
4
|
+
*/
|
|
5
|
+
baseFeeChangeDenominator?: number;
|
|
6
|
+
/**
|
|
7
|
+
* Block gas cost step
|
|
8
|
+
*/
|
|
9
|
+
blockGasCostStep?: number;
|
|
10
|
+
/**
|
|
11
|
+
* Gas limit
|
|
12
|
+
*/
|
|
13
|
+
gasLimit?: number;
|
|
14
|
+
/**
|
|
15
|
+
* Maximum block gas cost
|
|
16
|
+
*/
|
|
17
|
+
maxBlockGasCost?: number;
|
|
18
|
+
/**
|
|
19
|
+
* Minimum base fee
|
|
20
|
+
*/
|
|
21
|
+
minBaseFee?: number;
|
|
22
|
+
/**
|
|
23
|
+
* Minimum block gas cost
|
|
24
|
+
*/
|
|
25
|
+
minBlockGasCost?: number;
|
|
26
|
+
/**
|
|
27
|
+
* Target block rate
|
|
28
|
+
*/
|
|
29
|
+
targetBlockRate?: number;
|
|
30
|
+
/**
|
|
31
|
+
* Target gas
|
|
32
|
+
*/
|
|
33
|
+
targetGas?: number;
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export type { EvmGenesisFeeConfigDto };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type EvmGenesisWarpConfigDto = {
|
|
2
|
+
/**
|
|
3
|
+
* Block timestamp
|
|
4
|
+
*/
|
|
5
|
+
blockTimestamp?: number;
|
|
6
|
+
/**
|
|
7
|
+
* Quorum numerator
|
|
8
|
+
*/
|
|
9
|
+
quorumNumerator?: number;
|
|
10
|
+
/**
|
|
11
|
+
* Require primary network signers
|
|
12
|
+
*/
|
|
13
|
+
requirePrimaryNetworkSigners?: boolean;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export type { EvmGenesisWarpConfigDto };
|
|
@@ -7,9 +7,17 @@ type FullNativeTransactionDetails = {
|
|
|
7
7
|
*/
|
|
8
8
|
blockNumber: string;
|
|
9
9
|
/**
|
|
10
|
-
* The block
|
|
10
|
+
* The block creation (proposal) timestamp in seconds
|
|
11
11
|
*/
|
|
12
12
|
blockTimestamp: number;
|
|
13
|
+
/**
|
|
14
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
15
|
+
*/
|
|
16
|
+
blockTimestampMilliseconds?: number;
|
|
17
|
+
/**
|
|
18
|
+
* Minimum block delay in milliseconds. Available only after Granite upgrade.
|
|
19
|
+
*/
|
|
20
|
+
blockMinDelayExcess?: number;
|
|
13
21
|
/**
|
|
14
22
|
* The block hash identifier.
|
|
15
23
|
*/
|
|
@@ -8,9 +8,17 @@ type GetEvmBlockResponse = {
|
|
|
8
8
|
*/
|
|
9
9
|
blockNumber: string;
|
|
10
10
|
/**
|
|
11
|
-
* The block
|
|
11
|
+
* The block creation (proposal) timestamp in seconds
|
|
12
12
|
*/
|
|
13
13
|
blockTimestamp: number;
|
|
14
|
+
/**
|
|
15
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
16
|
+
*/
|
|
17
|
+
blockTimestampMilliseconds?: number;
|
|
18
|
+
/**
|
|
19
|
+
* Minimum block delay in milliseconds. Available only after Granite upgrade.
|
|
20
|
+
*/
|
|
21
|
+
blockMinDelayExcess?: number;
|
|
14
22
|
/**
|
|
15
23
|
* The block hash identifier.
|
|
16
24
|
*/
|
|
@@ -7,9 +7,13 @@ type InternalTransaction = {
|
|
|
7
7
|
*/
|
|
8
8
|
blockNumber: string;
|
|
9
9
|
/**
|
|
10
|
-
* The block
|
|
10
|
+
* The block creation (proposal) timestamp in seconds
|
|
11
11
|
*/
|
|
12
12
|
blockTimestamp: number;
|
|
13
|
+
/**
|
|
14
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
15
|
+
*/
|
|
16
|
+
blockTimestampMilliseconds?: number;
|
|
13
17
|
/**
|
|
14
18
|
* The block hash identifier.
|
|
15
19
|
*/
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { PrimaryNetworkChainName } from './PrimaryNetworkChainName.js';
|
|
2
|
+
import { PrimaryNetworkType } from './PrimaryNetworkType.js';
|
|
3
|
+
|
|
4
|
+
type LastActivityTimestamp = {
|
|
5
|
+
/**
|
|
6
|
+
* Unix timestamp in seconds at which the last activity occurred.
|
|
7
|
+
*/
|
|
8
|
+
timestamp: number;
|
|
9
|
+
/**
|
|
10
|
+
* Block height at which the last activity occurred.
|
|
11
|
+
*/
|
|
12
|
+
blockNumber: string;
|
|
13
|
+
/**
|
|
14
|
+
* Transaction hash of the transaction that created or consumed the address' UTXOs.
|
|
15
|
+
*/
|
|
16
|
+
txHash: string;
|
|
17
|
+
/**
|
|
18
|
+
* UTXO ID of the UTXO that was created or consumed.
|
|
19
|
+
*/
|
|
20
|
+
utxoId: string;
|
|
21
|
+
/**
|
|
22
|
+
* Whether the last activity was a consumption of an existing UTXO.
|
|
23
|
+
*/
|
|
24
|
+
isConsumed: boolean;
|
|
25
|
+
chainName: PrimaryNetworkChainName;
|
|
26
|
+
network: PrimaryNetworkType;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export type { LastActivityTimestamp };
|
|
@@ -7,9 +7,17 @@ type NativeTransaction = {
|
|
|
7
7
|
*/
|
|
8
8
|
blockNumber: string;
|
|
9
9
|
/**
|
|
10
|
-
* The block
|
|
10
|
+
* The block creation (proposal) timestamp in seconds
|
|
11
11
|
*/
|
|
12
12
|
blockTimestamp: number;
|
|
13
|
+
/**
|
|
14
|
+
* The block creation (proposal) timestamp in milliseconds. Available only after Granite upgrade.
|
|
15
|
+
*/
|
|
16
|
+
blockTimestampMilliseconds?: number;
|
|
17
|
+
/**
|
|
18
|
+
* Minimum block delay in milliseconds. Available only after Granite upgrade.
|
|
19
|
+
*/
|
|
20
|
+
blockMinDelayExcess?: number;
|
|
13
21
|
/**
|
|
14
22
|
* The block hash identifier.
|
|
15
23
|
*/
|
|
@@ -1,8 +1,28 @@
|
|
|
1
1
|
type SignatureAggregatorRequest = {
|
|
2
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Either Message or Justification must be provided. Hex-encoded message, optionally prefixed with "0x"
|
|
4
|
+
*/
|
|
5
|
+
message?: string;
|
|
6
|
+
/**
|
|
7
|
+
* Either Justification or Message must be provided. Hex-encoded justification, optionally prefixed with "0x"
|
|
8
|
+
*/
|
|
3
9
|
justification?: string;
|
|
10
|
+
/**
|
|
11
|
+
* Optional hex or cb58 encoded signing subnet ID. If omitted will default to the subnetID of the source blockchain.
|
|
12
|
+
*/
|
|
4
13
|
signingSubnetId?: string;
|
|
14
|
+
/**
|
|
15
|
+
* Optional. Integer from 0 to 100 representing the percentage of the weight of the signing Subnet that is required to sign the message. Defaults to 67 if omitted.
|
|
16
|
+
*/
|
|
5
17
|
quorumPercentage?: number;
|
|
18
|
+
/**
|
|
19
|
+
* Optional. Integer from 0 to 100 representing the additional percentage of weight of the signing Subnet that will be attempted to add to the signature. QuorumPercentage+QuorumPercentageBuffer must be less than or equal to 100. Obtaining signatures from more validators can take a longer time, but signatures representing a large percentage of the Subnet weight are less prone to become invalid due to validator weight changes. Defaults to 0 if omitted.
|
|
20
|
+
*/
|
|
21
|
+
quorumPercentageBuffer?: number;
|
|
22
|
+
/**
|
|
23
|
+
* Optional P-Chain height for validator set selection. If 0 (default), validators at proposed height will be used. If non-zero, validators at the specified P-Chain height will be used for signature aggregation.
|
|
24
|
+
*/
|
|
25
|
+
pChainHeight?: number;
|
|
6
26
|
};
|
|
7
27
|
|
|
8
28
|
export type { SignatureAggregatorRequest };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var t=(t=>(t.TIMESTAMP="timestamp",t.AMOUNT="amount",t))(t||{});export{t as UtxosSortByOption};
|