swagger.json


Overview

This file is an OpenAPI 3.0 specification document defining the RESTful API for the **@shapeshiftoss/ethereum-api** project (version 10.0.0). It describes the endpoints, request/response schemas, and operations for interacting with an Ethereum-compatible blockchain coinstack.

The API provides functionality for:

This specification enables client applications to interact programmatically with the Ethereum coinstack node and provides a structured, typed interface for blockchain data and transaction management.


Components

Schemas

The file defines multiple JSON schemas under [components.schemas](/projects/291/69205) which model the data structures used in requests and responses. These schemas define properties, types, required fields, and descriptions.

Key schemas include:

BaseInfo

TokenBalance

Account

Tx (Transaction)

TokenMetadata

GasFees


Paths (API Endpoints)

Each path defines supported HTTP methods, parameters, request bodies, and responses.

1. GET /api/v1/info

2. GET /api/v1/account/{pubkey}

3. GET /api/v1/account/{pubkey}/txs

4. GET /api/v1/tx/{txid}

5. POST /api/v1/send

6. POST /api/v1/jsonrpc

7. GET /api/v1/metadata/token

8. POST /api/v1/gas/estimate

9. GET /api/v1/gas/fees


Implementation Details


Interaction with Other System Components


Visual Diagram: API Structure Flowchart

flowchart TD
    A[API Root] --> B[/api/v1/info]
    A --> C[/api/v1/account/{pubkey}]
    C --> C1[/txs]
    A --> D[/api/v1/tx/{txid}]
    A --> E[/api/v1/send]
    A --> F[/api/v1/jsonrpc]
    A --> G[/api/v1/metadata/token]
    A --> H[/api/v1/gas/estimate]
    A --> I[/api/v1/gas/fees]

    subgraph AccountEndpoints
        C
        C1
    end

    subgraph TransactionEndpoints
        D
        E
    end

    subgraph GasEndpoints
        H
        I
    end

    style A fill:#f9f,stroke:#333,stroke-width:2px
    style B fill:#bbf,stroke:#333
    style C fill:#bbf,stroke:#333
    style C1 fill:#ccf,stroke:#333
    style D fill:#bbf,stroke:#333
    style E fill:#bbf,stroke:#333
    style F fill:#bbf,stroke:#333
    style G fill:#bbf,stroke:#333
    style H fill:#bbf,stroke:#333
    style I fill:#bbf,stroke:#333

Summary

The [swagger.json](/projects/291/68851) file fully describes a comprehensive REST and JSON-RPC API for interacting with an Ethereum coinstack. It provides detailed schemas and endpoints for account management, transaction querying, token metadata, gas estimation, and transaction broadcasting. The strict typing and rich metadata facilitate robust client implementation and integration with Ethereum blockchain infrastructure.