diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock
index 619d731f..2311967c 100644
--- a/.speakeasy/workflow.lock
+++ b/.speakeasy/workflow.lock
@@ -6,6 +6,7 @@ sources:
sourceBlobDigest: sha256:214dff750535e03d96c20a978cfa47a413d04c88d47f996ae148473b45c669df
tags:
- latest
+ - speakeasy-sdk-regen-1754688739
- 1.0.0
targets:
chainkit-sdk:
@@ -14,7 +15,7 @@ targets:
sourceRevisionDigest: sha256:9c3c1c9bededfb64c85c874865db9b8bf4621b0aa65f9a5bf4abababe387ec24
sourceBlobDigest: sha256:214dff750535e03d96c20a978cfa47a413d04c88d47f996ae148473b45c669df
codeSamplesNamespace: avalanche-sdk-chainkit-typescript-code-samples
- codeSamplesRevisionDigest: sha256:a51e4cdad495293f61143fc8c375227f127fe8e92affcfd273ac63428a4e78a7
+ codeSamplesRevisionDigest: sha256:bb21ba3c1307f07386c62ba2ec0d0dfa7b29f2489a9843810c4405fd72a50890
workflow:
workflowVersion: 1.0.0
speakeasyVersion: latest
diff --git a/chainkit/.devcontainer/README.md b/chainkit/.devcontainer/README.md
deleted file mode 100644
index 96e8024b..00000000
--- a/chainkit/.devcontainer/README.md
+++ /dev/null
@@ -1,35 +0,0 @@
-
-
-

