rpc-openapi.json
{
"openapi": "3.0.0",
"info": {
"title": "Octez RPC",
"description": "The RPC API served by the Octez node.",
"version": "16.0"
},
"paths": {
"/chains/{chain_id}": {
"patch": {
"description": "Forcefully set the bootstrapped flag of the node",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"bootstrapped": {
"type": "boolean"
}
},
"required": [
"bootstrapped"
]
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/blocks": {
"get": {
"description": "Lists block hashes from '<chain>', up to the last checkpoint, sorted with decreasing fitness. Without arguments it returns the head of the chain. Optional arguments allow to return the list of predecessors of a given block or of a set of blocks.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "length",
"in": "query",
"description": "The requested number of predecessors to return (per request; see next argument).",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "head",
"in": "query",
"description": "block_hash (Base58Check-encoded) An empty argument requests blocks starting with the current head. A non empty list allows to request one or more specific fragments of the chain.",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "min_date",
"in": "query",
"description": "A date in seconds from epoch When `min_date` is provided, blocks with a timestamp before `min_date` are filtered out. However, if the `length` parameter is also provided, then up to that number of predecessors will be returned regardless of their date.",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "array",
"items": {
"$ref": "#/components/schemas/block_hash"
}
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/chain_id": {
"get": {
"description": "The chain unique identifier.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "Network identifier (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/checkpoint": {
"get": {
"description": "DEPRECATED: use `../levels/{checkpoint, savepoint, caboose, history_mode}` instead. The current checkpoint for this chain.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/block_header"
},
"savepoint": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"caboose": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"history_mode": {
"$ref": "#/components/schemas/history_mode"
}
},
"required": [
"block",
"savepoint",
"caboose",
"history_mode"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/invalid_blocks": {
"get": {
"description": "Lists blocks that have been declared invalid along with the errors that led to them being declared invalid.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/block_hash"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"block",
"level",
"errors"
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/invalid_blocks/{block_hash}": {
"get": {
"description": "The errors that appears during the block (in)validation.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "block_hash",
"in": "path",
"description": "block_hash (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/block_hash"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"block",
"level",
"errors"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
},
"delete": {
"description": "Remove an invalid block for the tezos storage",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "block_hash",
"in": "path",
"description": "block_hash (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/is_bootstrapped": {
"get": {
"description": "The bootstrap status of a chain",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"bootstrapped": {
"type": "boolean"
},
"sync_state": {
"$ref": "#/components/schemas/chain_status"
}
},
"required": [
"bootstrapped",
"sync_state"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/levels/caboose": {
"get": {
"description": "The current caboose for this chain.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"block_hash": {
"$ref": "#/components/schemas/block_hash"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
}
},
"required": [
"block_hash",
"level"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/levels/checkpoint": {
"get": {
"description": "The current checkpoint for this chain.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"block_hash": {
"$ref": "#/components/schemas/block_hash"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
}
},
"required": [
"block_hash",
"level"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/chains/{chain_id}/levels/savepoint": {
"get": {
"description": "The current savepoint for this chain.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"block_hash": {
"$ref": "#/components/schemas/block_hash"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
}
},
"required": [
"block_hash",
"level"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/config": {
"get": {
"description": "Return the runtime node configuration (this takes into account the command-line arguments and the on-disk configuration file)",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"data-dir": {
"description": "Location of the data dir on disk.",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"disable-config-validation": {
"description": "Disable the node configuration validation.",
"type": "boolean"
},
"rpc": {
"description": "Configuration of rpc parameters",
"type": "object",
"properties": {
"listen-addrs": {
"description": "Hosts to listen to. If the port is not specified, the default port 8732 will be assumed.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
},
"listen-addr": {
"description": "Legacy value: Host to listen to",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"cors-origin": {
"description": "Cross Origin Resource Sharing parameters, see https://en.wikipedia.org/wiki/Cross-origin_resource_sharing.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
},
"cors-headers": {
"description": "Cross Origin Resource Sharing parameters, see https://en.wikipedia.org/wiki/Cross-origin_resource_sharing.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
},
"crt": {
"description": "Certificate file (necessary when TLS is used).",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"key": {
"description": "Key file (necessary when TLS is used).",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"acl": {
"description": "A list of RPC ACLs for specific listening addresses.",
"type": "array",
"items": {
"oneOf": [
{
"title": "Whitelist",
"type": "object",
"properties": {
"address": {
"$ref": "#/components/schemas/unistring"
},
"whitelist": {
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
}
},
"required": [
"address",
"whitelist"
]
},
{
"title": "Blacklist",
"type": "object",
"properties": {
"address": {
"$ref": "#/components/schemas/unistring"
},
"blacklist": {
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
}
},
"required": [
"address",
"blacklist"
]
}
]
}
},
"media-type": {
"description": "The media types supported by the server.",
"type": "string",
"enum": [
"json",
"any",
"binary"
]
}
}
},
"p2p": {
"description": "Configuration of network parameters",
"type": "object",
"properties": {
"expected-proof-of-work": {
"description": "Floating point number between 0 and 256 that represents a difficulty, 24 signifies for example that at least 24 leading zeroes are expected in the hash.",
"type": "number"
},
"bootstrap-peers": {
"description": "List of hosts. Tezos can connect to both IPv6 and IPv4 hosts. If the port is not specified, default port 9732 will be assumed.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
},
"listen-addr": {
"description": "Host to listen to. If the port is not specified, the default port 9732 will be assumed.",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"advertised-net-port": {
"description": "Alternative port advertised to other peers to connect to. If the port is not specified, the port from listen-addr will be assumed.",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"discovery-addr": {
"description": "Host for local peer discovery. If the port is not specified, the default port 10732 will be assumed.",
"nullable": true,
"oneOf": [
{
"title": "Some",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
]
},
"private-mode": {
"description": "Specify if the node is in private mode or not. A node in private mode rejects incoming connections from untrusted peers and only opens outgoing connections to peers listed in 'bootstrap-peers' or provided with '--peer' option. Moreover, these peers will keep the identity and the address of the private node secret.",
"type": "boolean"
},
"limits": {
"description": "Network limits",
"type": "object",
"properties": {
"connection-timeout": {
"description": "Delay acceptable when initiating a connection to a new peer, in seconds.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
},
"authentication-timeout": {
"description": "Delay granted to a peer to perform authentication, in seconds.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
},
"min-connections": {
"description": "Strict minimum number of connections (triggers an urgent maintenance).",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"expected-connections": {
"description": "Targeted number of connections to reach when bootstrapping / maintaining.",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"max-connections": {
"description": "Maximum number of connections (exceeding peers are disconnected).",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"backlog": {
"description": "Number above which pending incoming connections are immediately rejected.",
"type": "integer",
"minimum": 0,
"maximum": 255
},
"max-incoming-connections": {
"description": "Number above which pending incoming connections are immediately rejected.",
"type": "integer",
"minimum": 0,
"maximum": 255
},
"max-download-speed": {
"description": "Max download speeds in KiB/s.",
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"max-upload-speed": {
"description": "Max upload speeds in KiB/s.",
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"swap-linger": {
"$ref": "#/components/schemas/timespan.system"
},
"binary-chunks-size": {
"type": "integer",
"minimum": 0,
"maximum": 255
},
"read-buffer-size": {
"description": "Size of the buffer passed to read(2).",
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"read-queue-size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"write-queue-size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"incoming-app-message-queue-size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"incoming-message-queue-size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"outgoing-message-queue-size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"max_known_points": {
"description": "The max and target size for the known address table.",
"type": "array",
"items": {
"oneOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 65535
},
{
"type": "integer",
"minimum": 0,
"maximum": 65535
}
]
}
},
"max_known_peer_ids": {
"description": "The max and target size for the known peers table.",
"type": "array",
"items": {
"oneOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 65535
},
{
"type": "integer",
"minimum": 0,
"maximum": 65535
}
]
}
},
"peer_greylist_size": {
"description": "The number of peer_ids kept in the peer_id greylist.",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"ip_greylist_size_in_kilobytes": {
"description": "The size of the IP address greylist (in kilobytes).",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"ip_greylist_cleanup_delay": {
"description": "The time an IP address is kept in the greylist.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
},
"greylist-timeout": {
"description": "GC delay for the greylists tables, in seconds.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
},
"maintenance-idle-time": {
"description": "How long to wait at most, in seconds, before running a maintenance loop.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
}
}
},
"disable_mempool": {
"description": "If set to [true], the node will not participate in the propagation of pending operations (mempool). Default value is [false]. It can be used to decrease the memory and computation footprints of the node.",
"type": "boolean"
},
"enable_testchain": {
"description": "DEPRECATED. If set to [true], the node will spawn a testchain during the protocol's testing voting period. Default value is [false]. It is disabled to decrease the node storage usage and computation by dropping the validation of the test network blocks.",
"type": "boolean"
},
"greylisting_config": {
"description": "The reconnection policy regulates the frequency with which the node tries to reconnect to an old known peer.",
"type": "object",
"properties": {
"factor": {
"description": "The factor by which the reconnection delay is increased when a peer that was previously disconnected is disconnected again. This value should be set to 1 for a linear back-off and to >1 for an exponential back-off.",
"type": "number"
},
"initial-delay": {
"description": "The span of time a peer is disconnected for when it is first disconnected.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
},
"disconnection-delay": {
"description": "The span of time a peer is disconnected for when it is disconnected as the result of an error.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
},
"increase-cap": {
"description": "The maximum amount by which the reconnection is extended. This limits the rate of the exponential back-off, which eventually becomes linear when it reaches this limit. This limit is set to avoid reaching the End-of-Time when repeatedly reconnection a peer.",
"oneOf": [
{
"$ref": "#/components/schemas/timespan.system"
}
]
}
}
}
}
},
"log": {
"description": "Configuration of the Lwt-log sink (part of the logging framework)",
"type": "object",
"properties": {
"output": {
"description": "Output for the logging function. Either 'stdout', 'stderr' or the name of a log file .",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"level": {
"description": "Verbosity level: one of 'fatal', 'error', 'warn','notice', 'info', 'debug'.",
"type": "string",
"enum": [
"info",
"debug",
"error",
"fatal",
"warning",
"notice"
]
},
"rules": {
"description": "Fine-grained logging instructions. Same format as described in `octez-node run --help`, DEBUG section. In the example below, sections 'p2p' and all sections starting by 'client' will have their messages logged up to the debug level, whereas the rest of log sections will be logged up to the notice level.",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"template": {
"description": "Format for the log file, see https://github.com/ocsigen/lwt_log/blob/1.1.1/src/core/lwt_log_core.mli#L229.",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
}
},
"internal-events": {
"description": "Configuration of the structured logging framework",
"oneOf": [
{
"title": "Active-Sinks",
"description": "List of sinks to make sure are activated.",
"type": "object",
"properties": {
"active_sinks": {
"description": "List of URIs to activate/configure sinks.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
}
}
},
{
"title": "Active-Sinks-Deprecated",
"description": "List of sinks to make sure are activated, deprecated backwards-compatibility encoding.",
"type": "object",
"properties": {
"activate": {
"description": "List of URIs to activate/configure sinks.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
}
}
}
]
},
"shell": {
"description": "Configuration of network parameters",
"type": "object",
"properties": {
"peer_validator": {
"type": "object",
"properties": {
"block_header_request_timeout": {
"$ref": "#/components/schemas/timespan.system"
},
"block_operations_request_timeout": {
"$ref": "#/components/schemas/timespan.system"
},
"protocol_request_timeout": {
"$ref": "#/components/schemas/timespan.system"
},
"new_head_request_timeout": {
"$ref": "#/components/schemas/timespan.system"
}
}
},
"block_validator": {
"type": "object",
"properties": {
"protocol_request_timeout": {
"$ref": "#/components/schemas/timespan.system"
},
"operation_metadata_size_limit": {
"$ref": "#/components/schemas/operation_metadata_size_limit"
}
}
},
"prevalidator": {
"type": "object",
"properties": {
"operations_request_timeout": {
"$ref": "#/components/schemas/timespan.system"
},
"max_refused_operations": {
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"operations_batch_size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"disable_precheck": {
"type": "boolean"
}
}
},
"chain_validator": {
"oneOf": [
{
"title": "synchronisation_heuristic_encoding",
"type": "object",
"properties": {
"latency": {
"description": "[latency] is the time interval (in seconds) used to determine if a peer is synchronized with a chain. For instance, a peer whose known head has a timestamp T is considered synchronized if T >= now - latency. This parameter depends on the baking rate and the latency of the network.",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"synchronisation_threshold": {
"description": "The minimal number of peers this peer should be synchronized with in order to be bootstrapped.",
"type": "integer",
"minimum": 0,
"maximum": 255
}
}
},
{
"title": "legacy_bootstrap_threshold_encoding",
"type": "object",
"properties": {
"bootstrap_threshold": {
"description": "[DEPRECATED] Set the number of peers with whom a chain synchronisation must be completed to bootstrap the node.",
"type": "integer",
"minimum": 0,
"maximum": 255
}
}
}
]
},
"history_mode": {
"$ref": "#/components/schemas/history_mode"
}
}
},
"network": {
"description": "Configuration of which network/blockchain to connect to",
"oneOf": [
{
"title": "sandbox",
"type": "string",
"enum": [
"sandbox"
]
},
{
"title": "mainnet",
"type": "string",
"enum": [
"mainnet"
]
},
{
"title": "ghostnet",
"type": "string",
"enum": [
"ghostnet"
]
},
{
"title": "limanet",
"type": "string",
"enum": [
"limanet"
]
},
{
"title": "mumbainet",
"type": "string",
"enum": [
"mumbainet"
]
},
{
"title": "Custom",
"type": "object",
"properties": {
"genesis": {
"type": "object",
"properties": {
"timestamp": {
"$ref": "#/components/schemas/timestamp.protocol"
},
"block": {
"$ref": "#/components/schemas/block_hash"
},
"protocol": {
"$ref": "#/components/schemas/Protocol_hash"
}
},
"required": [
"timestamp",
"block",
"protocol"
]
},
"genesis_parameters": {
"type": "object",
"properties": {
"context_key": {
"$ref": "#/components/schemas/unistring"
},
"values": {}
},
"required": [
"values"
]
},
"chain_name": {
"$ref": "#/components/schemas/distributed_db_version.name"
},
"old_chain_name": {
"$ref": "#/components/schemas/distributed_db_version.name"
},
"incompatible_chain_name": {
"$ref": "#/components/schemas/distributed_db_version.name"
},
"sandboxed_chain_name": {
"$ref": "#/components/schemas/distributed_db_version.name"
},
"user_activated_upgrades": {
"$ref": "#/components/schemas/user_activated.upgrades"
},
"user_activated_protocol_overrides": {
"$ref": "#/components/schemas/user_activated.protocol_overrides"
},
"default_bootstrap_peers": {
"description": "List of hosts to use if p2p.bootstrap_peers is unspecified.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
}
},
"required": [
"genesis",
"chain_name",
"sandboxed_chain_name"
]
}
]
},
"metrics_addr": {
"description": "Configuration of the Prometheus metrics endpoint",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
},
"dal": {
"description": "USE FOR TESTING PURPOSE ONLY. Configuration for the data-availibility layer",
"type": "object",
"properties": {
"activated": {
"type": "boolean"
},
"srs_size": {
"nullable": true,
"oneOf": [
{
"title": "Some",
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
]
}
},
"required": [
"activated",
"srs_size"
]
}
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/config/history_mode": {
"get": {
"description": "Returns the history mode of the node's underlying storage.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"history_mode": {
"$ref": "#/components/schemas/history_mode"
}
},
"required": [
"history_mode"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/config/logging": {
"put": {
"description": "Replace the logging configuration of the node.",
"requestBody": {
"content": {
"application/json": {
"schema": {
"oneOf": [
{
"title": "Active-Sinks",
"description": "List of sinks to make sure are activated.",
"type": "object",
"properties": {
"active_sinks": {
"description": "List of URIs to activate/configure sinks.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
}
}
},
{
"title": "Active-Sinks-Deprecated",
"description": "List of sinks to make sure are activated, deprecated backwards-compatibility encoding.",
"type": "object",
"properties": {
"activate": {
"description": "List of URIs to activate/configure sinks.",
"type": "array",
"items": {
"$ref": "#/components/schemas/unistring"
}
}
}
}
]
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/config/network/user_activated_protocol_overrides": {
"get": {
"description": "List of protocols which replace other protocols",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "User activated protocol overrides",
"description": "User activated protocol overrides: activate a protocol instead of another.",
"type": "array",
"items": {
"type": "object",
"properties": {
"replaced_protocol": {
"$ref": "#/components/schemas/Protocol_hash"
},
"replacement_protocol": {
"$ref": "#/components/schemas/Protocol_hash"
}
},
"required": [
"replaced_protocol",
"replacement_protocol"
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/config/network/user_activated_upgrades": {
"get": {
"description": "List of protocols to switch to at given levels",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "User activated upgrades",
"description": "User activated upgrades: at given level, switch to given protocol.",
"type": "array",
"items": {
"type": "object",
"properties": {
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"replacement_protocol": {
"$ref": "#/components/schemas/Protocol_hash"
}
},
"required": [
"level",
"replacement_protocol"
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/errors": {
"get": {
"description": "Schema for all the RPC errors from the shell",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/fetch_protocol/{Protocol_hash}": {
"get": {
"description": "Fetch a protocol from the network.",
"parameters": [
{
"name": "Protocol_hash",
"in": "path",
"description": "Protocol_hash (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/injection/block": {
"post": {
"description": "Inject a block in the node and broadcast it. The `operations` embedded in `blockHeader` might be pre-validated using a contextual RPCs from the latest block (e.g. '/blocks/head/context/preapply'). Returns the ID of the block. By default, the RPC will wait for the block to be validated before answering. If ?async is true, the function returns immediately. Otherwise, the block will be validated before the result is returned. If ?force is true, it will be injected even on non strictly increasing fitness. An optional ?chain parameter can be used to specify whether to inject on the test chain or the main chain.",
"parameters": [
{
"name": "async",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "force",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "chain",
"in": "query",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": false,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"data": {
"type": "string",
"pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$"
},
"operations": {
"type": "array",
"items": {
"type": "array",
"items": {
"$ref": "#/components/schemas/operation"
}
}
}
},
"required": [
"data",
"operations"
]
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "A block identifier (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/injection/operation": {
"post": {
"description": "Inject an operation in node and broadcast it. Returns the ID of the operation. The `signedOperationContents` should be constructed using contextual RPCs from the latest block and signed by the client. The injection of the operation will apply it on the current mempool context. This context may change at each operation injection or operation reception from peers. By default, the RPC will wait for the operation to be (pre-)validated before returning. However, if ?async is true, the function returns immediately. The optional ?chain parameter can be used to specify whether to inject on the test chain or the main chain.",
"parameters": [
{
"name": "async",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "chain",
"in": "query",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": false,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "string",
"pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$"
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "A Tezos operation ID (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/injection/protocol": {
"post": {
"description": "Inject a protocol in node. Returns the ID of the protocol. If ?async is true, the function returns immediately. Otherwise, the protocol will be validated before the result is returned.",
"parameters": [
{
"name": "async",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"description": "The environment a protocol relies on and the components a protocol is made of.",
"type": "object",
"properties": {
"expected_env_version": {
"$ref": "#/components/schemas/protocol.environment_version"
},
"components": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"$ref": "#/components/schemas/unistring"
},
"interface": {
"$ref": "#/components/schemas/unistring"
},
"implementation": {
"$ref": "#/components/schemas/unistring"
}
},
"required": [
"name",
"implementation"
]
}
}
},
"required": [
"expected_env_version",
"components"
]
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "A Tezos protocol ID (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/active_chains": {
"get": {
"description": "Monitor every chain creation and destruction. Currently active chains will be given as first elements",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"oneOf": [
{
"title": "Main",
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
}
},
"required": [
"chain_id"
]
},
{
"title": "Test",
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"test_protocol": {
"$ref": "#/components/schemas/Protocol_hash"
},
"expiration_date": {
"$ref": "#/components/schemas/timestamp.protocol"
}
},
"required": [
"chain_id",
"test_protocol",
"expiration_date"
]
},
{
"title": "Stopping",
"type": "object",
"properties": {
"stopping": {
"$ref": "#/components/schemas/Chain_id"
}
},
"required": [
"stopping"
]
}
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/applied_blocks": {
"get": {
"description": "Monitor all blocks that are successfully applied and stored by the node, disregarding whether they were selected as the new head or not.",
"parameters": [
{
"name": "protocol",
"in": "query",
"description": "Protocol_hash (Base58Check-encoded)",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "next_protocol",
"in": "query",
"description": "Protocol_hash (Base58Check-encoded)",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "chain",
"in": "query",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"hash": {
"$ref": "#/components/schemas/block_hash"
},
"header": {
"$ref": "#/components/schemas/block_header"
},
"operations": {
"type": "array",
"items": {
"type": "array",
"items": {
"$ref": "#/components/schemas/operation"
}
}
}
},
"required": [
"chain_id",
"hash",
"header",
"operations"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/bootstrapped": {
"get": {
"description": "Wait for the node to have synchronized its chain with a few peers (configured by the node's administrator), streaming head updates that happen during the bootstrapping process, and closing the stream at the end. If the node was already bootstrapped, returns the current head immediately.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/block_hash"
},
"timestamp": {
"$ref": "#/components/schemas/timestamp.protocol"
}
},
"required": [
"block",
"timestamp"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/commit_hash": {
"get": {
"description": "DEPRECATED: use `version` instead.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "Universal string representation",
"description": "Either a plain UTF8 string, or a sequence of bytes for strings that contain invalid byte sequences.",
"oneOf": [
{
"type": "string"
},
{
"type": "object",
"properties": {
"invalid_utf8_string": {
"type": "array",
"items": {
"type": "integer",
"minimum": 0,
"maximum": 255
}
}
},
"required": [
"invalid_utf8_string"
]
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/heads/{chain_id}": {
"get": {
"description": "Monitor all blocks that are successfully validated and applied by the node and selected as the new head of the given chain.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "next_protocol",
"in": "query",
"description": "Protocol_hash (Base58Check-encoded)",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "Block header",
"description": "Block header. It contains both shell and protocol specific data.",
"type": "object",
"properties": {
"hash": {
"$ref": "#/components/schemas/block_hash"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"proto": {
"type": "integer",
"minimum": 0,
"maximum": 255
},
"predecessor": {
"$ref": "#/components/schemas/block_hash"
},
"timestamp": {
"$ref": "#/components/schemas/timestamp.protocol"
},
"validation_pass": {
"type": "integer",
"minimum": 0,
"maximum": 255
},
"operations_hash": {
"$ref": "#/components/schemas/Operation_list_list_hash"
},
"fitness": {
"$ref": "#/components/schemas/fitness"
},
"context": {
"$ref": "#/components/schemas/Context_hash"
},
"protocol_data": {
"type": "string",
"pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$"
}
},
"required": [
"hash",
"level",
"proto",
"predecessor",
"timestamp",
"validation_pass",
"operations_hash",
"fitness",
"context",
"protocol_data"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/protocols": {
"get": {
"description": "Monitor all economic protocols that are retrieved and successfully loaded and compiled by the node.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "A Tezos protocol ID (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/valid_blocks": {
"get": {
"description": "(Deprecated) Monitor all blocks that are successfully applied by the node, disregarding whether they were selected as the new head or not.",
"parameters": [
{
"name": "protocol",
"in": "query",
"description": "Protocol_hash (Base58Check-encoded)",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "next_protocol",
"in": "query",
"description": "Protocol_hash (Base58Check-encoded)",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "chain",
"in": "query",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "Block header",
"description": "Block header. It contains both shell and protocol specific data.",
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"hash": {
"$ref": "#/components/schemas/block_hash"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"proto": {
"type": "integer",
"minimum": 0,
"maximum": 255
},
"predecessor": {
"$ref": "#/components/schemas/block_hash"
},
"timestamp": {
"$ref": "#/components/schemas/timestamp.protocol"
},
"validation_pass": {
"type": "integer",
"minimum": 0,
"maximum": 255
},
"operations_hash": {
"$ref": "#/components/schemas/Operation_list_list_hash"
},
"fitness": {
"$ref": "#/components/schemas/fitness"
},
"context": {
"$ref": "#/components/schemas/Context_hash"
},
"protocol_data": {
"type": "string",
"pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$"
}
},
"required": [
"chain_id",
"hash",
"level",
"proto",
"predecessor",
"timestamp",
"validation_pass",
"operations_hash",
"fitness",
"context",
"protocol_data"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/monitor/validated_blocks": {
"get": {
"description": "Monitor all blocks that were successfully validated by the node but are not applied nor stored yet, disregarding whether they are going to be selected as the new head or not.",
"parameters": [
{
"name": "protocol",
"in": "query",
"description": "Protocol_hash (Base58Check-encoded)",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "next_protocol",
"in": "query",
"description": "Protocol_hash (Base58Check-encoded)",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "chain",
"in": "query",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"hash": {
"$ref": "#/components/schemas/block_hash"
},
"header": {
"$ref": "#/components/schemas/block_header"
},
"operations": {
"type": "array",
"items": {
"type": "array",
"items": {
"$ref": "#/components/schemas/operation"
}
}
}
},
"required": [
"chain_id",
"hash",
"header",
"operations"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/connections": {
"get": {
"description": "List the running P2P connection.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"incoming": {
"type": "boolean"
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"id_point": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"remote_socket_port": {
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"announced_version": {
"$ref": "#/components/schemas/network_version"
},
"private": {
"type": "boolean"
},
"local_metadata": {
"type": "object",
"properties": {
"disable_mempool": {
"type": "boolean"
},
"private_node": {
"type": "boolean"
}
},
"required": [
"disable_mempool",
"private_node"
]
},
"remote_metadata": {
"type": "object",
"properties": {
"disable_mempool": {
"type": "boolean"
},
"private_node": {
"type": "boolean"
}
},
"required": [
"disable_mempool",
"private_node"
]
}
},
"required": [
"incoming",
"peer_id",
"id_point",
"remote_socket_port",
"announced_version",
"private",
"local_metadata",
"remote_metadata"
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/connections/{peer_id}": {
"get": {
"description": "Details about the current P2P connection to the given peer.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"incoming": {
"type": "boolean"
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"id_point": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"remote_socket_port": {
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"announced_version": {
"$ref": "#/components/schemas/network_version"
},
"private": {
"type": "boolean"
},
"local_metadata": {
"type": "object",
"properties": {
"disable_mempool": {
"type": "boolean"
},
"private_node": {
"type": "boolean"
}
},
"required": [
"disable_mempool",
"private_node"
]
},
"remote_metadata": {
"type": "object",
"properties": {
"disable_mempool": {
"type": "boolean"
},
"private_node": {
"type": "boolean"
}
},
"required": [
"disable_mempool",
"private_node"
]
}
},
"required": [
"incoming",
"peer_id",
"id_point",
"remote_socket_port",
"announced_version",
"private",
"local_metadata",
"remote_metadata"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
},
"delete": {
"description": "Forced close of the current P2P connection to the given peer.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "wait",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/greylist": {
"delete": {
"description": "Clear all greylists tables. This will unban all addresses and peers automatically greylisted by the system.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/greylist/clear": {
"get": {
"description": "DEPRECATED: Clear all greylists tables. This will unban all addresses and peers automatically greylisted by the system. Use DELETE `/network/greylist` instead",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/greylist/ips": {
"get": {
"description": "Returns an object that contains a list of IP and the field \"not_reliable_since\".\n If the field \"not_reliable_since\" is None then the list contains the currently greylisted IP addresses.\n If the field \"not_reliable_since\" Contains a date, this means that the greylist has been overflowed and it is no more possible to obtain the exact list of greylisted IPs. Since the greylist of IP addresses has been design to work whatever his size, there is no security issue related to this overflow.\n Reinitialize the ACL structure by calling \"delete /network/greylist\" to get back this list reliable.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"ips": {
"type": "array",
"items": {
"$ref": "#/components/schemas/p2p_address"
}
},
"not_reliable_since": {
"nullable": true,
"oneOf": [
{
"title": "Some",
"oneOf": [
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
]
}
},
"required": [
"ips",
"not_reliable_since"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/greylist/peers": {
"get": {
"description": "List of the last greylisted peers.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/log": {
"get": {
"description": "Stream of all network events",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "An event that may happen during maintenance of and other operations on the p2p connection pool. Typically, it includes connection errors, peer swaps, etc.",
"oneOf": [
{
"title": "Too_few_connections",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"too_few_connections"
]
}
},
"required": [
"event"
]
},
{
"title": "Too_many_connections",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"too_many_connections"
]
}
},
"required": [
"event"
]
},
{
"title": "New_point",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"new_point"
]
},
"point": {
"$ref": "#/components/schemas/p2p_point.id"
}
},
"required": [
"event",
"point"
]
},
{
"title": "New_peer",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"new_peer"
]
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"peer_id"
]
},
{
"title": "Incoming_connection",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"incoming_connection"
]
},
"point": {
"$ref": "#/components/schemas/p2p_point.id"
}
},
"required": [
"event",
"point"
]
},
{
"title": "Outgoing_connection",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"outgoing_connection"
]
},
"point": {
"$ref": "#/components/schemas/p2p_point.id"
}
},
"required": [
"event",
"point"
]
},
{
"title": "Authentication_failed",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"authentication_failed"
]
},
"point": {
"$ref": "#/components/schemas/p2p_point.id"
}
},
"required": [
"event",
"point"
]
},
{
"title": "Accepting_request",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"accepting_request"
]
},
"point": {
"$ref": "#/components/schemas/p2p_point.id"
},
"id_point": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"point",
"id_point",
"peer_id"
]
},
{
"title": "Rejecting_request",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"rejecting_request"
]
},
"point": {
"$ref": "#/components/schemas/p2p_point.id"
},
"id_point": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"point",
"id_point",
"peer_id"
]
},
{
"title": "Request_rejected",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"request_rejected"
]
},
"point": {
"$ref": "#/components/schemas/p2p_point.id"
},
"identity": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
]
}
}
},
"required": [
"event",
"point"
]
},
{
"title": "Connection_established",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"connection_established"
]
},
"id_point": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"id_point",
"peer_id"
]
},
{
"title": "Disconnection",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"disconnection"
]
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"peer_id"
]
},
{
"title": "External_disconnection",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"external_disconnection"
]
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"peer_id"
]
},
{
"title": "Gc_points",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"gc_points"
]
}
},
"required": [
"event"
]
},
{
"title": "Gc_peer_ids",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"gc_peer_ids"
]
}
},
"required": [
"event"
]
},
{
"title": "Swap_request_received",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"swap_request_received"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Swap_ack_received",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"swap_ack_received"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Swap_request_sent",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"swap_request_sent"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Swap_ack_sent",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"swap_ack_sent"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Swap_request_ignored",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"swap_request_ignored"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Swap_success",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"swap_success"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Swap_failure",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"swap_failure"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Bootstrap_sent",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"bootstrap_sent"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Bootstrap_received",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"bootstrap_received"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Advertise_sent",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"advertise_sent"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
},
{
"title": "Advertise_received",
"type": "object",
"properties": {
"event": {
"type": "string",
"enum": [
"advertise_received"
]
},
"source": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event",
"source"
]
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers": {
"get": {
"description": "List the peers the node ever met.",
"parameters": [
{
"name": "filter",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"type": "object",
"properties": {
"score": {
"type": "number"
},
"trusted": {
"type": "boolean"
},
"conn_metadata": {
"type": "object",
"properties": {
"disable_mempool": {
"type": "boolean"
},
"private_node": {
"type": "boolean"
}
},
"required": [
"disable_mempool",
"private_node"
]
},
"peer_metadata": {
"type": "object",
"properties": {
"responses": {
"type": "object",
"properties": {
"sent": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"failed": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"received": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"unexpected": {
"$ref": "#/components/schemas/bignum"
},
"outdated": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"sent",
"failed",
"received",
"unexpected",
"outdated"
]
},
"requests": {
"type": "object",
"properties": {
"sent": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"received": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"failed": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"scheduled": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
}
},
"required": [
"sent",
"received",
"failed",
"scheduled"
]
},
"valid_blocks": {
"$ref": "#/components/schemas/bignum"
},
"old_heads": {
"$ref": "#/components/schemas/bignum"
},
"prevalidator_results": {
"type": "object",
"properties": {
"cannot_download": {
"$ref": "#/components/schemas/bignum"
},
"cannot_parse": {
"$ref": "#/components/schemas/bignum"
},
"refused_by_prefilter": {
"$ref": "#/components/schemas/bignum"
},
"refused_by_postfilter": {
"$ref": "#/components/schemas/bignum"
},
"applied": {
"$ref": "#/components/schemas/bignum"
},
"branch_delayed": {
"$ref": "#/components/schemas/bignum"
},
"branch_refused": {
"$ref": "#/components/schemas/bignum"
},
"refused": {
"$ref": "#/components/schemas/bignum"
},
"duplicate": {
"$ref": "#/components/schemas/bignum"
},
"outdated": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"cannot_download",
"cannot_parse",
"refused_by_prefilter",
"refused_by_postfilter",
"applied",
"branch_delayed",
"branch_refused",
"refused",
"duplicate",
"outdated"
]
},
"unactivated_chains": {
"$ref": "#/components/schemas/bignum"
},
"inactive_chains": {
"$ref": "#/components/schemas/bignum"
},
"future_blocks_advertised": {
"$ref": "#/components/schemas/bignum"
},
"unadvertised": {
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocol": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"block",
"operations",
"protocol"
]
},
"advertisements": {
"type": "object",
"properties": {
"sent": {
"type": "object",
"properties": {
"head": {
"$ref": "#/components/schemas/bignum"
},
"branch": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"head",
"branch"
]
},
"received": {
"type": "object",
"properties": {
"head": {
"$ref": "#/components/schemas/bignum"
},
"branch": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"head",
"branch"
]
}
},
"required": [
"sent",
"received"
]
}
},
"required": [
"responses",
"requests",
"valid_blocks",
"old_heads",
"prevalidator_results",
"unactivated_chains",
"inactive_chains",
"future_blocks_advertised",
"unadvertised",
"advertisements"
]
},
"state": {
"$ref": "#/components/schemas/p2p_peer.state"
},
"reachable_at": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"stat": {
"$ref": "#/components/schemas/p2p_stat"
},
"last_failed_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_rejected_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_established_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_disconnection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_seen": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_miss": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
}
},
"required": [
"score",
"trusted",
"peer_metadata",
"state",
"stat"
]
}
]
}
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers/{peer_id}": {
"get": {
"description": "Details about a given peer.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"score": {
"type": "number"
},
"trusted": {
"type": "boolean"
},
"conn_metadata": {
"type": "object",
"properties": {
"disable_mempool": {
"type": "boolean"
},
"private_node": {
"type": "boolean"
}
},
"required": [
"disable_mempool",
"private_node"
]
},
"peer_metadata": {
"type": "object",
"properties": {
"responses": {
"type": "object",
"properties": {
"sent": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"failed": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"received": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"unexpected": {
"$ref": "#/components/schemas/bignum"
},
"outdated": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"sent",
"failed",
"received",
"unexpected",
"outdated"
]
},
"requests": {
"type": "object",
"properties": {
"sent": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"received": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"failed": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"scheduled": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
}
},
"required": [
"sent",
"received",
"failed",
"scheduled"
]
},
"valid_blocks": {
"$ref": "#/components/schemas/bignum"
},
"old_heads": {
"$ref": "#/components/schemas/bignum"
},
"prevalidator_results": {
"type": "object",
"properties": {
"cannot_download": {
"$ref": "#/components/schemas/bignum"
},
"cannot_parse": {
"$ref": "#/components/schemas/bignum"
},
"refused_by_prefilter": {
"$ref": "#/components/schemas/bignum"
},
"refused_by_postfilter": {
"$ref": "#/components/schemas/bignum"
},
"applied": {
"$ref": "#/components/schemas/bignum"
},
"branch_delayed": {
"$ref": "#/components/schemas/bignum"
},
"branch_refused": {
"$ref": "#/components/schemas/bignum"
},
"refused": {
"$ref": "#/components/schemas/bignum"
},
"duplicate": {
"$ref": "#/components/schemas/bignum"
},
"outdated": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"cannot_download",
"cannot_parse",
"refused_by_prefilter",
"refused_by_postfilter",
"applied",
"branch_delayed",
"branch_refused",
"refused",
"duplicate",
"outdated"
]
},
"unactivated_chains": {
"$ref": "#/components/schemas/bignum"
},
"inactive_chains": {
"$ref": "#/components/schemas/bignum"
},
"future_blocks_advertised": {
"$ref": "#/components/schemas/bignum"
},
"unadvertised": {
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocol": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"block",
"operations",
"protocol"
]
},
"advertisements": {
"type": "object",
"properties": {
"sent": {
"type": "object",
"properties": {
"head": {
"$ref": "#/components/schemas/bignum"
},
"branch": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"head",
"branch"
]
},
"received": {
"type": "object",
"properties": {
"head": {
"$ref": "#/components/schemas/bignum"
},
"branch": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"head",
"branch"
]
}
},
"required": [
"sent",
"received"
]
}
},
"required": [
"responses",
"requests",
"valid_blocks",
"old_heads",
"prevalidator_results",
"unactivated_chains",
"inactive_chains",
"future_blocks_advertised",
"unadvertised",
"advertisements"
]
},
"state": {
"$ref": "#/components/schemas/p2p_peer.state"
},
"reachable_at": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"stat": {
"$ref": "#/components/schemas/p2p_stat"
},
"last_failed_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_rejected_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_established_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_disconnection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_seen": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_miss": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
}
},
"required": [
"score",
"trusted",
"peer_metadata",
"state",
"stat"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
},
"patch": {
"description": "Change the permissions of a given peer. With `{acl: ban}`: blacklist the given peer and remove it from the whitelist if present. With `{acl: open}`: removes the peer from the blacklist and whitelist. With `{acl: trust}`: trust the given peer permanently and remove it from the blacklist if present. The peer cannot be blocked (but its host IP still can).",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"acl": {
"type": "string",
"enum": [
"open",
"trust",
"ban"
]
}
}
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"score": {
"type": "number"
},
"trusted": {
"type": "boolean"
},
"conn_metadata": {
"type": "object",
"properties": {
"disable_mempool": {
"type": "boolean"
},
"private_node": {
"type": "boolean"
}
},
"required": [
"disable_mempool",
"private_node"
]
},
"peer_metadata": {
"type": "object",
"properties": {
"responses": {
"type": "object",
"properties": {
"sent": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"failed": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"received": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"unexpected": {
"$ref": "#/components/schemas/bignum"
},
"outdated": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"sent",
"failed",
"received",
"unexpected",
"outdated"
]
},
"requests": {
"type": "object",
"properties": {
"sent": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"received": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"failed": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
},
"scheduled": {
"oneOf": [
{
"title": "peer_metadata.v1",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"checkpoint": {
"$ref": "#/components/schemas/bignum"
},
"protocol_branch": {
"$ref": "#/components/schemas/bignum"
},
"predecessor_header": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"checkpoint",
"protocol_branch",
"predecessor_header",
"other"
]
},
{
"title": "peer_metadata.legacy_v0",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/bignum"
},
"head": {
"$ref": "#/components/schemas/bignum"
},
"block_header": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocols": {
"$ref": "#/components/schemas/bignum"
},
"operation_hashes_for_block": {
"$ref": "#/components/schemas/bignum"
},
"operations_for_block": {
"$ref": "#/components/schemas/bignum"
},
"other": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"branch",
"head",
"block_header",
"operations",
"protocols",
"operation_hashes_for_block",
"operations_for_block",
"other"
]
}
]
}
},
"required": [
"sent",
"received",
"failed",
"scheduled"
]
},
"valid_blocks": {
"$ref": "#/components/schemas/bignum"
},
"old_heads": {
"$ref": "#/components/schemas/bignum"
},
"prevalidator_results": {
"type": "object",
"properties": {
"cannot_download": {
"$ref": "#/components/schemas/bignum"
},
"cannot_parse": {
"$ref": "#/components/schemas/bignum"
},
"refused_by_prefilter": {
"$ref": "#/components/schemas/bignum"
},
"refused_by_postfilter": {
"$ref": "#/components/schemas/bignum"
},
"applied": {
"$ref": "#/components/schemas/bignum"
},
"branch_delayed": {
"$ref": "#/components/schemas/bignum"
},
"branch_refused": {
"$ref": "#/components/schemas/bignum"
},
"refused": {
"$ref": "#/components/schemas/bignum"
},
"duplicate": {
"$ref": "#/components/schemas/bignum"
},
"outdated": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"cannot_download",
"cannot_parse",
"refused_by_prefilter",
"refused_by_postfilter",
"applied",
"branch_delayed",
"branch_refused",
"refused",
"duplicate",
"outdated"
]
},
"unactivated_chains": {
"$ref": "#/components/schemas/bignum"
},
"inactive_chains": {
"$ref": "#/components/schemas/bignum"
},
"future_blocks_advertised": {
"$ref": "#/components/schemas/bignum"
},
"unadvertised": {
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/bignum"
},
"operations": {
"$ref": "#/components/schemas/bignum"
},
"protocol": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"block",
"operations",
"protocol"
]
},
"advertisements": {
"type": "object",
"properties": {
"sent": {
"type": "object",
"properties": {
"head": {
"$ref": "#/components/schemas/bignum"
},
"branch": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"head",
"branch"
]
},
"received": {
"type": "object",
"properties": {
"head": {
"$ref": "#/components/schemas/bignum"
},
"branch": {
"$ref": "#/components/schemas/bignum"
}
},
"required": [
"head",
"branch"
]
}
},
"required": [
"sent",
"received"
]
}
},
"required": [
"responses",
"requests",
"valid_blocks",
"old_heads",
"prevalidator_results",
"unactivated_chains",
"inactive_chains",
"future_blocks_advertised",
"unadvertised",
"advertisements"
]
},
"state": {
"$ref": "#/components/schemas/p2p_peer.state"
},
"reachable_at": {
"$ref": "#/components/schemas/p2p_connection.id"
},
"stat": {
"$ref": "#/components/schemas/p2p_stat"
},
"last_failed_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_rejected_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_established_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_disconnection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_seen": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_miss": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_connection.id"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
}
},
"required": [
"score",
"trusted",
"peer_metadata",
"state",
"stat"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers/{peer_id}/ban": {
"get": {
"description": "DEPRECATED: Blacklist the given peer and remove it from the whitelist if present. Use PATCH `network/peers/<peer_id>` instead.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers/{peer_id}/banned": {
"get": {
"description": "Check if a given peer is blacklisted or greylisted.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "boolean"
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers/{peer_id}/log": {
"get": {
"description": "Monitor network events related to a given peer.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "monitor",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/p2p_peer.pool_event"
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers/{peer_id}/trust": {
"get": {
"description": "DEPRECATED: Whitelist a given peer permanently and remove it from the blacklist if present. The peer cannot be blocked (but its host IP still can). Use PATCH `network/peers/<peer_id>` instead.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers/{peer_id}/unban": {
"get": {
"description": "DEPRECATED: Remove the given peer from the blacklist. Use PATCH `network/peers/<peer_id>` instead.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/peers/{peer_id}/untrust": {
"get": {
"description": "DEPRECATED: Remove a given peer from the whitelist. Use PATCH `network/peers/<peer_id>` instead.",
"parameters": [
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points": {
"get": {
"description": "List the pool of known `IP:port` used for establishing P2P connections.",
"parameters": [
{
"name": "filter",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/p2p_point.id"
},
{
"$ref": "#/components/schemas/p2p_point.info"
}
]
}
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points/{point}": {
"get": {
"description": "Details about a given `IP:addr`.",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "Information about a peer point. Includes flags, state, and records about past events.",
"type": "object",
"properties": {
"trusted": {
"type": "boolean"
},
"greylisted_until": {
"$ref": "#/components/schemas/timestamp.system"
},
"state": {
"$ref": "#/components/schemas/p2p_point.state"
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"last_failed_connection": {
"$ref": "#/components/schemas/timestamp.system"
},
"last_rejected_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_established_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_disconnection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_seen": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_miss": {
"$ref": "#/components/schemas/timestamp.system"
},
"expected_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"trusted",
"state"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
},
"put": {
"description": "Connect to a peer",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "timeout",
"in": "query",
"description": "A span of time in seconds",
"required": true,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
},
"patch": {
"description": "Change the connectivity state of a given `IP:addr`. With `{acl : ban}`: blacklist the given address and remove it from the whitelist if present. With `{acl: open}`: removes an address from the blacklist and whitelist. With `{acl: trust}`: trust a given address permanently and remove it from the blacklist if present. With `{peer_id: <id>}` set the peerId of the point. Connections from this address can still be closed on authentication if the peer is greylisted. ",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"acl": {
"type": "string",
"enum": [
"open",
"trust",
"ban"
]
},
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
}
}
}
}
},
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "Information about a peer point. Includes flags, state, and records about past events.",
"type": "object",
"properties": {
"trusted": {
"type": "boolean"
},
"greylisted_until": {
"$ref": "#/components/schemas/timestamp.system"
},
"state": {
"$ref": "#/components/schemas/p2p_point.state"
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"last_failed_connection": {
"$ref": "#/components/schemas/timestamp.system"
},
"last_rejected_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_established_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_disconnection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_seen": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_miss": {
"$ref": "#/components/schemas/timestamp.system"
},
"expected_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"trusted",
"state"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points/{point}/ban": {
"get": {
"description": "DEPRECATED: Blacklist the given address and remove it from the whitelist if present. Use PATCH `/network/point/<point_id>` instead.",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points/{point}/banned": {
"get": {
"description": "Check if a given address is blacklisted or greylisted. Port component is unused.",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "boolean"
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points/{point}/log": {
"get": {
"description": "Monitor network events related to an `IP:addr`.",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "monitor",
"in": "query",
"required": false,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/p2p_point.pool_event"
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points/{point}/trust": {
"get": {
"description": "DEPRECATED: Trust a given address permanently and remove it from the blacklist if present. Connections from this address can still be closed on authentication if the peer is greylisted. Use PATCH`/network/point/<point_id>` instead.",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points/{point}/unban": {
"get": {
"description": "DEPRECATED: Remove an address from the blacklist. Use PATCH `/network/point/<point_id>` instead.",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/points/{point}/untrust": {
"get": {
"description": "DEPRECATED: Remove an address from the whitelist. Use PATCH `/network/point/<point_id>` instead.",
"parameters": [
{
"name": "point",
"in": "path",
"description": "A network point (ipv4:port or [ipv6]:port).",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/self": {
"get": {
"description": "Return the node's peer id",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"title": "A Cryptobox public key ID (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/stat": {
"get": {
"description": "Global network bandwidth statistics in B/s.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "Statistics about the p2p network.",
"type": "object",
"properties": {
"total_sent": {
"$ref": "#/components/schemas/int64"
},
"total_recv": {
"$ref": "#/components/schemas/int64"
},
"current_inflow": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"current_outflow": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"total_sent",
"total_recv",
"current_inflow",
"current_outflow"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/version": {
"get": {
"description": "DEPRECATED: use `version` instead.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "A version number for the network protocol (includes distributed DB version and p2p version)",
"type": "object",
"properties": {
"chain_name": {
"$ref": "#/components/schemas/distributed_db_version.name"
},
"distributed_db_version": {
"$ref": "#/components/schemas/distributed_db_version"
},
"p2p_version": {
"$ref": "#/components/schemas/p2p_version"
}
},
"required": [
"chain_name",
"distributed_db_version",
"p2p_version"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/network/versions": {
"get": {
"description": "DEPRECATED: use `version` instead.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/network_version"
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/protocols": {
"get": {
"description": "(no description)",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Protocol_hash"
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/protocols/{Protocol_hash}": {
"get": {
"description": "(no description)",
"parameters": [
{
"name": "Protocol_hash",
"in": "path",
"description": "Protocol_hash (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The environment a protocol relies on and the components a protocol is made of.",
"type": "object",
"properties": {
"expected_env_version": {
"$ref": "#/components/schemas/protocol.environment_version"
},
"components": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"$ref": "#/components/schemas/unistring"
},
"interface": {
"$ref": "#/components/schemas/unistring"
},
"implementation": {
"$ref": "#/components/schemas/unistring"
}
},
"required": [
"name",
"implementation"
]
}
}
},
"required": [
"expected_env_version",
"components"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/protocols/{Protocol_hash}/environment": {
"get": {
"description": "(no description)",
"parameters": [
{
"name": "Protocol_hash",
"in": "path",
"description": "Protocol_hash (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "integer",
"minimum": 0,
"maximum": 65535
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/stats/gc": {
"get": {
"description": "Gets stats from the OCaml Garbage Collector",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"minor_words": {
"type": "number"
},
"promoted_words": {
"type": "number"
},
"major_words": {
"type": "number"
},
"minor_collections": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"major_collections": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"forced_major_collections": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"heap_words": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"heap_chunks": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"live_words": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"live_blocks": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"free_words": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"free_blocks": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"largest_free": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"fragments": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"compactions": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"top_heap_words": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"stack_size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"minor_words",
"promoted_words",
"major_words",
"minor_collections",
"major_collections",
"forced_major_collections",
"heap_words",
"heap_chunks",
"live_words",
"live_blocks",
"free_words",
"free_blocks",
"largest_free",
"fragments",
"compactions",
"top_heap_words",
"stack_size"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/stats/memory": {
"get": {
"description": "Gets memory usage stats",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"oneOf": [
{
"title": "Linux_proc_statm",
"type": "object",
"properties": {
"page_size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"size": {
"$ref": "#/components/schemas/int64"
},
"resident": {
"$ref": "#/components/schemas/int64"
},
"shared": {
"$ref": "#/components/schemas/int64"
},
"text": {
"$ref": "#/components/schemas/int64"
},
"lib": {
"$ref": "#/components/schemas/int64"
},
"data": {
"$ref": "#/components/schemas/int64"
},
"dt": {
"$ref": "#/components/schemas/int64"
}
},
"required": [
"page_size",
"size",
"resident",
"shared",
"text",
"lib",
"data",
"dt"
]
},
{
"title": "Darwin_ps",
"type": "object",
"properties": {
"page_size": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"mem": {
"type": "number"
},
"resident": {
"$ref": "#/components/schemas/int64"
}
},
"required": [
"page_size",
"mem",
"resident"
]
}
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/version": {
"get": {
"description": "Get information on the node version",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"version": {
"type": "object",
"properties": {
"major": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"minor": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"additional_info": {
"oneOf": [
{
"title": "Dev",
"type": "string",
"enum": [
"dev"
]
},
{
"title": "RC",
"type": "object",
"properties": {
"rc": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"rc"
]
},
{
"title": "Release",
"type": "string",
"enum": [
"release"
]
},
{
"title": "RC_dev",
"type": "object",
"properties": {
"rc_dev": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"rc_dev"
]
}
]
}
},
"required": [
"major",
"minor",
"additional_info"
]
},
"network_version": {
"$ref": "#/components/schemas/network_version"
},
"commit_info": {
"nullable": true,
"oneOf": [
{
"title": "Some",
"type": "object",
"properties": {
"commit_hash": {
"$ref": "#/components/schemas/unistring"
},
"commit_date": {
"$ref": "#/components/schemas/unistring"
}
},
"required": [
"commit_hash",
"commit_date"
]
}
]
}
},
"required": [
"version",
"network_version",
"commit_info"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/block_validator": {
"get": {
"description": "Introspect the state of the block_validator worker.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"pending_requests": {
"type": "array",
"items": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "validation",
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/block_hash"
},
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"peer": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"block",
"chain_id"
]
},
{
"title": "preapplication",
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
}
},
"required": [
"chain_id",
"level"
]
}
]
}
},
"required": [
"pushed",
"request"
]
}
},
"current_request": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"treated": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "validation",
"type": "object",
"properties": {
"block": {
"$ref": "#/components/schemas/block_hash"
},
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"peer": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"block",
"chain_id"
]
},
{
"title": "preapplication",
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
}
},
"required": [
"chain_id",
"level"
]
}
]
}
},
"required": [
"pushed",
"treated",
"request"
]
}
},
"required": [
"status",
"pending_requests"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/chain_validators": {
"get": {
"description": "Lists the chain validator workers and their status.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"information": {
"type": "object",
"properties": {
"instances": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"queue_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"instances",
"status",
"queue_length"
]
},
"pipelines": {
"type": "integer",
"minimum": -32768,
"maximum": 32767
}
},
"required": [
"chain_id",
"status",
"information",
"pipelines"
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/chain_validators/{chain_id}": {
"get": {
"description": "Introspect the state of a chain validator worker.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"pending_requests": {
"type": "array",
"items": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "Hash",
"type": "object",
"properties": {
"hash": {
"$ref": "#/components/schemas/block_hash"
}
},
"required": [
"hash"
]
},
{
"title": "Peer_id",
"type": "object",
"properties": {
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"peer_id"
]
}
]
}
},
"required": [
"pushed",
"request"
]
}
},
"current_request": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"treated": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "Hash",
"type": "object",
"properties": {
"hash": {
"$ref": "#/components/schemas/block_hash"
}
},
"required": [
"hash"
]
},
{
"title": "Peer_id",
"type": "object",
"properties": {
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"peer_id"
]
}
]
}
},
"required": [
"pushed",
"treated",
"request"
]
}
},
"required": [
"status",
"pending_requests"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/chain_validators/{chain_id}/ddb": {
"get": {
"description": "Introspect the state of the DDB attached to a chain validator worker.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"p2p_readers": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"active_chains": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"operation_db": {
"type": "object",
"properties": {
"table_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"scheduler_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"table_length",
"scheduler_length"
]
},
"operations_db": {
"type": "object",
"properties": {
"table_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"scheduler_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"table_length",
"scheduler_length"
]
},
"block_header_db": {
"type": "object",
"properties": {
"table_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"scheduler_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"table_length",
"scheduler_length"
]
},
"active_connections": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"active_peers": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"p2p_readers",
"active_chains",
"operation_db",
"operations_db",
"block_header_db",
"active_connections",
"active_peers"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/chain_validators/{chain_id}/peers_validators": {
"get": {
"description": "Lists the peer validator workers and their status.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"information": {
"type": "object",
"properties": {
"instances": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"queue_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"instances",
"status",
"queue_length"
]
},
"pipelines": {
"type": "object",
"properties": {
"fetched_headers": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"fetched_blocks": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"fetched_headers",
"fetched_blocks"
]
}
},
"required": [
"peer_id",
"status",
"information",
"pipelines"
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/chain_validators/{chain_id}/peers_validators/{peer_id}": {
"get": {
"description": "Introspect the state of a peer validator worker.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "peer_id",
"in": "path",
"description": "A cryptographic node identity (Base58Check-encoded)",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"pending_requests": {
"type": "array",
"items": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "New_head",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"new_head"
]
},
"block": {
"$ref": "#/components/schemas/block_hash"
}
},
"required": [
"request",
"block"
]
},
{
"title": "New_branch",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"new_branch"
]
},
"block": {
"$ref": "#/components/schemas/block_hash"
},
"locators": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"request",
"block",
"locators"
]
}
]
}
},
"required": [
"pushed",
"request"
]
}
},
"current_request": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"treated": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "New_head",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"new_head"
]
},
"block": {
"$ref": "#/components/schemas/block_hash"
}
},
"required": [
"request",
"block"
]
},
{
"title": "New_branch",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"new_branch"
]
},
"block": {
"$ref": "#/components/schemas/block_hash"
},
"locators": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"request",
"block",
"locators"
]
}
]
}
},
"required": [
"pushed",
"treated",
"request"
]
}
},
"required": [
"status",
"pending_requests"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/prevalidators": {
"get": {
"description": "Lists the Prevalidator workers and their status.",
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"chain_id": {
"$ref": "#/components/schemas/Chain_id"
},
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"information": {
"type": "object",
"properties": {
"instances": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"queue_length": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"instances",
"status",
"queue_length"
]
},
"pipelines": {
"type": "integer",
"minimum": -32768,
"maximum": 32767
}
},
"required": [
"chain_id",
"status",
"information",
"pipelines"
]
}
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
},
"/workers/prevalidators/{chain_id}": {
"get": {
"description": "Introspect the state of prevalidator workers.",
"parameters": [
{
"name": "chain_id",
"in": "path",
"description": "A chain identifier. This is either a chain hash in Base58Check notation or a one the predefined aliases: 'main', 'test'.",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"status": {
"oneOf": [
{
"title": "Launching",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"launching"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"running"
]
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"since"
]
},
{
"title": "Closing",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closing"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Closed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"closed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
}
},
"required": [
"phase",
"birth",
"since"
]
},
{
"title": "Crashed",
"type": "object",
"properties": {
"phase": {
"type": "string",
"enum": [
"crashed"
]
},
"birth": {
"$ref": "#/components/schemas/timestamp.system"
},
"since": {
"$ref": "#/components/schemas/timestamp.system"
},
"errors": {
"$ref": "#/components/schemas/error"
}
},
"required": [
"phase",
"birth",
"since",
"errors"
]
}
]
},
"pending_requests": {
"type": "array",
"items": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "Flush",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"flush"
]
},
"block": {
"$ref": "#/components/schemas/block_hash"
},
"event": {
"$ref": "#/components/schemas/chain_update"
}
},
"required": [
"request",
"block",
"event"
]
},
{
"title": "Notify",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"notify"
]
},
"peer": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"mempool": {
"$ref": "#/components/schemas/mempool"
}
},
"required": [
"request",
"peer",
"mempool"
]
},
{
"title": "Inject",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"inject"
]
},
"operation": {
"$ref": "#/components/schemas/operation"
},
"force": {
"type": "boolean"
}
},
"required": [
"request",
"operation",
"force"
]
},
{
"title": "Arrived",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"arrived"
]
},
"operation_hash": {
"$ref": "#/components/schemas/Operation_hash"
},
"operation": {
"$ref": "#/components/schemas/operation"
}
},
"required": [
"request",
"operation_hash",
"operation"
]
},
{
"title": "Advertise",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"advertise"
]
}
},
"required": [
"request"
]
},
{
"title": "Leftover",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"leftover"
]
}
},
"required": [
"request"
]
},
{
"title": "Ban",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"ban"
]
},
"operation_hash": {
"$ref": "#/components/schemas/Operation_hash"
}
},
"required": [
"request",
"operation_hash"
]
}
]
}
},
"required": [
"pushed",
"request"
]
}
},
"current_request": {
"type": "object",
"properties": {
"pushed": {
"$ref": "#/components/schemas/timestamp.system"
},
"treated": {
"$ref": "#/components/schemas/timestamp.system"
},
"request": {
"oneOf": [
{
"title": "Flush",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"flush"
]
},
"block": {
"$ref": "#/components/schemas/block_hash"
},
"event": {
"$ref": "#/components/schemas/chain_update"
}
},
"required": [
"request",
"block",
"event"
]
},
{
"title": "Notify",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"notify"
]
},
"peer": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"mempool": {
"$ref": "#/components/schemas/mempool"
}
},
"required": [
"request",
"peer",
"mempool"
]
},
{
"title": "Inject",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"inject"
]
},
"operation": {
"$ref": "#/components/schemas/operation"
},
"force": {
"type": "boolean"
}
},
"required": [
"request",
"operation",
"force"
]
},
{
"title": "Arrived",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"arrived"
]
},
"operation_hash": {
"$ref": "#/components/schemas/Operation_hash"
},
"operation": {
"$ref": "#/components/schemas/operation"
}
},
"required": [
"request",
"operation_hash",
"operation"
]
},
{
"title": "Advertise",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"advertise"
]
}
},
"required": [
"request"
]
},
{
"title": "Leftover",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"leftover"
]
}
},
"required": [
"request"
]
},
{
"title": "Ban",
"type": "object",
"properties": {
"request": {
"type": "string",
"enum": [
"ban"
]
},
"operation_hash": {
"$ref": "#/components/schemas/Operation_hash"
}
},
"required": [
"request",
"operation_hash"
]
}
]
}
},
"required": [
"pushed",
"treated",
"request"
]
}
},
"required": [
"status",
"pending_requests"
]
}
}
}
},
"default": {
"description": "",
"content": {
"application/json": {
"schema": {
"description": "The full list of errors is available with the global RPC `GET errors`"
}
}
}
}
}
}
}
},
"components": {
"schemas": {
"Chain_id": {
"title": "Network identifier (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"Context_hash": {
"title": "A hash of context (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"Crypto_box.Public_key_hash": {
"title": "A Cryptobox public key ID (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"Operation_hash": {
"title": "A Tezos operation ID (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"Operation_list_list_hash": {
"title": "A list of list of operations (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"Protocol_hash": {
"title": "A Tezos protocol ID (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"bignum": {
"title": "Big number",
"description": "Decimal representation of a big number",
"type": "string"
},
"block_hash": {
"title": "A block identifier (Base58Check-encoded)",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"block_header": {
"title": "Block header",
"description": "Block header. It contains both shell and protocol specific data.",
"type": "object",
"properties": {
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"proto": {
"type": "integer",
"minimum": 0,
"maximum": 255
},
"predecessor": {
"$ref": "#/components/schemas/block_hash"
},
"timestamp": {
"$ref": "#/components/schemas/timestamp.protocol"
},
"validation_pass": {
"type": "integer",
"minimum": 0,
"maximum": 255
},
"operations_hash": {
"$ref": "#/components/schemas/Operation_list_list_hash"
},
"fitness": {
"$ref": "#/components/schemas/fitness"
},
"context": {
"$ref": "#/components/schemas/Context_hash"
},
"protocol_data": {
"type": "string",
"pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$"
}
},
"required": [
"level",
"proto",
"predecessor",
"timestamp",
"validation_pass",
"operations_hash",
"fitness",
"context",
"protocol_data"
]
},
"chain_status": {
"description": "If 'unsynced', the node is not currently synchronized with of its peers (it is probably still bootstrapping and its head is lagging behind the chain's).\nIf 'synced', the node considers itself synchronized with its peers and the current head timestamp is recent.\nIf 'stuck', the node considers itself synchronized with its peers but the chain seems to be halted from its viewpoint.",
"type": "string",
"enum": [
"stuck",
"synced",
"unsynced"
]
},
"chain_update": {
"description": "If 'ignored', the new validated block is ignored since the current head fitness is better. If 'branch', we have set our head to a new validated block which is not the direct successor of the previous head. If 'increment', the new validated head is the direct successor of the previous head.",
"type": "string",
"enum": [
"branch",
"ignored",
"increment"
]
},
"distributed_db_version": {
"description": "A version number for the distributed DB protocol",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"distributed_db_version.name": {
"description": "A name for the distributed DB protocol",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"error": {
"description": "The full list of errors is available with the global RPC `GET errors`"
},
"fitness": {
"title": "Block fitness",
"description": "The fitness, or score, of a block, that allow the Tezos to decide which chain is the best. A fitness value is a list of byte sequences. They are compared as follows: shortest lists are smaller; lists of the same length are compared according to the lexicographical order.",
"type": "array",
"items": {
"type": "string",
"pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$"
}
},
"history_mode": {
"title": "history mode",
"description": "Storage mode for the Tezos shell.",
"oneOf": [
{
"title": "archive",
"description": "Archive mode retains every block and operations since the genesis block including their metadata and their associated contexts.",
"type": "string",
"enum": [
"archive"
]
},
{
"title": "full",
"description": "Full mode retains every block and operations since the genesis block but periodically prunes older blocks' metadata to reduce the storage size.",
"type": "object",
"properties": {
"full": {
"type": "object",
"properties": {
"additional_cycles": {
"title": "additional cycles",
"description": "Number of additional cycles preserved below the savepoint. By default: 1 additional cycles will be stored.",
"type": "integer",
"minimum": 0,
"maximum": 1000
}
},
"required": [
"additional_cycles"
]
}
},
"required": [
"full"
]
},
{
"title": "rolling",
"description": "Rolling mode only retain the most recent cycles by periodically periodically discarding older blocks to reduce the storage size.",
"type": "object",
"properties": {
"rolling": {
"type": "object",
"properties": {
"additional_cycles": {
"title": "additional cycles",
"description": "Number of additional cycles preserved below the savepoint. By default: 1 additional cycles will be stored.",
"type": "integer",
"minimum": 0,
"maximum": 1000
}
},
"required": [
"additional_cycles"
]
}
},
"required": [
"rolling"
]
},
{
"title": "full_alias",
"description": "Full mode with default number of additional cycles.",
"type": "string",
"enum": [
"full"
]
},
{
"title": "rolling_alias",
"description": "Rolling mode with default number of additional cycles.",
"type": "string",
"enum": [
"rolling"
]
}
]
},
"int64": {
"title": "64 bit integers",
"description": "Decimal representation of 64 bit integers",
"type": "string"
},
"mempool": {
"description": "A batch of operation. This format is used to gossip operations between peers.",
"type": "object",
"properties": {
"known_valid": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Operation_hash"
}
},
"pending": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Operation_hash"
}
}
},
"required": [
"known_valid",
"pending"
]
},
"network_version": {
"description": "A version number for the network protocol (includes distributed DB version and p2p version)",
"type": "object",
"properties": {
"chain_name": {
"$ref": "#/components/schemas/distributed_db_version.name"
},
"distributed_db_version": {
"$ref": "#/components/schemas/distributed_db_version"
},
"p2p_version": {
"$ref": "#/components/schemas/p2p_version"
}
},
"required": [
"chain_name",
"distributed_db_version",
"p2p_version"
]
},
"operation": {
"description": "An operation. The shell_header part indicates a block an operation is meant to apply on top of. The proto part is protocol-specific and appears as a binary blob.",
"type": "object",
"properties": {
"branch": {
"$ref": "#/components/schemas/block_hash"
},
"data": {
"type": "string",
"pattern": "^([a-zA-Z0-9][a-zA-Z0-9])*$"
}
},
"required": [
"branch",
"data"
]
},
"operation_metadata_size_limit": {
"title": "operation_metadata_size_limit",
"description": "The operation metadata size limit",
"oneOf": [
{
"title": "unlimited",
"description": "The metadata size is unlimited.",
"type": "string",
"enum": [
"unlimited"
]
},
{
"title": "limited",
"description": "The metadata size is limited to the given integer's value (in bytes).",
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
]
},
"p2p_address": {
"description": "An address for locating peers.",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"p2p_connection.id": {
"description": "The identifier for a p2p connection. It includes an address and a port number.",
"type": "object",
"properties": {
"addr": {
"$ref": "#/components/schemas/p2p_address"
},
"port": {
"type": "integer",
"minimum": 0,
"maximum": 65535
}
},
"required": [
"addr"
]
},
"p2p_peer.pool_event": {
"description": "An event that may happen during maintenance of and other operations on the connection to a specific peer.",
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": [
"rejecting_request",
"incoming_request",
"disconnection",
"external_disconnection",
"connection_established",
"request_rejected"
]
},
"timestamp": {
"$ref": "#/components/schemas/timestamp.system"
},
"addr": {
"$ref": "#/components/schemas/p2p_address"
},
"port": {
"type": "integer",
"minimum": 0,
"maximum": 65535
}
},
"required": [
"kind",
"timestamp",
"addr"
]
},
"p2p_peer.state": {
"description": "The state a peer connection can be in: accepted (when the connection is being established), running (when the connection is already established), disconnected (otherwise).",
"type": "string",
"enum": [
"running",
"accepted",
"disconnected"
]
},
"p2p_point.id": {
"description": "Identifier for a peer point",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"p2p_point.info": {
"description": "Information about a peer point. Includes flags, state, and records about past events.",
"type": "object",
"properties": {
"trusted": {
"type": "boolean"
},
"greylisted_until": {
"$ref": "#/components/schemas/timestamp.system"
},
"state": {
"$ref": "#/components/schemas/p2p_point.state"
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
"last_failed_connection": {
"$ref": "#/components/schemas/timestamp.system"
},
"last_rejected_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_established_connection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_disconnection": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_seen": {
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
},
{
"$ref": "#/components/schemas/timestamp.system"
}
]
}
},
"last_miss": {
"$ref": "#/components/schemas/timestamp.system"
},
"expected_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"trusted",
"state"
]
},
"p2p_point.pool_event": {
"description": "Events happening during maintenance of and operations on a peer point pool (such as connections, disconnections, connection requests).",
"type": "array",
"items": {
"oneOf": [
{
"$ref": "#/components/schemas/timestamp.system"
},
{
"oneOf": [
{
"title": "Outgoing_request",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"outgoing_request"
]
}
},
"required": [
"event_kind"
]
},
{
"title": "Accepting_request",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"accepting_request"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind",
"p2p_peer_id"
]
},
{
"title": "Rejecting_request",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"rejecting_request"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind",
"p2p_peer_id"
]
},
{
"title": "Rejecting_rejected",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"request_rejected"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind"
]
},
{
"title": "Connection_established",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"rejecting_request"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind",
"p2p_peer_id"
]
},
{
"title": "Disconnection",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"rejecting_request"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind",
"p2p_peer_id"
]
},
{
"title": "External_disconnection",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"rejecting_request"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind",
"p2p_peer_id"
]
}
]
}
]
}
},
"p2p_point.state": {
"description": "The state a connection to a peer point can be in: requested (connection open from here), accepted (handshake), running (connection already established), disconnected (no connection).",
"oneOf": [
{
"title": "Requested",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"requested"
]
}
},
"required": [
"event_kind"
]
},
{
"title": "Accepted",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"accepted"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind",
"p2p_peer_id"
]
},
{
"title": "Running",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"running"
]
},
"p2p_peer_id": {
"$ref": "#/components/schemas/Crypto_box.Public_key_hash"
}
},
"required": [
"event_kind",
"p2p_peer_id"
]
},
{
"title": "Disconnected",
"type": "object",
"properties": {
"event_kind": {
"type": "string",
"enum": [
"disconnected"
]
}
},
"required": [
"event_kind"
]
}
]
},
"p2p_stat": {
"description": "Statistics about the p2p network.",
"type": "object",
"properties": {
"total_sent": {
"$ref": "#/components/schemas/int64"
},
"total_recv": {
"$ref": "#/components/schemas/int64"
},
"current_inflow": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
},
"current_outflow": {
"type": "integer",
"minimum": -1073741824,
"maximum": 1073741823
}
},
"required": [
"total_sent",
"total_recv",
"current_inflow",
"current_outflow"
]
},
"p2p_version": {
"description": "A version number for the p2p layer.",
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"protocol.environment_version": {
"type": "integer",
"minimum": 0,
"maximum": 65535
},
"timespan.system": {
"description": "A span of time, as seen by the local computer.",
"type": "number"
},
"timestamp.protocol": {
"description": "A timestamp as seen by the protocol: second-level precision, epoch based.",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"timestamp.rfc": {
"title": "RFC 3339 formatted timestamp",
"description": "A date in RFC 3339 notation.",
"oneOf": [
{
"$ref": "#/components/schemas/unistring"
}
]
},
"timestamp.system": {
"description": "A timestamp as seen by the underlying, local computer: subsecond-level precision, epoch or rfc3339 based.",
"oneOf": [
{
"title": "RFC encoding",
"oneOf": [
{
"$ref": "#/components/schemas/timestamp.rfc"
}
]
},
{
"title": "Second since epoch",
"oneOf": [
{
"$ref": "#/components/schemas/int64"
}
]
}
]
},
"unistring": {
"title": "Universal string representation",
"description": "Either a plain UTF8 string, or a sequence of bytes for strings that contain invalid byte sequences.",
"oneOf": [
{
"type": "string"
},
{
"type": "object",
"properties": {
"invalid_utf8_string": {
"type": "array",
"items": {
"type": "integer",
"minimum": 0,
"maximum": 255
}
}
},
"required": [
"invalid_utf8_string"
]
}
]
},
"user_activated.protocol_overrides": {
"title": "User activated protocol overrides",
"description": "User activated protocol overrides: activate a protocol instead of another.",
"type": "array",
"items": {
"type": "object",
"properties": {
"replaced_protocol": {
"$ref": "#/components/schemas/Protocol_hash"
},
"replacement_protocol": {
"$ref": "#/components/schemas/Protocol_hash"
}
},
"required": [
"replaced_protocol",
"replacement_protocol"
]
}
},
"user_activated.upgrades": {
"title": "User activated upgrades",
"description": "User activated upgrades: at given level, switch to given protocol.",
"type": "array",
"items": {
"type": "object",
"properties": {
"level": {
"type": "integer",
"minimum": -2147483648,
"maximum": 2147483647
},
"replacement_protocol": {
"$ref": "#/components/schemas/Protocol_hash"
}
},
"required": [
"level",
"replacement_protocol"
]
}
}
}
}
}