@opendatalabs/vana-sdk 0.1.0-alpha.18ba63a → 0.1.0-alpha.21f7ddb
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/chains.browser.cjs +2 -2
- package/dist/chains.browser.cjs.map +1 -1
- package/dist/chains.browser.js +2 -2
- package/dist/chains.browser.js.map +1 -1
- package/dist/chains.cjs +2 -2
- package/dist/chains.cjs.map +1 -1
- package/dist/chains.js +2 -2
- package/dist/chains.js.map +1 -1
- package/dist/chains.node.cjs +2 -2
- package/dist/chains.node.cjs.map +1 -1
- package/dist/chains.node.js +2 -2
- package/dist/chains.node.js.map +1 -1
- package/dist/index.browser.d.ts +159 -6
- package/dist/index.browser.js +897 -514
- package/dist/index.browser.js.map +1 -1
- package/dist/index.node.cjs +931 -547
- package/dist/index.node.cjs.map +1 -1
- package/dist/index.node.d.cts +159 -6
- package/dist/index.node.d.ts +159 -6
- package/dist/index.node.js +903 -519
- package/dist/index.node.js.map +1 -1
- package/package.json +1 -1
package/dist/chains.browser.cjs
CHANGED
|
@@ -48,7 +48,7 @@ var vanaMainnet = {
|
|
|
48
48
|
url: "https://vanascan.io"
|
|
49
49
|
}
|
|
50
50
|
},
|
|
51
|
-
subgraphUrl: "https://
|
|
51
|
+
subgraphUrl: "https://vanagraph.io/v7"
|
|
52
52
|
};
|
|
53
53
|
var moksha = {
|
|
54
54
|
id: 14800,
|
|
@@ -69,7 +69,7 @@ var moksha = {
|
|
|
69
69
|
url: "https://moksha.vanascan.io"
|
|
70
70
|
}
|
|
71
71
|
},
|
|
72
|
-
subgraphUrl: "https://
|
|
72
|
+
subgraphUrl: "https://moksha.vanagraph.io/v7"
|
|
73
73
|
};
|
|
74
74
|
function getChainConfig(chainId) {
|
|
75
75
|
switch (chainId) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/chains.browser.ts","../src/chains/definitions.ts"],"sourcesContent":["/**\n * Browser-specific chains entry point\n *\n * This is identical to the base chains export since chain configurations\n * are environment-agnostic.\n */\n\nexport type { VanaChainConfig } from \"./chains/definitions\";\nexport {\n vanaMainnet,\n moksha,\n mokshaTestnet,\n getChainConfig,\n getAllChains,\n} from \"./chains/definitions\";\n","/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl
|
|
1
|
+
{"version":3,"sources":["../src/chains.browser.ts","../src/chains/definitions.ts"],"sourcesContent":["/**\n * Browser-specific chains entry point\n *\n * This is identical to the base chains export since chain configurations\n * are environment-agnostic.\n */\n\nexport type { VanaChainConfig } from \"./chains/definitions\";\nexport {\n vanaMainnet,\n moksha,\n mokshaTestnet,\n getChainConfig,\n getAllChains,\n} from \"./chains/definitions\";\n","/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl: \"https://vanagraph.io/v7\",\n} as const;\n\n/**\n * Moksha Testnet configuration\n */\nexport const moksha: VanaChainConfig = {\n id: 14800,\n name: \"Moksha Testnet\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.moksha.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan - Moksha\",\n url: \"https://moksha.vanascan.io\",\n },\n },\n subgraphUrl: \"https://moksha.vanagraph.io/v7\",\n} as const;\n\n/**\n * Retrieves the chain configuration for a given chain ID.\n *\n * @param chainId - The numeric chain ID to look up\n * @returns The chain configuration if found, undefined otherwise\n * @example\n * ```typescript\n * const config = getChainConfig(1480);\n * if (config) {\n * console.log('Chain name:', config.name);\n * console.log('Subgraph URL:', config.subgraphUrl);\n * }\n * ```\n */\nexport function getChainConfig(chainId: number): VanaChainConfig | undefined {\n switch (chainId) {\n case 1480:\n return vanaMainnet;\n case 14800:\n return moksha;\n default:\n return undefined;\n }\n}\n\n// Backwards compatibility alias\nexport const mokshaTestnet = moksha;\n\n/**\n * Retrieves all available Vana chain configurations.\n *\n * @returns Array of all supported Vana chain configurations\n * @example\n * ```typescript\n * const chains = getAllChains();\n * console.log('Supported chains:');\n * chains.forEach(chain => {\n * console.log(`- ${chain.name} (ID: ${chain.id})`);\n * });\n * ```\n */\nexport function getAllChains(): VanaChainConfig[] {\n return [vanaMainnet, moksha];\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACiBO,IAAM,cAA+B;AAAA,EAC1C,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,sBAAsB;AAAA,IAC/B;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAKO,IAAM,SAA0B;AAAA,EACrC,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,6BAA6B;AAAA,IACtC;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAgBO,SAAS,eAAe,SAA8C;AAC3E,UAAQ,SAAS;AAAA,IACf,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AACH,aAAO;AAAA,IACT;AACE,aAAO;AAAA,EACX;AACF;AAGO,IAAM,gBAAgB;AAetB,SAAS,eAAkC;AAChD,SAAO,CAAC,aAAa,MAAM;AAC7B;","names":[]}
|
package/dist/chains.browser.js
CHANGED
|
@@ -18,7 +18,7 @@ var vanaMainnet = {
|
|
|
18
18
|
url: "https://vanascan.io"
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
|
-
subgraphUrl: "https://
|
|
21
|
+
subgraphUrl: "https://vanagraph.io/v7"
|
|
22
22
|
};
|
|
23
23
|
var moksha = {
|
|
24
24
|
id: 14800,
|
|
@@ -39,7 +39,7 @@ var moksha = {
|
|
|
39
39
|
url: "https://moksha.vanascan.io"
|
|
40
40
|
}
|
|
41
41
|
},
|
|
42
|
-
subgraphUrl: "https://
|
|
42
|
+
subgraphUrl: "https://moksha.vanagraph.io/v7"
|
|
43
43
|
};
|
|
44
44
|
function getChainConfig(chainId) {
|
|
45
45
|
switch (chainId) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl
|
|
1
|
+
{"version":3,"sources":["../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl: \"https://vanagraph.io/v7\",\n} as const;\n\n/**\n * Moksha Testnet configuration\n */\nexport const moksha: VanaChainConfig = {\n id: 14800,\n name: \"Moksha Testnet\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.moksha.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan - Moksha\",\n url: \"https://moksha.vanascan.io\",\n },\n },\n subgraphUrl: \"https://moksha.vanagraph.io/v7\",\n} as const;\n\n/**\n * Retrieves the chain configuration for a given chain ID.\n *\n * @param chainId - The numeric chain ID to look up\n * @returns The chain configuration if found, undefined otherwise\n * @example\n * ```typescript\n * const config = getChainConfig(1480);\n * if (config) {\n * console.log('Chain name:', config.name);\n * console.log('Subgraph URL:', config.subgraphUrl);\n * }\n * ```\n */\nexport function getChainConfig(chainId: number): VanaChainConfig | undefined {\n switch (chainId) {\n case 1480:\n return vanaMainnet;\n case 14800:\n return moksha;\n default:\n return undefined;\n }\n}\n\n// Backwards compatibility alias\nexport const mokshaTestnet = moksha;\n\n/**\n * Retrieves all available Vana chain configurations.\n *\n * @returns Array of all supported Vana chain configurations\n * @example\n * ```typescript\n * const chains = getAllChains();\n * console.log('Supported chains:');\n * chains.forEach(chain => {\n * console.log(`- ${chain.name} (ID: ${chain.id})`);\n * });\n * ```\n */\nexport function getAllChains(): VanaChainConfig[] {\n return [vanaMainnet, moksha];\n}\n"],"mappings":";AAiBO,IAAM,cAA+B;AAAA,EAC1C,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,sBAAsB;AAAA,IAC/B;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAKO,IAAM,SAA0B;AAAA,EACrC,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,6BAA6B;AAAA,IACtC;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAgBO,SAAS,eAAe,SAA8C;AAC3E,UAAQ,SAAS;AAAA,IACf,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AACH,aAAO;AAAA,IACT;AACE,aAAO;AAAA,EACX;AACF;AAGO,IAAM,gBAAgB;AAetB,SAAS,eAAkC;AAChD,SAAO,CAAC,aAAa,MAAM;AAC7B;","names":[]}
|
package/dist/chains.cjs
CHANGED
|
@@ -48,7 +48,7 @@ var vanaMainnet = {
|
|
|
48
48
|
url: "https://vanascan.io"
|
|
49
49
|
}
|
|
50
50
|
},
|
|
51
|
-
subgraphUrl: "https://
|
|
51
|
+
subgraphUrl: "https://vanagraph.io/v7"
|
|
52
52
|
};
|
|
53
53
|
var moksha = {
|
|
54
54
|
id: 14800,
|
|
@@ -69,7 +69,7 @@ var moksha = {
|
|
|
69
69
|
url: "https://moksha.vanascan.io"
|
|
70
70
|
}
|
|
71
71
|
},
|
|
72
|
-
subgraphUrl: "https://
|
|
72
|
+
subgraphUrl: "https://moksha.vanagraph.io/v7"
|
|
73
73
|
};
|
|
74
74
|
function getChainConfig(chainId) {
|
|
75
75
|
switch (chainId) {
|
package/dist/chains.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/chains.ts","../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chains entry point for SSR-safe chain configuration exports\n *\n * This module exports only chain configurations without any platform-specific\n * dependencies, making it safe for server-side rendering.\n */\n\nexport type { VanaChainConfig } from \"./chains/definitions\";\nexport {\n vanaMainnet,\n moksha,\n mokshaTestnet,\n getChainConfig,\n getAllChains,\n} from \"./chains/definitions\";\n","/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl
|
|
1
|
+
{"version":3,"sources":["../src/chains.ts","../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chains entry point for SSR-safe chain configuration exports\n *\n * This module exports only chain configurations without any platform-specific\n * dependencies, making it safe for server-side rendering.\n */\n\nexport type { VanaChainConfig } from \"./chains/definitions\";\nexport {\n vanaMainnet,\n moksha,\n mokshaTestnet,\n getChainConfig,\n getAllChains,\n} from \"./chains/definitions\";\n","/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl: \"https://vanagraph.io/v7\",\n} as const;\n\n/**\n * Moksha Testnet configuration\n */\nexport const moksha: VanaChainConfig = {\n id: 14800,\n name: \"Moksha Testnet\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.moksha.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan - Moksha\",\n url: \"https://moksha.vanascan.io\",\n },\n },\n subgraphUrl: \"https://moksha.vanagraph.io/v7\",\n} as const;\n\n/**\n * Retrieves the chain configuration for a given chain ID.\n *\n * @param chainId - The numeric chain ID to look up\n * @returns The chain configuration if found, undefined otherwise\n * @example\n * ```typescript\n * const config = getChainConfig(1480);\n * if (config) {\n * console.log('Chain name:', config.name);\n * console.log('Subgraph URL:', config.subgraphUrl);\n * }\n * ```\n */\nexport function getChainConfig(chainId: number): VanaChainConfig | undefined {\n switch (chainId) {\n case 1480:\n return vanaMainnet;\n case 14800:\n return moksha;\n default:\n return undefined;\n }\n}\n\n// Backwards compatibility alias\nexport const mokshaTestnet = moksha;\n\n/**\n * Retrieves all available Vana chain configurations.\n *\n * @returns Array of all supported Vana chain configurations\n * @example\n * ```typescript\n * const chains = getAllChains();\n * console.log('Supported chains:');\n * chains.forEach(chain => {\n * console.log(`- ${chain.name} (ID: ${chain.id})`);\n * });\n * ```\n */\nexport function getAllChains(): VanaChainConfig[] {\n return [vanaMainnet, moksha];\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACiBO,IAAM,cAA+B;AAAA,EAC1C,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,sBAAsB;AAAA,IAC/B;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAKO,IAAM,SAA0B;AAAA,EACrC,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,6BAA6B;AAAA,IACtC;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAgBO,SAAS,eAAe,SAA8C;AAC3E,UAAQ,SAAS;AAAA,IACf,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AACH,aAAO;AAAA,IACT;AACE,aAAO;AAAA,EACX;AACF;AAGO,IAAM,gBAAgB;AAetB,SAAS,eAAkC;AAChD,SAAO,CAAC,aAAa,MAAM;AAC7B;","names":[]}
|
package/dist/chains.js
CHANGED
|
@@ -18,7 +18,7 @@ var vanaMainnet = {
|
|
|
18
18
|
url: "https://vanascan.io"
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
|
-
subgraphUrl: "https://
|
|
21
|
+
subgraphUrl: "https://vanagraph.io/v7"
|
|
22
22
|
};
|
|
23
23
|
var moksha = {
|
|
24
24
|
id: 14800,
|
|
@@ -39,7 +39,7 @@ var moksha = {
|
|
|
39
39
|
url: "https://moksha.vanascan.io"
|
|
40
40
|
}
|
|
41
41
|
},
|
|
42
|
-
subgraphUrl: "https://
|
|
42
|
+
subgraphUrl: "https://moksha.vanagraph.io/v7"
|
|
43
43
|
};
|
|
44
44
|
function getChainConfig(chainId) {
|
|
45
45
|
switch (chainId) {
|
package/dist/chains.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl
|
|
1
|
+
{"version":3,"sources":["../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl: \"https://vanagraph.io/v7\",\n} as const;\n\n/**\n * Moksha Testnet configuration\n */\nexport const moksha: VanaChainConfig = {\n id: 14800,\n name: \"Moksha Testnet\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.moksha.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan - Moksha\",\n url: \"https://moksha.vanascan.io\",\n },\n },\n subgraphUrl: \"https://moksha.vanagraph.io/v7\",\n} as const;\n\n/**\n * Retrieves the chain configuration for a given chain ID.\n *\n * @param chainId - The numeric chain ID to look up\n * @returns The chain configuration if found, undefined otherwise\n * @example\n * ```typescript\n * const config = getChainConfig(1480);\n * if (config) {\n * console.log('Chain name:', config.name);\n * console.log('Subgraph URL:', config.subgraphUrl);\n * }\n * ```\n */\nexport function getChainConfig(chainId: number): VanaChainConfig | undefined {\n switch (chainId) {\n case 1480:\n return vanaMainnet;\n case 14800:\n return moksha;\n default:\n return undefined;\n }\n}\n\n// Backwards compatibility alias\nexport const mokshaTestnet = moksha;\n\n/**\n * Retrieves all available Vana chain configurations.\n *\n * @returns Array of all supported Vana chain configurations\n * @example\n * ```typescript\n * const chains = getAllChains();\n * console.log('Supported chains:');\n * chains.forEach(chain => {\n * console.log(`- ${chain.name} (ID: ${chain.id})`);\n * });\n * ```\n */\nexport function getAllChains(): VanaChainConfig[] {\n return [vanaMainnet, moksha];\n}\n"],"mappings":";AAiBO,IAAM,cAA+B;AAAA,EAC1C,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,sBAAsB;AAAA,IAC/B;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAKO,IAAM,SAA0B;AAAA,EACrC,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,6BAA6B;AAAA,IACtC;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAgBO,SAAS,eAAe,SAA8C;AAC3E,UAAQ,SAAS;AAAA,IACf,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AACH,aAAO;AAAA,IACT;AACE,aAAO;AAAA,EACX;AACF;AAGO,IAAM,gBAAgB;AAetB,SAAS,eAAkC;AAChD,SAAO,CAAC,aAAa,MAAM;AAC7B;","names":[]}
|
package/dist/chains.node.cjs
CHANGED
|
@@ -48,7 +48,7 @@ var vanaMainnet = {
|
|
|
48
48
|
url: "https://vanascan.io"
|
|
49
49
|
}
|
|
50
50
|
},
|
|
51
|
-
subgraphUrl: "https://
|
|
51
|
+
subgraphUrl: "https://vanagraph.io/v7"
|
|
52
52
|
};
|
|
53
53
|
var moksha = {
|
|
54
54
|
id: 14800,
|
|
@@ -69,7 +69,7 @@ var moksha = {
|
|
|
69
69
|
url: "https://moksha.vanascan.io"
|
|
70
70
|
}
|
|
71
71
|
},
|
|
72
|
-
subgraphUrl: "https://
|
|
72
|
+
subgraphUrl: "https://moksha.vanagraph.io/v7"
|
|
73
73
|
};
|
|
74
74
|
function getChainConfig(chainId) {
|
|
75
75
|
switch (chainId) {
|
package/dist/chains.node.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/chains.node.ts","../src/chains/definitions.ts"],"sourcesContent":["/**\n * Node.js-specific chains entry point\n *\n * This is identical to the base chains export since chain configurations\n * are environment-agnostic.\n */\n\nexport type { VanaChainConfig } from \"./chains/definitions\";\nexport {\n vanaMainnet,\n moksha,\n mokshaTestnet,\n getChainConfig,\n getAllChains,\n} from \"./chains/definitions\";\n","/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl
|
|
1
|
+
{"version":3,"sources":["../src/chains.node.ts","../src/chains/definitions.ts"],"sourcesContent":["/**\n * Node.js-specific chains entry point\n *\n * This is identical to the base chains export since chain configurations\n * are environment-agnostic.\n */\n\nexport type { VanaChainConfig } from \"./chains/definitions\";\nexport {\n vanaMainnet,\n moksha,\n mokshaTestnet,\n getChainConfig,\n getAllChains,\n} from \"./chains/definitions\";\n","/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl: \"https://vanagraph.io/v7\",\n} as const;\n\n/**\n * Moksha Testnet configuration\n */\nexport const moksha: VanaChainConfig = {\n id: 14800,\n name: \"Moksha Testnet\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.moksha.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan - Moksha\",\n url: \"https://moksha.vanascan.io\",\n },\n },\n subgraphUrl: \"https://moksha.vanagraph.io/v7\",\n} as const;\n\n/**\n * Retrieves the chain configuration for a given chain ID.\n *\n * @param chainId - The numeric chain ID to look up\n * @returns The chain configuration if found, undefined otherwise\n * @example\n * ```typescript\n * const config = getChainConfig(1480);\n * if (config) {\n * console.log('Chain name:', config.name);\n * console.log('Subgraph URL:', config.subgraphUrl);\n * }\n * ```\n */\nexport function getChainConfig(chainId: number): VanaChainConfig | undefined {\n switch (chainId) {\n case 1480:\n return vanaMainnet;\n case 14800:\n return moksha;\n default:\n return undefined;\n }\n}\n\n// Backwards compatibility alias\nexport const mokshaTestnet = moksha;\n\n/**\n * Retrieves all available Vana chain configurations.\n *\n * @returns Array of all supported Vana chain configurations\n * @example\n * ```typescript\n * const chains = getAllChains();\n * console.log('Supported chains:');\n * chains.forEach(chain => {\n * console.log(`- ${chain.name} (ID: ${chain.id})`);\n * });\n * ```\n */\nexport function getAllChains(): VanaChainConfig[] {\n return [vanaMainnet, moksha];\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACiBO,IAAM,cAA+B;AAAA,EAC1C,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,sBAAsB;AAAA,IAC/B;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAKO,IAAM,SAA0B;AAAA,EACrC,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,6BAA6B;AAAA,IACtC;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAgBO,SAAS,eAAe,SAA8C;AAC3E,UAAQ,SAAS;AAAA,IACf,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AACH,aAAO;AAAA,IACT;AACE,aAAO;AAAA,EACX;AACF;AAGO,IAAM,gBAAgB;AAetB,SAAS,eAAkC;AAChD,SAAO,CAAC,aAAa,MAAM;AAC7B;","names":[]}
|
package/dist/chains.node.js
CHANGED
|
@@ -18,7 +18,7 @@ var vanaMainnet = {
|
|
|
18
18
|
url: "https://vanascan.io"
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
|
-
subgraphUrl: "https://
|
|
21
|
+
subgraphUrl: "https://vanagraph.io/v7"
|
|
22
22
|
};
|
|
23
23
|
var moksha = {
|
|
24
24
|
id: 14800,
|
|
@@ -39,7 +39,7 @@ var moksha = {
|
|
|
39
39
|
url: "https://moksha.vanascan.io"
|
|
40
40
|
}
|
|
41
41
|
},
|
|
42
|
-
subgraphUrl: "https://
|
|
42
|
+
subgraphUrl: "https://moksha.vanagraph.io/v7"
|
|
43
43
|
};
|
|
44
44
|
function getChainConfig(chainId) {
|
|
45
45
|
switch (chainId) {
|
package/dist/chains.node.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl
|
|
1
|
+
{"version":3,"sources":["../src/chains/definitions.ts"],"sourcesContent":["/**\n * Chain configuration definitions for Vana networks\n *\n * These provide default configurations for known Vana chains.\n * Applications can use these as-is or override specific values.\n */\n\nimport type { Chain } from \"viem\";\n\nexport interface VanaChainConfig extends Chain {\n /** URL for the subgraph API endpoint used to query on-chain data */\n subgraphUrl: string;\n}\n\n/**\n * Vana Mainnet configuration\n */\nexport const vanaMainnet: VanaChainConfig = {\n id: 1480,\n name: \"Vana\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan\",\n url: \"https://vanascan.io\",\n },\n },\n subgraphUrl: \"https://vanagraph.io/v7\",\n} as const;\n\n/**\n * Moksha Testnet configuration\n */\nexport const moksha: VanaChainConfig = {\n id: 14800,\n name: \"Moksha Testnet\",\n nativeCurrency: {\n name: \"VANA\",\n symbol: \"VANA\",\n decimals: 18,\n },\n rpcUrls: {\n default: {\n http: [\"https://rpc.moksha.vana.org\"],\n },\n },\n blockExplorers: {\n default: {\n name: \"Vanascan - Moksha\",\n url: \"https://moksha.vanascan.io\",\n },\n },\n subgraphUrl: \"https://moksha.vanagraph.io/v7\",\n} as const;\n\n/**\n * Retrieves the chain configuration for a given chain ID.\n *\n * @param chainId - The numeric chain ID to look up\n * @returns The chain configuration if found, undefined otherwise\n * @example\n * ```typescript\n * const config = getChainConfig(1480);\n * if (config) {\n * console.log('Chain name:', config.name);\n * console.log('Subgraph URL:', config.subgraphUrl);\n * }\n * ```\n */\nexport function getChainConfig(chainId: number): VanaChainConfig | undefined {\n switch (chainId) {\n case 1480:\n return vanaMainnet;\n case 14800:\n return moksha;\n default:\n return undefined;\n }\n}\n\n// Backwards compatibility alias\nexport const mokshaTestnet = moksha;\n\n/**\n * Retrieves all available Vana chain configurations.\n *\n * @returns Array of all supported Vana chain configurations\n * @example\n * ```typescript\n * const chains = getAllChains();\n * console.log('Supported chains:');\n * chains.forEach(chain => {\n * console.log(`- ${chain.name} (ID: ${chain.id})`);\n * });\n * ```\n */\nexport function getAllChains(): VanaChainConfig[] {\n return [vanaMainnet, moksha];\n}\n"],"mappings":";AAiBO,IAAM,cAA+B;AAAA,EAC1C,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,sBAAsB;AAAA,IAC/B;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAKO,IAAM,SAA0B;AAAA,EACrC,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,gBAAgB;AAAA,IACd,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,UAAU;AAAA,EACZ;AAAA,EACA,SAAS;AAAA,IACP,SAAS;AAAA,MACP,MAAM,CAAC,6BAA6B;AAAA,IACtC;AAAA,EACF;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,MACP,MAAM;AAAA,MACN,KAAK;AAAA,IACP;AAAA,EACF;AAAA,EACA,aAAa;AACf;AAgBO,SAAS,eAAe,SAA8C;AAC3E,UAAQ,SAAS;AAAA,IACf,KAAK;AACH,aAAO;AAAA,IACT,KAAK;AACH,aAAO;AAAA,IACT;AACE,aAAO;AAAA,EACX;AACF;AAGO,IAAM,gBAAgB;AAetB,SAAS,eAAkC;AAChD,SAAO,CAAC,aAAa,MAAM;AAC7B;","names":[]}
|
package/dist/index.browser.d.ts
CHANGED
|
@@ -191,10 +191,10 @@ interface OnChainPermissionGrant {
|
|
|
191
191
|
grantUrl: string;
|
|
192
192
|
/** Cryptographic signature that authorized this permission */
|
|
193
193
|
grantSignature: string;
|
|
194
|
-
/** Hash of the grant file content for integrity verification */
|
|
195
|
-
grantHash: string;
|
|
196
194
|
/** Nonce used when granting the permission */
|
|
197
195
|
nonce: bigint;
|
|
196
|
+
/** Block number when permission started */
|
|
197
|
+
startBlock: bigint;
|
|
198
198
|
/** Block number when permission was granted */
|
|
199
199
|
addedAtBlock: bigint;
|
|
200
200
|
/** Timestamp when permission was added */
|
|
@@ -203,6 +203,13 @@ interface OnChainPermissionGrant {
|
|
|
203
203
|
transactionHash: string;
|
|
204
204
|
/** Address that granted the permission */
|
|
205
205
|
grantor: Address;
|
|
206
|
+
/** Grantee information */
|
|
207
|
+
grantee: {
|
|
208
|
+
/** Grantee ID */
|
|
209
|
+
id: string;
|
|
210
|
+
/** Grantee address */
|
|
211
|
+
address: string;
|
|
212
|
+
};
|
|
206
213
|
/** Whether the permission is still active (not revoked) */
|
|
207
214
|
active: boolean;
|
|
208
215
|
}
|
|
@@ -490,6 +497,48 @@ interface GenericTypedData extends RecordCompatible {
|
|
|
490
497
|
/** Message to sign */
|
|
491
498
|
message: Record<string, unknown>;
|
|
492
499
|
}
|
|
500
|
+
/**
|
|
501
|
+
* Represents EIP-712 typed data for permission revocation.
|
|
502
|
+
*
|
|
503
|
+
* @remarks
|
|
504
|
+
* Used when revoking previously granted permissions through gasless transactions.
|
|
505
|
+
* The message contains a nonce and the permission ID to revoke.
|
|
506
|
+
*
|
|
507
|
+
* @category Permissions
|
|
508
|
+
*/
|
|
509
|
+
interface RevokePermissionTypedData extends GenericTypedData {
|
|
510
|
+
/** EIP-712 type definitions for the RevokePermission structure */
|
|
511
|
+
types: {
|
|
512
|
+
RevokePermission: Array<{
|
|
513
|
+
name: string;
|
|
514
|
+
type: string;
|
|
515
|
+
}>;
|
|
516
|
+
};
|
|
517
|
+
/** The primary type identifier for revocation operations */
|
|
518
|
+
primaryType: "RevokePermission";
|
|
519
|
+
/** The structured message containing revocation parameters */
|
|
520
|
+
message: RevokePermissionInput;
|
|
521
|
+
}
|
|
522
|
+
/**
|
|
523
|
+
* Defines all valid primary types for EIP-712 typed data in the Vana SDK.
|
|
524
|
+
*
|
|
525
|
+
* @remarks
|
|
526
|
+
* These literal types ensure compile-time safety when handling typed data operations.
|
|
527
|
+
* Each corresponds to a specific blockchain operation type.
|
|
528
|
+
*
|
|
529
|
+
* @category Permissions
|
|
530
|
+
*/
|
|
531
|
+
type TypedDataPrimaryType = "Permission" | "RevokePermission" | "TrustServer" | "UntrustServer" | "AddServer" | "RegisterGrantee" | "ServerFilesAndPermission";
|
|
532
|
+
/**
|
|
533
|
+
* Represents the union of all specific typed data interfaces.
|
|
534
|
+
*
|
|
535
|
+
* @remarks
|
|
536
|
+
* Enables type-safe handling of any typed data structure in the SDK.
|
|
537
|
+
* Used internally by relayer handlers and signature verification.
|
|
538
|
+
*
|
|
539
|
+
* @category Permissions
|
|
540
|
+
*/
|
|
541
|
+
type SpecificTypedData = PermissionGrantTypedData | RevokePermissionTypedData | TrustServerTypedData | UntrustServerTypedData | AddAndTrustServerTypedData | RegisterGranteeTypedData | ServerFilesAndPermissionTypedData;
|
|
493
542
|
/**
|
|
494
543
|
* Permission operation types
|
|
495
544
|
*
|
|
@@ -1071,6 +1120,85 @@ interface StorageConfig {
|
|
|
1071
1120
|
*/
|
|
1072
1121
|
defaultProvider?: string;
|
|
1073
1122
|
}
|
|
1123
|
+
/**
|
|
1124
|
+
* Download relayer callbacks for proxying CORS-restricted downloads.
|
|
1125
|
+
*
|
|
1126
|
+
* Provides a callback to proxy download requests through your application server
|
|
1127
|
+
* when direct browser access fails due to CORS restrictions (e.g., Google Drive).
|
|
1128
|
+
*
|
|
1129
|
+
* IMPORTANT SECURITY REQUIREMENTS for your proxy endpoint:
|
|
1130
|
+
* 1. MUST block requests to private/internal IPs (SSRF protection)
|
|
1131
|
+
* 2. SHOULD NOT restrict domains (files can be hosted anywhere)
|
|
1132
|
+
*
|
|
1133
|
+
* @category Configuration
|
|
1134
|
+
* @example Client-side implementation:
|
|
1135
|
+
* ```typescript
|
|
1136
|
+
* const downloadRelayer: DownloadRelayerCallbacks = {
|
|
1137
|
+
* async proxyDownload(url) {
|
|
1138
|
+
* const response = await fetch('/api/proxy', {
|
|
1139
|
+
* method: 'POST',
|
|
1140
|
+
* headers: { 'Content-Type': 'application/json' },
|
|
1141
|
+
* body: JSON.stringify({ url })
|
|
1142
|
+
* });
|
|
1143
|
+
* return response.blob();
|
|
1144
|
+
* }
|
|
1145
|
+
* };
|
|
1146
|
+
* ```
|
|
1147
|
+
*
|
|
1148
|
+
* @example Server-side proxy endpoint (Next.js):
|
|
1149
|
+
* ```typescript
|
|
1150
|
+
* // /api/proxy/route.ts
|
|
1151
|
+
* import { promises as dns } from 'dns';
|
|
1152
|
+
* import { isIPv4 } from 'net';
|
|
1153
|
+
*
|
|
1154
|
+
* async function handleProxy(url: string) {
|
|
1155
|
+
* const { hostname } = new URL(url);
|
|
1156
|
+
*
|
|
1157
|
+
* // Resolve hostname to IP (handle localhost specially)
|
|
1158
|
+
* const ip = hostname === 'localhost' ? '127.0.0.1' :
|
|
1159
|
+
* isIPv4(hostname) ? hostname :
|
|
1160
|
+
* await dns.lookup(hostname).then(r => r.address);
|
|
1161
|
+
*
|
|
1162
|
+
* // SSRF Protection: Block private/internal IPs
|
|
1163
|
+
* if (isIPv4(ip)) {
|
|
1164
|
+
* const [a, b] = ip.split('.').map(Number);
|
|
1165
|
+
* if (a === 10 || a === 127 || a === 0 ||
|
|
1166
|
+
* (a === 172 && b >= 16 && b <= 31) ||
|
|
1167
|
+
* (a === 192 && b === 168) ||
|
|
1168
|
+
* (a === 169 && b === 254) ||
|
|
1169
|
+
* a >= 224) { // Also block multicast/reserved
|
|
1170
|
+
* return new Response('Private/internal addresses not allowed', { status: 403 });
|
|
1171
|
+
* }
|
|
1172
|
+
* }
|
|
1173
|
+
*
|
|
1174
|
+
* // Proxy the request
|
|
1175
|
+
* const response = await fetch(url, { redirect: 'manual' });
|
|
1176
|
+
*
|
|
1177
|
+
* // Handle redirects (with recursion limit)
|
|
1178
|
+
* if (response.status >= 301 && response.status <= 308) {
|
|
1179
|
+
* const location = response.headers.get('location');
|
|
1180
|
+
* if (location) return handleProxy(new URL(location, url).href);
|
|
1181
|
+
* }
|
|
1182
|
+
*
|
|
1183
|
+
* const data = await response.arrayBuffer();
|
|
1184
|
+
* return new Response(data, {
|
|
1185
|
+
* headers: {
|
|
1186
|
+
* 'Content-Type': response.headers.get('content-type') || 'application/octet-stream',
|
|
1187
|
+
* 'Access-Control-Allow-Origin': '*'
|
|
1188
|
+
* }
|
|
1189
|
+
* });
|
|
1190
|
+
* }
|
|
1191
|
+
* ```
|
|
1192
|
+
*/
|
|
1193
|
+
interface DownloadRelayerCallbacks {
|
|
1194
|
+
/**
|
|
1195
|
+
* Proxy a download request through your application server
|
|
1196
|
+
*
|
|
1197
|
+
* @param url - The URL to download from
|
|
1198
|
+
* @returns Promise resolving to the downloaded content as a Blob
|
|
1199
|
+
*/
|
|
1200
|
+
proxyDownload: (url: string) => Promise<Blob>;
|
|
1201
|
+
}
|
|
1074
1202
|
/**
|
|
1075
1203
|
* Relayer callback functions for handling gasless transactions.
|
|
1076
1204
|
*
|
|
@@ -1374,6 +1502,11 @@ interface BaseConfig {
|
|
|
1374
1502
|
* Provides flexible relay mechanism - can use HTTP, WebSocket, or any custom implementation.
|
|
1375
1503
|
*/
|
|
1376
1504
|
relayerCallbacks?: RelayerCallbacks;
|
|
1505
|
+
/**
|
|
1506
|
+
* Optional download relayer for proxying CORS-restricted downloads.
|
|
1507
|
+
* Provides a proxy mechanism for files stored on servers with CORS restrictions.
|
|
1508
|
+
*/
|
|
1509
|
+
downloadRelayer?: DownloadRelayerCallbacks;
|
|
1377
1510
|
/**
|
|
1378
1511
|
* Optional storage providers configuration for file upload/download.
|
|
1379
1512
|
* Required for: upload(), grant() without pre-stored URLs, schema operations.
|
|
@@ -1415,6 +1548,11 @@ interface BaseConfigWithStorage {
|
|
|
1415
1548
|
* Provides flexible relay mechanism - can use HTTP, WebSocket, or any custom implementation.
|
|
1416
1549
|
*/
|
|
1417
1550
|
relayerCallbacks?: RelayerCallbacks;
|
|
1551
|
+
/**
|
|
1552
|
+
* Optional download relayer for proxying CORS-restricted downloads.
|
|
1553
|
+
* Provides a proxy mechanism for files stored on servers with CORS restrictions.
|
|
1554
|
+
*/
|
|
1555
|
+
downloadRelayer?: DownloadRelayerCallbacks;
|
|
1418
1556
|
/** Required storage providers configuration for file upload/download */
|
|
1419
1557
|
storage: StorageConfig;
|
|
1420
1558
|
/**
|
|
@@ -30082,6 +30220,8 @@ interface ControllerContext$1 {
|
|
|
30082
30220
|
applicationClient?: WalletClient;
|
|
30083
30221
|
/** Handles gasless transaction submission through relayer services. */
|
|
30084
30222
|
relayerCallbacks?: RelayerCallbacks;
|
|
30223
|
+
/** Proxies CORS-restricted downloads through application server. */
|
|
30224
|
+
downloadRelayer?: DownloadRelayerCallbacks;
|
|
30085
30225
|
/** Manages file upload and download operations across storage providers. */
|
|
30086
30226
|
storageManager?: StorageManager;
|
|
30087
30227
|
/** Provides subgraph endpoint for querying indexed blockchain data. */
|
|
@@ -31792,6 +31932,8 @@ declare class SchemaValidator {
|
|
|
31792
31932
|
* Fetches and validates a data schema from a URL
|
|
31793
31933
|
*
|
|
31794
31934
|
* @param url - The URL to fetch the data schema from
|
|
31935
|
+
* @param downloadRelayer - Optional download relayer for CORS bypass
|
|
31936
|
+
* @param downloadRelayer.proxyDownload - Function to proxy downloads through application server
|
|
31795
31937
|
* @returns The validated data schema
|
|
31796
31938
|
* @throws SchemaValidationError if invalid or fetch fails
|
|
31797
31939
|
* @example
|
|
@@ -31800,7 +31942,9 @@ declare class SchemaValidator {
|
|
|
31800
31942
|
* const schema = await validator.fetchAndValidateSchema("https://example.com/schema.json");
|
|
31801
31943
|
* ```
|
|
31802
31944
|
*/
|
|
31803
|
-
fetchAndValidateSchema(url: string
|
|
31945
|
+
fetchAndValidateSchema(url: string, downloadRelayer?: {
|
|
31946
|
+
proxyDownload: (url: string) => Promise<Blob>;
|
|
31947
|
+
}): Promise<DataSchema>;
|
|
31804
31948
|
}
|
|
31805
31949
|
/**
|
|
31806
31950
|
* Global schema validator instance
|
|
@@ -31838,10 +31982,14 @@ declare function validateDataAgainstSchema(data: unknown, schema: DataSchema | S
|
|
|
31838
31982
|
* Convenience function to fetch and validate a data schema from a URL
|
|
31839
31983
|
*
|
|
31840
31984
|
* @param url - The URL to fetch the data schema from
|
|
31985
|
+
* @param downloadRelayer - Optional download relayer for CORS bypass
|
|
31986
|
+
* @param downloadRelayer.proxyDownload - Function to proxy downloads through application server
|
|
31841
31987
|
* @returns The validated data schema
|
|
31842
31988
|
* @throws SchemaValidationError if invalid or fetch fails
|
|
31843
31989
|
*/
|
|
31844
|
-
declare function fetchAndValidateSchema(url: string
|
|
31990
|
+
declare function fetchAndValidateSchema(url: string, downloadRelayer?: {
|
|
31991
|
+
proxyDownload: (url: string) => Promise<Blob>;
|
|
31992
|
+
}): Promise<DataSchema>;
|
|
31845
31993
|
|
|
31846
31994
|
/**
|
|
31847
31995
|
* Parameters for the `vana.personal.postRequest` method.
|
|
@@ -35579,6 +35727,7 @@ declare class VanaCore {
|
|
|
35579
35727
|
/** Handles environment-specific operations like encryption and file systems. */
|
|
35580
35728
|
protected platform: VanaPlatformAdapter;
|
|
35581
35729
|
private readonly relayerCallbacks?;
|
|
35730
|
+
private readonly downloadRelayer?;
|
|
35582
35731
|
private readonly storageManager?;
|
|
35583
35732
|
private readonly hasRequiredStorage;
|
|
35584
35733
|
private readonly ipfsGateways?;
|
|
@@ -36633,6 +36782,8 @@ declare function storeGrantFile(grantFile: GrantFile, relayerUrl: string): Promi
|
|
|
36633
36782
|
*
|
|
36634
36783
|
* @param grantUrl - The grant file URL from OnChainPermissionGrant.grantUrl
|
|
36635
36784
|
* @param _relayerUrl - URL of the relayer service (optional, unused)
|
|
36785
|
+
* @param downloadRelayer - Optional download relayer for proxying CORS-restricted downloads
|
|
36786
|
+
* @param downloadRelayer.proxyDownload - Function to proxy download requests through application server
|
|
36636
36787
|
* @returns Promise resolving to the complete grant file with operation details
|
|
36637
36788
|
* @throws {NetworkError} When all retrieval attempts fail
|
|
36638
36789
|
* @throws {SerializationError} When grant file format is invalid
|
|
@@ -36655,7 +36806,9 @@ declare function storeGrantFile(grantFile: GrantFile, relayerUrl: string): Promi
|
|
|
36655
36806
|
* }
|
|
36656
36807
|
* ```
|
|
36657
36808
|
*/
|
|
36658
|
-
declare function retrieveGrantFile(grantUrl: string, _relayerUrl?: string
|
|
36809
|
+
declare function retrieveGrantFile(grantUrl: string, _relayerUrl?: string, downloadRelayer?: {
|
|
36810
|
+
proxyDownload: (url: string) => Promise<Blob>;
|
|
36811
|
+
}): Promise<GrantFile>;
|
|
36659
36812
|
/**
|
|
36660
36813
|
* Generates a content hash for a grant file.
|
|
36661
36814
|
* This can be used for integrity verification.
|
|
@@ -37734,4 +37887,4 @@ declare function Vana(config: VanaConfig): VanaBrowserImpl;
|
|
|
37734
37887
|
*/
|
|
37735
37888
|
type VanaInstance = VanaBrowserImpl;
|
|
37736
37889
|
|
|
37737
|
-
export { type $defs, type APIResponse, type AddAndTrustServerInput, type AddAndTrustServerParams, type AddAndTrustServerTypedData, type AddRefinerParams, type AddRefinerResult, type AddSchemaParams, type AddSchemaResult, type AllKeys, ApiClient, type ApiClientConfig, type ApiResponse, AsyncQueue, type AsyncResult, type AuthenticationErrorResponse, type Awaited, type BaseConfig, type BaseConfigWithStorage, BaseController, type BatchServerInfoResult, type BatchUploadParams, type BatchUploadResult, type BlockRange, BlockchainError, type BlockchainErrorResponse, type Brand, BrowserPlatformAdapter, type Cache, type CacheConfig, CallbackStorage, type ChainConfig, type ChainConfigWithStorage, type CheckPermissionParams, CircuitBreaker, type CompleteSchema, type ComputeErrorResponse, type ConditionalOptional, type ConfigValidationOptions, type ConfigValidationResult, type ContractAddresses, type ContractCall, type ContractDeployment, ContractFactory, type ContractInfo, type ContractMethodParams, type ContractMethodReturnType, ContractNotFoundError, type Controller, type ControllerContext, type CreateOperationParams, type CreateOperationRequest, type CreateOperationResponse, type CreateSchemaParams, type CreateSchemaResult, DEFAULT_ENCRYPTION_SEED, DEFAULT_IPFS_GATEWAY, DataController, type DataSchema, type DecryptionErrorResponse, type DeepPartial, type DeepReadonly, type DeleteFileParams, type DeleteFileResult, type DownloadFileParams, type DownloadFileResult, type EncryptedUploadParams, type EncryptionInfo, type ErrorResponse, EventEmitter, type EventFilter, type EventLog, type Factory, type FileAccessErrorResponse, type FileAccessPermissions, type FileMetadata, type FilePermissionParams, type FileSharingConfig, type GasEstimate, type GenericRequest, type GenericResponse, type GenericTypedData, type GetFileParams, type GetOperationResponse, type GetUserFilesParams, type GetUserPermissionsOptions, type GetUserTrustedServersParams, GoogleDriveStorage, GrantExpiredError, type GrantFile, type GrantPermissionParams, GrantSchemaError, GrantValidationError, type GrantValidationErrorResponse, type GrantValidationOptions, type GrantValidationResult, type GrantedPermission, type Grantee, type GranteeInfo, GranteeMismatchError, type GranteeQueryOptions, type HttpMethod, IPFS_GATEWAYS, type IdentityResponseModel, type InitPersonalServerParams, type InternalServerErrorResponse, InvalidConfigurationError, IpfsStorage, type LegacyPermissionParams, type MaybeArray, type MaybePromise, MemoryCache, type Middleware, MiddlewarePipeline, NetworkError, type NetworkInfo, type Nominal, type NonNullable, NonceError, type NotFoundErrorResponse, type Observable, type Observer, type OmitByType, type OnChainPermissionGrant, type OperationErrorResponse, OperationNotAllowedError, type OptionalKeys, type PaginatedGrantees, type PaginatedTrustedServers, type PaginationParams, type PaginationResult, type PartialExcept, type Permission, type PermissionAnalytics, type PermissionCheckResult, PermissionError, type PermissionEvent, type PermissionGrantDomain, type PermissionGrantMessage, type PermissionGrantTypedData, type PermissionInfo, type PermissionInputMessage, type PermissionOperation, type PermissionQueryResult, type PermissionStatus, PermissionsController, PersonalServerError, type PersonalServerIdentity, type PersonalServerModel, type PickByType, type PinataListResponse, type PinataPin, PinataStorage, type PinataUploadResponse, type Plugin, type PostRequestParams, type PromiseResult, ProtocolController, type QueryPermissionsParams, type RateLimitInfo, RateLimiter, type RateLimiterConfig, type Refiner, type RegisterGranteeInput, type RegisterGranteeParams, type RegisterGranteeTypedData, type RelayerCallbacks, type RelayerConfig, RelayerError, type RelayerErrorResponse, type RelayerMetrics, type RelayerQueueInfo, type RelayerRequestOptions, type RelayerStatus, type RelayerStorageResponse, type RelayerStoreParams, type RelayerSubmitParams, type RelayerTransactionResponse, type RelayerTransactionStatus, type RelayerWebhookConfig, type RelayerWebhookPayload, type ReplicateAPIResponse, type ReplicateStatus, type Repository, type RequestOptions, type RequireKeys, type RequiredExcept, type RetryConfig, RetryUtility, type RevokePermissionInput, type RevokePermissionParams, type RuntimeConfig, type Schema, type SchemaMetadata, SchemaValidationError, SchemaValidator, SerializationError, type Server, type components as ServerComponents, ServerController, type $defs as ServerDefs, type ServerFilesAndPermissionParams, type ServerFilesAndPermissionTypedData, type ServerInfo, type operations as ServerOperations, type paths as ServerPaths, type ServerTrustStatus, ServerUrlMismatchError, type webhooks as ServerWebhooks, type Service, SignatureCache, SignatureError, type SimplifiedPermissionMessage, type StateMachine, type StatusInfo, type StorageCallbacks, type StorageConfig, type StorageDownloadOptions, StorageError, type StorageFile, type StorageListOptions, type StorageListResult, StorageManager, type StorageProvider, type StorageProviderConfig, type StorageRequiredMarker, type StorageUploadResult, type TimeRange, TransactionHandle, type TransactionOptions, type TransactionReceipt, type Transformer, type TrustServerInput, type TrustServerParams, type TrustServerTypedData, type TrustedServer, type TrustedServerInfo, type TrustedServerQueryOptions, type UnencryptedUploadParams, type UntrustServerInput, type UntrustServerParams, type UntrustServerTypedData, type UpdateSchemaIdParams, type UpdateSchemaIdResult, type UploadEncryptedFileResult, type UploadFileParams, type UploadFileResult, type UploadParams, type UploadProgress, type UploadResult, type UserFile, UserRejectedRequestError, type ValidationErrorResponse, type ValidationResult, type Validator, Vana, VanaBrowserImpl, type VanaChain, type VanaChainConfig, type VanaChainId, type VanaConfig, type VanaConfigWithStorage, type VanaContract, type VanaContract as VanaContractAbi, type VanaContractInstance, type VanaContractName, VanaCore, VanaCoreFactory, VanaError, type VanaInstance, type VanaPlatformAdapter, type WalletConfig, type WalletConfigWithStorage, __contractCache, chains, checkGrantAccess, clearContractCache, type components, convertIpfsUrl, convertIpfsUrlWithFallbacks, createAndStoreGrant, createBrowserPlatformAdapter, createGrantFile, createPlatformAdapterSafe, createValidatedGrant, decryptBlobWithSignedKey, decryptWithPrivateKey, decryptWithWalletPrivateKey, Vana as default, detectPlatform, encryptBlobWithSignedKey, encryptFileKey, encryptWithWalletPublicKey, extractIpfsHash, fetchAndValidateSchema, fetchWithFallbacks, formatEth, formatNumber, formatToken, generateEncryptionKey, generateEncryptionKeyPair, generatePGPKeyPair, getAbi, getAllChains, getChainConfig, getContractAddress, getContractController, getContractInfo, getEncryptionParameters, getGatewayUrls, getGrantFileHash, getGrantTimeRemaining, getPlatformCapabilities, hasStorageConfig, isAPIResponse, isChainConfig, isGrantExpired, isIpfsUrl, isPlatformSupported, isReplicateAPIResponse, isVanaChain, isVanaChainId, isWalletConfig, moksha, mokshaTestnet, type operations, parseReplicateOutput, type paths, retrieveAndValidateGrant, retrieveGrantFile, safeParseJSON, schemaValidator, shortenAddress, storeGrantFile, summarizeGrant, validateDataAgainstSchema, validateDataSchemaAgainstMetaSchema, validateGrant, validateGrantExpiry, validateGrantFile, validateGranteeAccess, validateOperationAccess, vanaMainnet, type webhooks, withSignatureCache };
|
|
37890
|
+
export { type $defs, type APIResponse, type AddAndTrustServerInput, type AddAndTrustServerParams, type AddAndTrustServerTypedData, type AddRefinerParams, type AddRefinerResult, type AddSchemaParams, type AddSchemaResult, type AllKeys, ApiClient, type ApiClientConfig, type ApiResponse, AsyncQueue, type AsyncResult, type AuthenticationErrorResponse, type Awaited, type BaseConfig, type BaseConfigWithStorage, BaseController, type BatchServerInfoResult, type BatchUploadParams, type BatchUploadResult, type BlockRange, BlockchainError, type BlockchainErrorResponse, type Brand, BrowserPlatformAdapter, type Cache, type CacheConfig, CallbackStorage, type ChainConfig, type ChainConfigWithStorage, type CheckPermissionParams, CircuitBreaker, type CompleteSchema, type ComputeErrorResponse, type ConditionalOptional, type ConfigValidationOptions, type ConfigValidationResult, type ContractAddresses, type ContractCall, type ContractDeployment, ContractFactory, type ContractInfo, type ContractMethodParams, type ContractMethodReturnType, ContractNotFoundError, type Controller, type ControllerContext, type CreateOperationParams, type CreateOperationRequest, type CreateOperationResponse, type CreateSchemaParams, type CreateSchemaResult, DEFAULT_ENCRYPTION_SEED, DEFAULT_IPFS_GATEWAY, DataController, type DataSchema, type DecryptionErrorResponse, type DeepPartial, type DeepReadonly, type DeleteFileParams, type DeleteFileResult, type DownloadFileParams, type DownloadFileResult, type DownloadRelayerCallbacks, type EncryptedUploadParams, type EncryptionInfo, type ErrorResponse, EventEmitter, type EventFilter, type EventLog, type Factory, type FileAccessErrorResponse, type FileAccessPermissions, type FileMetadata, type FilePermissionParams, type FileSharingConfig, type GasEstimate, type GenericRequest, type GenericResponse, type GenericTypedData, type GetFileParams, type GetOperationResponse, type GetUserFilesParams, type GetUserPermissionsOptions, type GetUserTrustedServersParams, GoogleDriveStorage, GrantExpiredError, type GrantFile, type GrantPermissionParams, GrantSchemaError, GrantValidationError, type GrantValidationErrorResponse, type GrantValidationOptions, type GrantValidationResult, type GrantedPermission, type Grantee, type GranteeInfo, GranteeMismatchError, type GranteeQueryOptions, type HttpMethod, IPFS_GATEWAYS, type IdentityResponseModel, type InitPersonalServerParams, type InternalServerErrorResponse, InvalidConfigurationError, IpfsStorage, type LegacyPermissionParams, type MaybeArray, type MaybePromise, MemoryCache, type Middleware, MiddlewarePipeline, NetworkError, type NetworkInfo, type Nominal, type NonNullable, NonceError, type NotFoundErrorResponse, type Observable, type Observer, type OmitByType, type OnChainPermissionGrant, type OperationErrorResponse, OperationNotAllowedError, type OptionalKeys, type PaginatedGrantees, type PaginatedTrustedServers, type PaginationParams, type PaginationResult, type PartialExcept, type Permission, type PermissionAnalytics, type PermissionCheckResult, PermissionError, type PermissionEvent, type PermissionGrantDomain, type PermissionGrantMessage, type PermissionGrantTypedData, type PermissionInfo, type PermissionInputMessage, type PermissionOperation, type PermissionQueryResult, type PermissionStatus, PermissionsController, PersonalServerError, type PersonalServerIdentity, type PersonalServerModel, type PickByType, type PinataListResponse, type PinataPin, PinataStorage, type PinataUploadResponse, type Plugin, type PostRequestParams, type PromiseResult, ProtocolController, type QueryPermissionsParams, type RateLimitInfo, RateLimiter, type RateLimiterConfig, type Refiner, type RegisterGranteeInput, type RegisterGranteeParams, type RegisterGranteeTypedData, type RelayerCallbacks, type RelayerConfig, RelayerError, type RelayerErrorResponse, type RelayerMetrics, type RelayerQueueInfo, type RelayerRequestOptions, type RelayerStatus, type RelayerStorageResponse, type RelayerStoreParams, type RelayerSubmitParams, type RelayerTransactionResponse, type RelayerTransactionStatus, type RelayerWebhookConfig, type RelayerWebhookPayload, type ReplicateAPIResponse, type ReplicateStatus, type Repository, type RequestOptions, type RequireKeys, type RequiredExcept, type RetryConfig, RetryUtility, type RevokePermissionInput, type RevokePermissionParams, type RevokePermissionTypedData, type RuntimeConfig, type Schema, type SchemaMetadata, SchemaValidationError, SchemaValidator, SerializationError, type Server, type components as ServerComponents, ServerController, type $defs as ServerDefs, type ServerFilesAndPermissionParams, type ServerFilesAndPermissionTypedData, type ServerInfo, type operations as ServerOperations, type paths as ServerPaths, type ServerTrustStatus, ServerUrlMismatchError, type webhooks as ServerWebhooks, type Service, SignatureCache, SignatureError, type SimplifiedPermissionMessage, type SpecificTypedData, type StateMachine, type StatusInfo, type StorageCallbacks, type StorageConfig, type StorageDownloadOptions, StorageError, type StorageFile, type StorageListOptions, type StorageListResult, StorageManager, type StorageProvider, type StorageProviderConfig, type StorageRequiredMarker, type StorageUploadResult, type TimeRange, TransactionHandle, type TransactionOptions, type TransactionReceipt, type Transformer, type TrustServerInput, type TrustServerParams, type TrustServerTypedData, type TrustedServer, type TrustedServerInfo, type TrustedServerQueryOptions, type TypedDataPrimaryType, type UnencryptedUploadParams, type UntrustServerInput, type UntrustServerParams, type UntrustServerTypedData, type UpdateSchemaIdParams, type UpdateSchemaIdResult, type UploadEncryptedFileResult, type UploadFileParams, type UploadFileResult, type UploadParams, type UploadProgress, type UploadResult, type UserFile, UserRejectedRequestError, type ValidationErrorResponse, type ValidationResult, type Validator, Vana, VanaBrowserImpl, type VanaChain, type VanaChainConfig, type VanaChainId, type VanaConfig, type VanaConfigWithStorage, type VanaContract, type VanaContract as VanaContractAbi, type VanaContractInstance, type VanaContractName, VanaCore, VanaCoreFactory, VanaError, type VanaInstance, type VanaPlatformAdapter, type WalletConfig, type WalletConfigWithStorage, __contractCache, chains, checkGrantAccess, clearContractCache, type components, convertIpfsUrl, convertIpfsUrlWithFallbacks, createAndStoreGrant, createBrowserPlatformAdapter, createGrantFile, createPlatformAdapterSafe, createValidatedGrant, decryptBlobWithSignedKey, decryptWithPrivateKey, decryptWithWalletPrivateKey, Vana as default, detectPlatform, encryptBlobWithSignedKey, encryptFileKey, encryptWithWalletPublicKey, extractIpfsHash, fetchAndValidateSchema, fetchWithFallbacks, formatEth, formatNumber, formatToken, generateEncryptionKey, generateEncryptionKeyPair, generatePGPKeyPair, getAbi, getAllChains, getChainConfig, getContractAddress, getContractController, getContractInfo, getEncryptionParameters, getGatewayUrls, getGrantFileHash, getGrantTimeRemaining, getPlatformCapabilities, hasStorageConfig, isAPIResponse, isChainConfig, isGrantExpired, isIpfsUrl, isPlatformSupported, isReplicateAPIResponse, isVanaChain, isVanaChainId, isWalletConfig, moksha, mokshaTestnet, type operations, parseReplicateOutput, type paths, retrieveAndValidateGrant, retrieveGrantFile, safeParseJSON, schemaValidator, shortenAddress, storeGrantFile, summarizeGrant, validateDataAgainstSchema, validateDataSchemaAgainstMetaSchema, validateGrant, validateGrantExpiry, validateGrantFile, validateGranteeAccess, validateOperationAccess, vanaMainnet, type webhooks, withSignatureCache };
|