-
-
-
-> **Remember to shutdown a GitHub Codespace when it is not in use!**
-
-# Dev Containers Quick Start
-
-The default location for usage snippets is the `samples` directory.
-
-## Running a Usage Sample
-
-A sample usage example has been provided in a `root.ts` file. As you work with the SDK, it's expected that you will modify these samples to fit your needs. To execute this particular snippet, use the command below.
-
-```
-ts-node root.ts
-```
-
-## Generating Additional Usage Samples
-
-The speakeasy CLI allows you to generate more usage snippets. Here's how:
-
-- To generate a sample for a specific operation by providing an operation ID, use:
-
-```
-speakeasy generate usage -s https://glacier-api.avax.network/api-json -l typescript -i {INPUT_OPERATION_ID} -o ./samples
-```
-
-- To generate samples for an entire namespace (like a tag or group name), use:
-
-```
-speakeasy generate usage -s https://glacier-api.avax.network/api-json -l typescript -n {INPUT_TAG_NAME} -o ./samples
-```
diff --git a/chainkit/.devcontainer/devcontainer.json b/chainkit/.devcontainer/devcontainer.json
deleted file mode 100644
index 4d560dd5..00000000
--- a/chainkit/.devcontainer/devcontainer.json
+++ /dev/null
@@ -1,45 +0,0 @@
-// For format details, see https://aka.ms/devcontainer.json. For config options, see the
-// README at: https://github.com/devcontainers/images/tree/main/src/typescript-node
-{
- "name": "TypeScript",
- "image": "mcr.microsoft.com/devcontainers/typescript-node:1-20-bullseye",
- // Features to add to the dev container. More info: https://containers.dev/features.
- // "features": {},
- // Use 'forwardPorts' to make a list of ports inside the container available locally.
- // "forwardPorts": [],
- // Use 'postCreateCommand' to run commands after the container is created.
- "postCreateCommand": "sudo chmod +x ./.devcontainer/setup.sh && ./.devcontainer/setup.sh",
- "customizations": {
- "vscode": {
- "extensions": [
- "ms-vscode.vscode-typescript-tslint-plugin",
- "esbenp.prettier-vscode",
- "github.vscode-pull-request-github"
- ],
- "settings": {
- "files.eol": "\n",
- "editor.formatOnSave": true,
- "typescript.tsc.autoDetect": "on",
- "typescript.updateImportsOnFileMove.enabled": "always",
- "typescript.preferences.importModuleSpecifier": "relative",
- "[typescript]": {
- "editor.codeActionsOnSave": {
- "source.organizeImports": true
- }
- },
- "[typescriptreact]": {
- "editor.codeActionsOnSave": {
- "source.organizeImports": true
- }
- }
- }
- },
- "codespaces": {
- "openFiles": [
- ".devcontainer/README.md"
- ]
- }
- }
- // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
- // "remoteUser": "root"
-}
diff --git a/chainkit/.devcontainer/setup.sh b/chainkit/.devcontainer/setup.sh
deleted file mode 100644
index 020480c4..00000000
--- a/chainkit/.devcontainer/setup.sh
+++ /dev/null
@@ -1,30 +0,0 @@
-#!/bin/bash
-
-# Install the speakeasy CLI
-curl -fsSL https://raw.githubusercontent.com/speakeasy-api/speakeasy/main/install.sh | sh
-
-# Setup samples directory
-rmdir samples || true
-mkdir samples
-
-npm install
-npm install -g ts-node
-npm link
-npm link @avalanche-sdk/chainkit
-TS_CONFIG_CONTENT=$(cat < samples/tsconfig.json
-
-# Generate starter usage sample with speakeasy
-speakeasy generate usage -s https://glacier-api.avax.network/api-json -l typescript -o samples/root.ts
\ No newline at end of file
diff --git a/chainkit/.speakeasy/gen.lock b/chainkit/.speakeasy/gen.lock
index e6360498..2e7e5a10 100644
--- a/chainkit/.speakeasy/gen.lock
+++ b/chainkit/.speakeasy/gen.lock
@@ -5,11 +5,11 @@ management:
docVersion: 1.0.0
speakeasyVersion: 1.600.2
generationVersion: 2.677.3
- releaseVersion: 0.2.3
- configChecksum: 17821f6f8da51541fa40b0c3ad0ae389
+ releaseVersion: 0.3.0
+ configChecksum: 0f5dbd2c664cdc0e971d8c6d0d7e8fa9
repoURL: https://github.com/ava-labs/avalanche-sdk-typescript.git
- repoSubDirectory: devtools
- installationURL: https://gitpkg.now.sh/ava-labs/avalanche-sdk-typescript/devtools
+ repoSubDirectory: chainkit
+ installationURL: https://gitpkg.now.sh/ava-labs/avalanche-sdk-typescript/chainkit
published: true
features:
typescript:
@@ -18,7 +18,6 @@ features:
core: 3.21.20
defaultEnabledRetries: 0.1.0
deprecations: 2.81.1
- devContainers: 2.90.0
enumUnions: 0.1.0
envVarSecurityUsage: 0.1.2
examples: 2.82.2
@@ -40,9 +39,6 @@ features:
unions: 2.85.11
webhooks: 1.5.0
generatedFiles:
- - .devcontainer/README.md
- - .devcontainer/devcontainer.json
- - .devcontainer/setup.sh
- .gitattributes
- .npmignore
- FUNCTIONS.md
diff --git a/chainkit/.speakeasy/gen.yaml b/chainkit/.speakeasy/gen.yaml
index 58476882..70f87c50 100644
--- a/chainkit/.speakeasy/gen.yaml
+++ b/chainkit/.speakeasy/gen.yaml
@@ -21,7 +21,7 @@ generation:
generateNewTests: false
skipResponseBodyAssertions: false
typescript:
- version: 0.2.3
+ version: 0.3.0
additionalDependencies:
dependencies:
json-canonicalize: ^1.0.6
diff --git a/chainkit/README.md b/chainkit/README.md
index db2fcb2e..9e0cebde 100644
--- a/chainkit/README.md
+++ b/chainkit/README.md
@@ -12,32 +12,27 @@
-
## Summary
Data, Metrics, and Webhooks API: The Avalanche API suite offers powerful tools for real-time and historical blockchain data. The Webhooks API enables instant monitoring of on-chain events, including smart contract activity, NFT transfers, and wallet transactions, with customizable filters and secure notifications. The Metrics API (Beta) provides analytics on blockchain activity, while the Data API (Beta) delivers multi-chain data for Avalanche and Ethereum, including transaction history, token balances, and metadata. These APIs empower developers to build dynamic web3 applications with real-time insights and seamless integration.
-
-
## Table of Contents
-
-
-* [SDK Installation](#sdk-installation)
-* [Requirements](#requirements)
-* [SDK Example Usage](#sdk-example-usage)
-* [Authentication](#authentication)
-* [Available Resources and Operations](#available-resources-and-operations)
-* [Standalone functions](#standalone-functions)
-* [Global Parameters](#global-parameters)
-* [Pagination](#pagination)
-* [Retries](#retries)
-* [Error Handling](#error-handling)
-* [Server Selection](#server-selection)
-* [Custom HTTP Client](#custom-http-client)
-* [Debugging](#debugging)
+ * [SDK Installation](#sdk-installation)
+ * [Requirements](#requirements)
+ * [SDK Example Usage](#sdk-example-usage)
+ * [Authentication](#authentication)
+ * [Available Resources and Operations](#available-resources-and-operations)
+ * [Standalone functions](#standalone-functions)
+ * [Global Parameters](#global-parameters)
+ * [Pagination](#pagination)
+ * [Retries](#retries)
+ * [Error Handling](#error-handling)
+ * [Server Selection](#server-selection)
+ * [Custom HTTP Client](#custom-http-client)
+ * [Debugging](#debugging)
* [Development](#development)
* [Maturity](#maturity)
* [Contributions](#contributions)
@@ -45,7 +40,6 @@ Data, Metrics, and Webhooks API: The Avalanche API suite offers powerful tools f
-
## SDK Installation
The SDK can be installed with either [npm](https://www.npmjs.com/), [pnpm](https://pnpm.io/), [bun](https://bun.sh/) or [yarn](https://classic.yarnpkg.com/en/) package managers.
@@ -80,6 +74,7 @@ yarn add @avalanche-sdk/chainkit zod
> [!NOTE]
> This package is published with CommonJS and ES Modules (ESM) support.
+
### Model Context Protocol (MCP) Server
This SDK is also an installable MCP server where the various SDK methods are
@@ -147,6 +142,7 @@ chmod +x mcp-server
If the repo is a private repo you must add your Github PAT to download a release `-H "Authorization: Bearer {GITHUB_PAT}"`.
+
```json
{
"mcpServers": {
@@ -165,19 +161,15 @@ For a full list of server arguments, run:
```sh
npx -y --package @avalanche-sdk/chainkit -- mcp start --help
```
-
-
## Requirements
For supported JavaScript runtimes, please consult [RUNTIMES.md](RUNTIMES.md).
-
-
## SDK Example Usage
### Example
@@ -208,23 +200,20 @@ async function run() {
run();
```
-
-
## Authentication
### Per-Client Security Schemes
This SDK supports the following security scheme globally:
-| Name | Type | Scheme |
-| ---------- | ------ | ------- |
+| Name | Type | Scheme |
+| -------- | ------ | ------- |
| `apiKey` | apiKey | API key |
To authenticate with the API the `apiKey` parameter must be set when initializing the SDK client instance. For example:
-
```typescript
import { Avalanche } from "@avalanche-sdk/chainkit";
@@ -241,16 +230,15 @@ async function run() {
run();
```
-
-
## Available Resources and Operations
Available methods
+
### [data](docs/sdks/data/README.md)
* [healthCheck](docs/sdks/data/README.md#healthcheck) - Get the health of the service
@@ -293,15 +281,13 @@ run();
* [get](docs/sdks/evmchains/README.md#get) - Get chain information
* [~~getAddressChains~~](docs/sdks/evmchains/README.md#getaddresschains) - **[Deprecated]** Gets a list of all chains where the address was either a sender or receiver in a transaction or ERC transfer. The list is currently updated every 15 minutes.
-⚠️ **This operation will be removed in a future release. Please use /v1/address/:address/chains endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/address/:address/chains endpoint instead** . :warning: **Deprecated**
* [~~listAllLatestTransactions~~](docs/sdks/evmchains/README.md#listalllatesttransactions) - **[Deprecated]** Lists the latest transactions for all supported EVM chains. Filterable by status.
-⚠️ **This operation will be removed in a future release. Please use /v1/transactions endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/transactions endpoint instead** . :warning: **Deprecated**
* [~~listAllLatestBlocks~~](docs/sdks/evmchains/README.md#listalllatestblocks) - **[Deprecated]** Lists the latest blocks for all supported EVM chains. Filterable by network.
-⚠️ **This operation will be removed in a future release. Please use /v1/blocks endpoint instead** . ⚠️ **Deprecated**
+⚠️ **This operation will be removed in a future release. Please use /v1/blocks endpoint instead** . :warning: **Deprecated**
#### [data.evm.contracts](docs/sdks/contracts/README.md)
@@ -387,15 +373,13 @@ run();
* [~~getTeleporterMessage~~](docs/sdks/teleporter/README.md#getteleportermessage) - **[Deprecated]** Gets a teleporter message by message ID.
-⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages/:messageId endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages/:messageId endpoint instead** . :warning: **Deprecated**
* [~~listTeleporterMessages~~](docs/sdks/teleporter/README.md#listteleportermessages) - **[Deprecated]** Lists teleporter messages. Ordered by timestamp in descending order.
-⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages endpoint instead** . :warning: **Deprecated**
* [~~listTeleporterMessagesByAddress~~](docs/sdks/teleporter/README.md#listteleportermessagesbyaddress) - **[Deprecated]** Lists teleporter messages by address. Ordered by timestamp in descending order.
-⚠️ **This operation will be removed in a future release. Please use /v1/icm/addresses/:address/messages endpoint instead** . ⚠️ **Deprecated**
+⚠️ **This operation will be removed in a future release. Please use /v1/icm/addresses/:address/messages endpoint instead** . :warning: **Deprecated**
#### [data.usageMetrics](docs/sdks/usagemetrics/README.md)
@@ -404,7 +388,7 @@ run();
* [getSubnetRpcUsage](docs/sdks/usagemetrics/README.md#getsubnetrpcusage) - Get usage metrics for the Subnet RPC
* [~~getRpcUsageMetrics~~](docs/sdks/usagemetrics/README.md#getrpcusagemetrics) - **[Deprecated]** Gets metrics for public Subnet RPC usage over a specified time interval aggregated at the specified time-duration granularity.
-⚠️ **This operation will be removed in a future release. Please use /v1/subnetRpcUsageMetrics endpoint instead**. ⚠️ **Deprecated**
+⚠️ **This operation will be removed in a future release. Please use /v1/subnetRpcUsageMetrics endpoint instead**. :warning: **Deprecated**
### [metrics](docs/sdks/metrics/README.md)
@@ -456,7 +440,6 @@ run();
-
## Standalone functions
All the methods listed above are available as standalone functions. These
@@ -562,43 +545,37 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
- [`webhooksUpdate`](docs/sdks/webhooks/README.md#update) - Update a webhook
- ~~[`dataEvmChainsGetAddressChains`](docs/sdks/evmchains/README.md#getaddresschains)~~ - **[Deprecated]** Gets a list of all chains where the address was either a sender or receiver in a transaction or ERC transfer. The list is currently updated every 15 minutes.
-⚠️ **This operation will be removed in a future release. Please use /v1/address/:address/chains endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/address/:address/chains endpoint instead** . :warning: **Deprecated**
- ~~[`dataEvmChainsListAllLatestBlocks`](docs/sdks/evmchains/README.md#listalllatestblocks)~~ - **[Deprecated]** Lists the latest blocks for all supported EVM chains. Filterable by network.
-⚠️ **This operation will be removed in a future release. Please use /v1/blocks endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/blocks endpoint instead** . :warning: **Deprecated**
- ~~[`dataEvmChainsListAllLatestTransactions`](docs/sdks/evmchains/README.md#listalllatesttransactions)~~ - **[Deprecated]** Lists the latest transactions for all supported EVM chains. Filterable by status.
-⚠️ **This operation will be removed in a future release. Please use /v1/transactions endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/transactions endpoint instead** . :warning: **Deprecated**
- ~~[`dataTeleporterGetTeleporterMessage`](docs/sdks/teleporter/README.md#getteleportermessage)~~ - **[Deprecated]** Gets a teleporter message by message ID.
-⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages/:messageId endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages/:messageId endpoint instead** . :warning: **Deprecated**
- ~~[`dataTeleporterListTeleporterMessages`](docs/sdks/teleporter/README.md#listteleportermessages)~~ - **[Deprecated]** Lists teleporter messages. Ordered by timestamp in descending order.
-⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/icm/messages endpoint instead** . :warning: **Deprecated**
- ~~[`dataTeleporterListTeleporterMessagesByAddress`](docs/sdks/teleporter/README.md#listteleportermessagesbyaddress)~~ - **[Deprecated]** Lists teleporter messages by address. Ordered by timestamp in descending order.
-⚠️ **This operation will be removed in a future release. Please use /v1/icm/addresses/:address/messages endpoint instead** . ⚠️ **Deprecated**
-
+⚠️ **This operation will be removed in a future release. Please use /v1/icm/addresses/:address/messages endpoint instead** . :warning: **Deprecated**
- ~~[`dataUsageMetricsGetRpcUsageMetrics`](docs/sdks/usagemetrics/README.md#getrpcusagemetrics)~~ - **[Deprecated]** Gets metrics for public Subnet RPC usage over a specified time interval aggregated at the specified time-duration granularity.
-⚠️ **This operation will be removed in a future release. Please use /v1/subnetRpcUsageMetrics endpoint instead**. ⚠️ **Deprecated**
+⚠️ **This operation will be removed in a future release. Please use /v1/subnetRpcUsageMetrics endpoint instead**. :warning: **Deprecated**
-
## Global Parameters
Certain parameters are configured globally. These parameters may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, These global values will be used as defaults on the operations that use them. When such operations are called, there is a place in each to override the global value, if needed.
For example, you can set `chainId` to `"43114"` at SDK initialization and then you do not have to pass the same value on calls to operations like `list`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.
+
### Available Globals
The following global parameters are available.
@@ -631,18 +608,18 @@ async function run() {
run();
```
-
-
## Pagination
Some of the endpoints in this SDK support pagination. To use pagination, you
make your SDK calls as usual, but the returned response object will also be an
-async iterable that can be consumed using the
+async iterable that can be consumed using the [`for await...of`][for-await-of]
syntax.
+[for-await-of]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of
+
Here's an example of one such pagination call:
```typescript
@@ -663,17 +640,14 @@ async function run() {
run();
```
-
-
## Retries
Some of the endpoints in this SDK support retries. If you use the SDK without any configuration, it will fall back to the default retry strategy provided by the API. However, the default retry strategy can be overridden on a per-operation basis, or across the entire SDK.
To change the default retry strategy for a single API call, simply provide a retryConfig object to the call:
-
```typescript
import { Avalanche } from "@avalanche-sdk/chainkit";
@@ -701,7 +675,6 @@ run();
```
If you'd like to override the default retry strategy for all operations that support retries, you can provide a retryConfig at SDK initialization:
-
```typescript
import { Avalanche } from "@avalanche-sdk/chainkit";
@@ -727,26 +700,23 @@ async function run() {
run();
```
-
-
## Error Handling
[`AvalancheError`](./src/models/errors/avalancheerror.ts) is the base class for all HTTP error responses. It has the following properties:
-| Property | Type | Description |
-| --------------------- | ------------ | ----------------------------------------------------------------------------------- |
-| `error.message` | `string` | Error message |
-| `error.statusCode` | `number` | HTTP response status code eg `404` |
-| `error.headers` | `Headers` | HTTP response headers |
-| `error.body` | `string` | HTTP body. Can be empty string if no body is returned. |
-| `error.rawResponse` | `Response` | Raw HTTP response |
-| `error.data$` | | Optional. Some errors may contain structured data.[See Error Classes](#error-classes). |
+| Property | Type | Description |
+| ------------------- | ---------- | --------------------------------------------------------------------------------------- |
+| `error.message` | `string` | Error message |
+| `error.statusCode` | `number` | HTTP response status code eg `404` |
+| `error.headers` | `Headers` | HTTP response headers |
+| `error.body` | `string` | HTTP body. Can be empty string if no body is returned. |
+| `error.rawResponse` | `Response` | Raw HTTP response |
+| `error.data$` | | Optional. Some errors may contain structured data. [See Error Classes](#error-classes). |
### Example
-
```typescript
import { Avalanche } from "@avalanche-sdk/chainkit";
import * as errors from "@avalanche-sdk/chainkit/models/errors";
@@ -784,9 +754,7 @@ run();
```
### Error Classes
-
**Primary errors:**
-
* [`AvalancheError`](./src/models/errors/avalancheerror.ts): The base class for HTTP error responses.
* [`BadRequestError`](./src/models/errors/badrequesterror.ts): Bad requests generally mean the client has passed invalid or malformed parameters. Error messages in the response could help in evaluating the error. Status code `400`.
* [`UnauthorizedError`](./src/models/errors/unauthorizederror.ts): When a client attempts to access resources that require authorization credentials but the client lacks proper authentication in the request, the server responds with 401. Status code `401`.
@@ -802,28 +770,25 @@ run();
**Network errors:**
-
* [`ConnectionError`](./src/models/errors/httpclienterrors.ts): HTTP client was unable to make a request to a server.
* [`RequestTimeoutError`](./src/models/errors/httpclienterrors.ts): HTTP request timed out due to an AbortSignal signal.
* [`RequestAbortedError`](./src/models/errors/httpclienterrors.ts): HTTP request was aborted by the client.
* [`InvalidRequestError`](./src/models/errors/httpclienterrors.ts): Any input used to create a request is invalid.
* [`UnexpectedClientError`](./src/models/errors/httpclienterrors.ts): Unrecognised or unexpected error.
-**Inherit from [`AvalancheError`](./src/models/errors/avalancheerror.ts)**:
+**Inherit from [`AvalancheError`](./src/models/errors/avalancheerror.ts)**:
* [`ResponseValidationError`](./src/models/errors/responsevalidationerror.ts): Type mismatch between the data returned from the server and the structure expected by the SDK. See `error.rawValue` for the raw value and `error.pretty()` for a nicely formatted multi-line string.
-
## Server Selection
### Override Server URL Per-Client
The default server can be overridden globally by passing a URL to the `serverURL: string` optional parameter when initializing the SDK client instance. For example:
-
```typescript
import { Avalanche } from "@avalanche-sdk/chainkit";
@@ -844,7 +809,6 @@ run();
### Override Server URL Per-Operation
The server URL can also be overridden on a per-operation basis, provided a server list was specified for the operation. For example:
-
```typescript
import { Avalanche } from "@avalanche-sdk/chainkit";
@@ -861,11 +825,9 @@ async function run() {
run();
```
-
-
## Custom HTTP Client
The TypeScript SDK makes API calls using an `HTTPClient` that wraps the native
@@ -912,11 +874,9 @@ httpClient.addHook("requestError", (error, request) => {
const sdk = new Avalanche({ httpClient });
```
-
-
## Debugging
You can setup your SDK to emit debug logs for SDK requests and responses.
@@ -931,7 +891,6 @@ import { Avalanche } from "@avalanche-sdk/chainkit";
const sdk = new Avalanche({ debugLogger: console });
```
-
diff --git a/chainkit/RELEASES.md b/chainkit/RELEASES.md
index 8b137891..6f48885f 100644
--- a/chainkit/RELEASES.md
+++ b/chainkit/RELEASES.md
@@ -1 +1,12 @@
+
+
+## 2025-08-08 21:32:00
+### Changes
+Based on:
+- OpenAPI Doc
+- Speakeasy CLI 1.600.2 (2.677.3) https://github.com/speakeasy-api/speakeasy
+### Generated
+- [typescript v0.3.0] chainkit
+### Releases
+- [NPM v0.3.0] https://www.npmjs.com/package/@avalanche-sdk/chainkit/v/0.3.0 - chainkit
\ No newline at end of file
diff --git a/chainkit/docs/models/components/contract.md b/chainkit/docs/models/components/contract.md
index efd6a4e8..646e2e27 100644
--- a/chainkit/docs/models/components/contract.md
+++ b/chainkit/docs/models/components/contract.md
@@ -3,37 +3,37 @@
## Supported Types
-### `components.Erc20Contract`
+### `components.Erc721Contract`
```typescript
-const value: components.Erc20Contract = {
+const value: components.Erc721Contract = {
name: "Wrapped AVAX",
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
- ercType: "ERC-20",
+ ercType: "ERC-721",
symbol: "WAVAX",
- decimals: 18,
};
```
-### `components.Erc721Contract`
+### `components.Erc1155Contract`
```typescript
-const value: components.Erc721Contract = {
+const value: components.Erc1155Contract = {
name: "Wrapped AVAX",
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
- ercType: "ERC-721",
+ ercType: "ERC-1155",
symbol: "WAVAX",
};
```
-### `components.Erc1155Contract`
+### `components.Erc20Contract`
```typescript
-const value: components.Erc1155Contract = {
+const value: components.Erc20Contract = {
name: "Wrapped AVAX",
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
- ercType: "ERC-1155",
+ ercType: "ERC-20",
symbol: "WAVAX",
+ decimals: 18,
};
```
diff --git a/chainkit/docs/models/components/listicmmessagesresponsemessage.md b/chainkit/docs/models/components/listicmmessagesresponsemessage.md
index af41e97f..a3b31c6b 100644
--- a/chainkit/docs/models/components/listicmmessagesresponsemessage.md
+++ b/chainkit/docs/models/components/listicmmessagesresponsemessage.md
@@ -3,10 +3,10 @@
## Supported Types
-### `components.PendingIcmMessage`
+### `components.DeliveredIcmMessage`
```typescript
-const value: components.PendingIcmMessage = {
+const value: components.DeliveredIcmMessage = {
messageId: "",
icmContractAddress: "",
sourceBlockchainId: "",
@@ -16,9 +16,9 @@ const value: components.PendingIcmMessage = {
messageNonce: "",
from: "",
to: "",
- messageExecuted: false,
+ messageExecuted: true,
receipts: [],
- receiptDelivered: false,
+ receiptDelivered: true,
rewardDetails: {
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
name: "Wrapped AVAX",
@@ -38,14 +38,21 @@ const value: components.PendingIcmMessage = {
timestamp: 6459.73,
gasSpent: "",
},
- status: "pending",
+ destinationTransaction: {
+ txHash: "",
+ timestamp: 8250.11,
+ gasSpent: "",
+ rewardRedeemer: "",
+ delivererAddress: "",
+ },
+ status: "delivered",
};
```
-### `components.DeliveredIcmMessage`
+### `components.PendingIcmMessage`
```typescript
-const value: components.DeliveredIcmMessage = {
+const value: components.PendingIcmMessage = {
messageId: "",
icmContractAddress: "",
sourceBlockchainId: "",
@@ -55,9 +62,9 @@ const value: components.DeliveredIcmMessage = {
messageNonce: "",
from: "",
to: "",
- messageExecuted: true,
+ messageExecuted: false,
receipts: [],
- receiptDelivered: true,
+ receiptDelivered: false,
rewardDetails: {
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
name: "Wrapped AVAX",
@@ -77,14 +84,7 @@ const value: components.DeliveredIcmMessage = {
timestamp: 6459.73,
gasSpent: "",
},
- destinationTransaction: {
- txHash: "",
- timestamp: 8250.11,
- gasSpent: "",
- rewardRedeemer: "",
- delivererAddress: "",
- },
- status: "delivered",
+ status: "pending",
};
```
diff --git a/chainkit/docs/models/components/listteleportermessagesresponsemessage.md b/chainkit/docs/models/components/listteleportermessagesresponsemessage.md
index b4ae0f2a..4a094612 100644
--- a/chainkit/docs/models/components/listteleportermessagesresponsemessage.md
+++ b/chainkit/docs/models/components/listteleportermessagesresponsemessage.md
@@ -3,10 +3,10 @@
## Supported Types
-### `components.DeliveredTeleporterMessage`
+### `components.PendingTeleporterMessage`
```typescript
-const value: components.DeliveredTeleporterMessage = {
+const value: components.PendingTeleporterMessage = {
messageId: "",
teleporterContractAddress: "",
sourceBlockchainId: "",
@@ -38,21 +38,14 @@ const value: components.DeliveredTeleporterMessage = {
timestamp: 1403.23,
gasSpent: "",
},
- destinationTransaction: {
- txHash: "",
- timestamp: 4770.43,
- gasSpent: "",
- rewardRedeemer: "",
- delivererAddress: "",
- },
- status: "delivered",
+ status: "pending",
};
```
-### `components.PendingTeleporterMessage`
+### `components.DeliveredTeleporterMessage`
```typescript
-const value: components.PendingTeleporterMessage = {
+const value: components.DeliveredTeleporterMessage = {
messageId: "",
teleporterContractAddress: "",
sourceBlockchainId: "",
@@ -84,7 +77,14 @@ const value: components.PendingTeleporterMessage = {
timestamp: 1403.23,
gasSpent: "",
},
- status: "pending",
+ destinationTransaction: {
+ txHash: "",
+ timestamp: 4770.43,
+ gasSpent: "",
+ rewardRedeemer: "",
+ delivererAddress: "",
+ },
+ status: "delivered",
};
```
diff --git a/chainkit/docs/models/components/validator.md b/chainkit/docs/models/components/validator.md
index 554224df..36994455 100644
--- a/chainkit/docs/models/components/validator.md
+++ b/chainkit/docs/models/components/validator.md
@@ -31,6 +31,20 @@ const value: components.ActiveValidatorDetails = {
};
```
+### `components.PendingValidatorDetails`
+
+```typescript
+const value: components.PendingValidatorDetails = {
+ txHash: "",
+ nodeId: "",
+ subnetId: "",
+ amountStaked: "",
+ startTimestamp: 9843.29,
+ endTimestamp: 5112.58,
+ validationStatus: "pending",
+};
+```
+
### `components.CompletedValidatorDetails`
```typescript
@@ -66,17 +80,3 @@ const value: components.RemovedValidatorDetails = {
};
```
-### `components.PendingValidatorDetails`
-
-```typescript
-const value: components.PendingValidatorDetails = {
- txHash: "",
- nodeId: "",
- subnetId: "",
- amountStaked: "",
- startTimestamp: 9843.29,
- endTimestamp: 5112.58,
- validationStatus: "pending",
-};
-```
-
diff --git a/chainkit/docs/models/operations/getcontractmetadataresponse.md b/chainkit/docs/models/operations/getcontractmetadataresponse.md
index e4fdbf1d..c41ce055 100644
--- a/chainkit/docs/models/operations/getcontractmetadataresponse.md
+++ b/chainkit/docs/models/operations/getcontractmetadataresponse.md
@@ -5,37 +5,37 @@ Successful response
## Supported Types
-### `components.Erc721Contract`
+### `components.Erc20Contract`
```typescript
-const value: components.Erc721Contract = {
+const value: components.Erc20Contract = {
name: "Wrapped AVAX",
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
- ercType: "ERC-721",
+ ercType: "ERC-20",
symbol: "WAVAX",
+ decimals: 18,
};
```
-### `components.Erc1155Contract`
+### `components.Erc721Contract`
```typescript
-const value: components.Erc1155Contract = {
+const value: components.Erc721Contract = {
name: "Wrapped AVAX",
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
- ercType: "ERC-1155",
+ ercType: "ERC-721",
symbol: "WAVAX",
};
```
-### `components.Erc20Contract`
+### `components.Erc1155Contract`
```typescript
-const value: components.Erc20Contract = {
+const value: components.Erc1155Contract = {
name: "Wrapped AVAX",
address: "0x71C7656EC7ab88b098defB751B7401B5f6d8976F",
- ercType: "ERC-20",
+ ercType: "ERC-1155",
symbol: "WAVAX",
- decimals: 18,
};
```
diff --git a/chainkit/examples/package-lock.json b/chainkit/examples/package-lock.json
index ea7fba20..10982b59 100644
--- a/chainkit/examples/package-lock.json
+++ b/chainkit/examples/package-lock.json
@@ -18,7 +18,7 @@
},
"..": {
"name": "@avalanche-sdk/chainkit",
- "version": "0.2.3",
+ "version": "0.3.0",
"dependencies": {
"json-canonicalize": "^1.0.6",
"zod": "^3.20.0"
diff --git a/chainkit/package-lock.json b/chainkit/package-lock.json
index ba31db09..96c0e2e2 100644
--- a/chainkit/package-lock.json
+++ b/chainkit/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "@avalanche-sdk/chainkit",
- "version": "0.2.3",
+ "version": "0.3.0",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@avalanche-sdk/chainkit",
- "version": "0.2.3",
+ "version": "0.3.0",
"dependencies": {
"json-canonicalize": "^1.0.6",
"zod": "^3.20.0"
diff --git a/chainkit/package.json b/chainkit/package.json
index b8b24824..69d8d245 100644
--- a/chainkit/package.json
+++ b/chainkit/package.json
@@ -1,6 +1,6 @@
{
"name": "@avalanche-sdk/chainkit",
- "version": "0.2.3",
+ "version": "0.3.0",
"author": "Avacloud",
"type": "module",
"bin": {
@@ -25,7 +25,7 @@
"repository": {
"type": "git",
"url": "https://github.com/ava-labs/avalanche-sdk-typescript.git",
- "directory": "devtools"
+ "directory": "chainkit"
},
"scripts": {
"lint": "eslint --cache --max-warnings=0 src",
diff --git a/chainkit/src/lib/config.ts b/chainkit/src/lib/config.ts
index b2069a23..09835f71 100644
--- a/chainkit/src/lib/config.ts
+++ b/chainkit/src/lib/config.ts
@@ -72,8 +72,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
export const SDK_METADATA = {
language: "typescript",
openapiDocVersion: "1.0.0",
- sdkVersion: "0.2.3",
+ sdkVersion: "0.3.0",
genVersion: "2.677.3",
userAgent:
- "speakeasy-sdk/typescript 0.2.3 2.677.3 1.0.0 @avalanche-sdk/chainkit",
+ "speakeasy-sdk/typescript 0.3.0 2.677.3 1.0.0 @avalanche-sdk/chainkit",
} as const;
diff --git a/chainkit/src/mcp-server/mcp-server.ts b/chainkit/src/mcp-server/mcp-server.ts
index 43776bed..a70686a7 100644
--- a/chainkit/src/mcp-server/mcp-server.ts
+++ b/chainkit/src/mcp-server/mcp-server.ts
@@ -19,7 +19,7 @@ const routes = buildRouteMap({
export const app = buildApplication(routes, {
name: "mcp",
versionInfo: {
- currentVersion: "0.2.3",
+ currentVersion: "0.3.0",
},
});
diff --git a/chainkit/src/mcp-server/server.ts b/chainkit/src/mcp-server/server.ts
index 80d61a46..3ec3186a 100644
--- a/chainkit/src/mcp-server/server.ts
+++ b/chainkit/src/mcp-server/server.ts
@@ -122,7 +122,7 @@ export function createMCPServer(deps: {
}) {
const server = new McpServer({
name: "Avalanche",
- version: "0.2.3",
+ version: "0.3.0",
});
const client = new AvalancheCore({