@iotexproject/kit 0.1.16 → 0.1.18
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.d.ts +2 -3
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -8591,9 +8591,6 @@ declare const modules$2: {
|
|
|
8591
8591
|
};
|
|
8592
8592
|
export type IotexscanModulesType = typeof modules$2;
|
|
8593
8593
|
declare class Ioid {
|
|
8594
|
-
test(args: {
|
|
8595
|
-
jsonParams: any;
|
|
8596
|
-
}, ctx?: ConfigContext): Promise<any>;
|
|
8597
8594
|
register(args: {
|
|
8598
8595
|
projectName: string;
|
|
8599
8596
|
deviceSignature: `0x${string}`;
|
|
@@ -8608,9 +8605,11 @@ declare class Ioid {
|
|
|
8608
8605
|
error: any;
|
|
8609
8606
|
ok?: undefined;
|
|
8610
8607
|
hash?: undefined;
|
|
8608
|
+
cid?: undefined;
|
|
8611
8609
|
} | {
|
|
8612
8610
|
ok: boolean;
|
|
8613
8611
|
hash: `0x${string}`;
|
|
8612
|
+
cid: string;
|
|
8614
8613
|
error?: undefined;
|
|
8615
8614
|
}>;
|
|
8616
8615
|
verifier(args: {
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var G=({url:b="http://localhost:9527",ctx:j}={})=>new Proxy({},{get(C,w,F){return new Proxy({},{get(E,D){return async(T)=>{for(let z in T){if(typeof T[z]==="object")T[z]=JSON.stringify(T[z],(A,B)=>typeof B==="bigint"?B.toString():B);if(T[z]==null)delete T[z]}const $=`${b}/${String(w)}/${String(D)}?${new URLSearchParams(T).toString()}`;let N;if(j)N=await fetch($,{headers:{...j}});else N=await fetch($);return N.json()}}})}}),H=({url:b="http://localhost:9527"}={})=>new Proxy({},{get(j,C,w){return new Proxy({},{get(F,E){return async(D)=>{for(let N in D){if(typeof D[N]==="object")D[N]=JSON.stringify(D[N],(z,A)=>typeof A==="bigint"?A.toString():A);if(D[N]==null)delete D[N]}const T=`${b}/${String(C)}/${String(E)}?${new URLSearchParams(D).toString()}`;return(await fetch(T)).json()}}})}}),J=({url:b="http://localhost:9527",fetchRequestInit:j})=>new Proxy({},{get(C,w,F){return new Proxy({},{get(E,D){return async(T)=>{const $=`${b}/${String(w)}/${String(D)}`;return(await fetch($,{method:"POST",...j,body:JSON.stringify(T)})).json()}}})}}),K=({url:b="http://localhost:9527",fetchRequestInit:j})=>new Proxy({},{get(C,w,F){return new Proxy({},{get(E,D){return async(T)=>{const $=`${b}/${String(w)}/${String(D)}?${new URLSearchParams(T).toString()}`;return(await fetch($,{method:"GET",...j})).json()}}})}}),L=({url:b="http://localhost:9527",ctx:j}={})=>new Proxy({},{get(C,w,F){return new Proxy({},{get(E,D){return async(T)=>{let $=!1;for(let B in T){if(typeof T[B]==="object")$=!0;if(T[B]==null)delete T[B]}let N,z,A={};if($)N=`${b}/${String(w)}/${String(D)}`;else N=`${b}/${String(w)}/${String(D)}?${new URLSearchParams(T).toString()}`;if(j)A.headers={...j};if($)A.method="POST",A.body=JSON.stringify(T);return z=await fetch(N,A),z.json()}}})}});export{K as createIotexscanClient,L as createIoidClient,J as createClientWithWriteDBServer,H as createClientWithDBServer,G as createClient};
|