Chain · Reads onchain state
Returns the configuration and metadata of every blockchain network Plug indexes and executes on. Each entry carries what a caller needs to speak to a chain through Plug: its id, its identity, and the platform-level configuration that decides how it is indexed and executed against. The list is the authority on where Plug operates; anything not in it is not supported yet. Reach for it to populate a chain picker, to validate a chain id before composing against it, or to discover what is supported without hardcoding a list that will rot.
Send a request
Response
{links: {self: stringprev: string | undefinednext: string | undefined} | undefinedheaders: unknown | undefineddata: {chain_id: numberaddress: stringname: stringsymbol: stringdecimals: numbericon: stringexternal: Record<string, {name: stringurl: string}>block_time: number} | null}
Code samples
Language
Prompt
Call the Plug API endpoint "Get chain(s)".## EndpointGET /chainBase URL: https://api.plug.to## DescriptionReturns the configuration and metadata of every blockchain network Plug indexes and executes on.Each entry carries what a caller needs to speak to a chain through Plug: its id, its identity, and the platform-level configuration that decides how it is indexed and executed against. The list is the authority on where Plug operates; anything not in it is not supported yet.Reach for it to populate a chain picker, to validate a chain id before composing against it, or to discover what is supported without hardcoding a list that will rot.## Query Parameters- filter[chain_id] (integer, optional) — Filter results to specific chains from the listed of supported options.## Headers- Accept (string, required) — For a typical single-time JSON response, set this to application/json. To receive realtime updates through a stream, set this to text/event-stream. (default: application/json) [application/json, text/event-stream]Current value: application/json## Response Schema- links (object, optional)- self (string, required)- prev (string, optional)- next (string, optional)- headers (unknown, optional)- data (object, optional)- chain_id (integer, required)- address (string, required)- name (string, required)- symbol (string, required)- decimals (integer, required)- icon (string, required)- external (Record<string, object>, required)- block_time (integer, required)## Example RequestGET https://api.plug.to/chain