M0

M0 Topology API

The Topology API from M0 — 2 operation(s) for topology.

Operations 2

GET /topology/routes #
GET /topology/stats #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/m0-topology-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

m0-topology-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: liquidity-api Order Topology API
  version: '1.0'
  description: This API provides quotes for moving and converting between M extensions and other stablecoins
servers:
- url: https://gateway.m0.xyz/v1/orchestration
  description: mainnet
- url: https://gateway.stage.m0.xyz/v1/orchestration
  description: stage
- url: https://gateway.dev.m0.xyz/v1/orchestration
  description: devnet
- url: http://localhost:5600
  description: localnet
tags:
- name: Topology
paths:
  /topology/routes:
    get:
      description: 'Returns all known routes in the system. Routes are seeded from the

        static asset graph on startup and enriched by live quote traffic.

        This is a read-only view of routing knowledge — not the routing

        logic itself. Use lastUsed and totalQuoteCount to gauge confidence.


        **Error responses**


        Errors return `commons.ErrorBody` (`{ code, message, requestId }`);

        branch on `code`, not the HTTP status.


        | Status | `code`               | When                                                                       |

        | ------ | -------------------- | -------------------------------------------------------------------------- |

        | 400    | `BadTopologyRequest` | Invalid query params: only one of `sourceChain` / `sourceAddress`, or an unknown asset. |'
      operationId: topology_getRoutes
      tags:
      - Topology
      parameters:
      - name: sourceChain
        in: query
        required: false
        schema:
          $ref: '#/components/schemas/Chain'
      - name: sourceAddress
        in: query
        required: false
        schema:
          type:
          - string
          - 'null'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/TopologyRoute'
        '400':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
      security:
      - ApiKeyAuth: []
  /topology/stats:
    get:
      description: Aggregated statistics about route usage
      operationId: topology_getRouteStats
      tags:
      - Topology
      parameters: []
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TopologyRouteStats'
      security:
      - ApiKeyAuth: []
components:
  schemas:
    TopologyRouteProvider:
      title: TopologyRouteProvider
      type: object
      properties:
        provider:
          $ref: '#/components/schemas/Providers'
        lastUsed:
          type:
          - string
          - 'null'
          format: date-time
        quoteCount:
          type: integer
      required:
      - provider
      - quoteCount
    ErrorBody:
      title: ErrorBody
      type: object
      description: 'Standard error response body. Every error response from this API

        returns this shape.'
      properties:
        code:
          $ref: '#/components/schemas/ErrorCode'
          description: Stable machine-readable identifier for the failure mode.
        message:
          type: string
          description: Human-readable description of what went wrong. Safe to surface in UI.
        requestId:
          type:
          - string
          - 'null'
          description: 'Per-request correlation id (matches the `requestId` field in

            server logs). Include this when filing support tickets.'
      required:
      - code
      - message
    ErrorCode:
      title: ErrorCode
      type: string
      enum:
      - QuoteError
      - BadQuoteRequest
      - NoQuotesAvailable
      - BadOrderRequest
      - OrderNotFound
      - OrderNotCancellable
      - CancelOrderError
      - BadTopologyRequest
      - BadPermitRequest
      - PermitNotSupported
      - PermitExpired
      - InvalidPermitSignature
      - PermitQuoteError
      - PermitBuildError
      description: 'Stable machine-readable identifier for an API error. Each value

        corresponds 1:1 to an error type (and to one `responses` entry

        in the OpenAPI spec). Branch on this rather than on the HTTP status

        code — multiple errors may share a status as the API evolves.'
    Providers:
      title: Providers
      type: string
      enum:
      - m-swap-facility
      - m-wormhole-portal
      - m-hyperlane-portal
      - m-portal
      - wormhole-cctp
      - jupiter
      - raydium
      - mayan-swift
      - kyber-swap
      - limit-order
      - uniswap-v3
    TopologyRouteStats:
      title: TopologyRouteStats
      type: object
      properties:
        totalRoutes:
          type: integer
        activeRoutes:
          type: integer
        collectingSince:
          type:
          - string
          - 'null'
          format: date-time
        lastUpdated:
          type:
          - string
          - 'null'
          format: date-time
        hottestPaths:
          type: array
          items:
            $ref: '#/components/schemas/TopologyRoute'
        topSenders:
          type: array
          items:
            $ref: '#/components/schemas/AddressFrequency'
        topRecipients:
          type: array
          items:
            $ref: '#/components/schemas/AddressFrequency'
      required:
      - totalRoutes
      - activeRoutes
      - hottestPaths
      - topSenders
      - topRecipients
    AddressFrequency:
      title: AddressFrequency
      type: object
      properties:
        address:
          type: string
        count:
          type: integer
      required:
      - address
      - count
    Chain:
      title: Chain
      type: string
      enum:
      - Ethereum
      - Solana
      - Arbitrum
      - Base
      - Linea
      - Sepolia
      - BaseSepolia
      - ArbitrumSepolia
      - HyperEVM
      - BinanceSmartChain
      - Mantra
      - Plasma
      - SolanaDevnet
      - Soneium
      - Citrea
      - Fluent
      - Moca
      - Rise
    TopologyRoute:
      title: TopologyRoute
      type: object
      properties:
        source:
          $ref: '#/components/schemas/AssetAddress'
        destination:
          $ref: '#/components/schemas/AssetAddress'
        providers:
          type: array
          items:
            $ref: '#/components/schemas/TopologyRouteProvider'
        lastUsed:
          type:
          - string
          - 'null'
          format: date-time
        totalQuoteCount:
          type: integer
      required:
      - source
      - destination
      - providers
      - totalQuoteCount
    AssetAddress:
      title: AssetAddress
      type: object
      properties:
        chain:
          $ref: '#/components/schemas/Chain'
        address:
          type: string
      required:
      - chain
      - address
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key