90 Commits

Author SHA1 Message Date
coopops f136c81668 ci: добавить workflow_dispatch (триггер пересборки из mono на Gitea)
Publish Coopenomics Website / build-and-publish-docs (push) Failing after 9m2s
Gitea не имеет API для repository_dispatch (только workflow_dispatch), поэтому
mono/release.yaml (job trigger-coopenomics-docs) после переезда на Gitea дёргает
этот workflow через workflow_dispatch API. Входы mono_sha/mono_ref информативные.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-25 10:27:06 +00:00
coopops 479576cd2c [mp2-6][@ant] ci: клонировать mono@marketplace2 в publish-docs — реестр стандартов docs.coopenomics.world должен видеть три новых yaml (p.mkt.supply/return/wroff), которые лежат только на marketplace2; main отстаёт, dev/reports их не содержат, поэтому временно нацеливаем сборку на ветку с актуальным срезом — вернём main после мержа marketplace2 в опубликованный срез 2026-05-04 14:58:22 +00:00
coopops a821d4a476 [350-1][@ant] ci: Node 20 → 22 в publish-docs — desktop из mono@main требует Node 22.22+ (quasar prepare падает на 20), в mono-репе workflow уже на 22, приводим к одной версии 2026-04-23 17:37:18 +00:00
coopops cfe32f6614 [350-1][@ant] ci: клонировать mono@main в publish-docs — только опубликованный срез попадает в docs.coopenomics.world (dev слишком бурлящий, capital отстаёт), стандарты/типы/SDK публикуются синхронно с релизами mono 2026-04-23 17:33:06 +00:00
coopops 0f9c57eaf5 [350-1][@ant] ci: клонировать mono@dev вместо mono@capital в publish-docs — standards-site и обновлённые ledger2-реестры живут в dev, capital отстаёт, иначе все mono-артефакты (/contracts, /cooptypes, /sdk, /standards) в docs.coopenomics.world берутся с устаревшего среза 2026-04-23 17:32:22 +00:00
coopops 763b410d33 [350-1][@ant] ci: переставить копирование standards-site из site/ в docs/ ДО mkdocs build — тот же паттерн что у /contracts, /cooptypes, /sdk; иначе dist не долетал до site/ и в gh-pages ветку ничего не уезжало 2026-04-23 14:07:46 +00:00
coopops 0e115d03ff [350-1][@ant] docs: поставить «Реестр стандартов: /standards» рядом с /contracts и /cooptypes в nav — все sub-site референсы в одном логическом блоке внизу, относительный путь вместо абсолютного URL как в аналогах 2026-04-23 13:43:02 +00:00
coopops 29d351d54c [350-1][@ant] fix: сделать шаги сборки standards-site в publish-docs идемпотентно-проходимыми — пока graph-standarts не смержен в капитал-ветку mono, клон не содержит components/contracts/standards-site/ и pnpm run build рушит весь деплой документации; оборачиваем в if -d чтобы workflow продолжал публиковать mkdocs-часть как раньше, а standards-site подтянется автоматически после первого же мёржа 2026-04-23 10:45:59 +00:00
coopops a76112d718 [350-1][@ant] feat: подключить standards-site к публикации docs.coopenomics.world — после клонирования mono-repo и mkdocs build workflow поднимает standards-site (pnpm install + build с base=/standards/) и копирует dist в site/standards, а в mkdocs nav добавлен внешний линк «Реестр стандартов», чтобы председатели с публичного сайта кооперативной экономики попадали прямо на BPMN-граф процессов из единого YAML-источника правды 2026-04-23 10:45:10 +00:00
coopops fa961febab cleanup unused docs 2026-04-19 06:55:12 +00:00
Alex Ant ec543d7245 update 2026-03-22 21:18:27 +05:00
Alex Ant c1ace24b38 factory 2026-03-22 14:56:06 +05:00
Alex Ant db27fc2c7a cdt docs update 2026-03-22 13:39:55 +05:00
Alex Ant 41fb8d82a4 75% ready 2026-03-21 20:12:04 +05:00
Alex Ant 49188d404e update 2026-03-20 23:37:38 +05:00
Alex Ant 04281a2606 update 2026-03-20 20:00:46 +05:00
Alex Ant 519f34eecb update 2026-03-20 19:18:34 +05:00
Alex Ant 17c5905067 rework 2025-12-02 22:43:20 +05:00
Alex Ant 34e19f5a9c change domain 2025-12-02 20:32:57 +05:00
Alex Ant 63673a3297 fix publish large file 2025-11-24 19:08:06 +05:00
Alex Ant 0e3b1f178f update 2025-09-18 19:39:44 +05:00
Alex Ant 9f560a8bf7 update 2025-09-18 19:39:30 +05:00
Alex Ant 3a534e6af1 update 2025-09-18 19:08:46 +05:00
Alex Ant ca383f14f5 add all swagger docs from coopos 2025-08-27 14:09:51 +05:00
Alex Ant 7193a89dad make chain-api docs 2025-08-27 13:54:07 +05:00
Alex Ant bfd5a11f94 workflow 2025-08-27 00:19:24 +05:00
Alex Ant 744ef05aa7 doxygen downgrade 2025-08-26 22:52:23 +05:00
Alex Ant d0b20da868 downgrade doxygen 2025-08-26 20:58:58 +05:00
Alex Ant e9e59b9d17 update 2025-08-26 20:50:20 +05:00
Alex Ant aca97c83c3 update 2025-08-26 20:42:12 +05:00
Alex Ant 213d1b64b9 update 2025-08-26 20:23:41 +05:00
Alex Ant 0c22c73f67 update 2025-08-26 20:16:38 +05:00
Alex Ant cbbb46c5b5 update 2025-08-26 20:02:20 +05:00
Alex Ant 8c49480eb2 update 2025-08-26 20:01:39 +05:00
Alex Ant 30a4646cc0 docs automation #1 2025-08-26 19:57:55 +05:00
Alex Ant 8128161964 update 2025-05-29 10:14:06 +05:00
Alex Ant 821718342b update 2025-05-28 22:56:22 +05:00
Alex Ant 1ada97065e update 2025-04-11 19:25:41 +05:00
Alex Ant aaaebb138e update 2025-04-05 15:40:01 +05:00
Alex Ant 8307b3ba59 udpate 2025-02-01 20:44:15 +05:00
Alex Ant a32826c26c update 2024-11-27 14:14:29 +05:00
Alex Ant 2ef74a0046 update 2024-11-24 19:04:08 +05:00
Alex Ant 05cbd56acf update 2024-11-23 23:28:16 +05:00
Alex Ant 2c7556728f TSK-196: update check 2024-09-26 11:05:46 +05:00
Alex Ant c9bceeb22e TSK-196 update 2024-09-26 00:13:04 +05:00
Alex Ant eb02927383 Fixes: TSK-196 2024-09-26 00:09:33 +05:00
Alex Ant cf05493deb update #TSK-196 TSK-196 2024-09-26 00:07:01 +05:00
Alex Ant f43de8a140 TSK-196 correction and update 2024-09-25 23:55:57 +05:00
Alex Ant 34be86e50e platform finish 2024-08-21 17:06:30 +05:00
Alex Ant a9931ead16 platform 2024-08-20 22:07:50 +05:00
Alex Ant 2bb7a998bd update 2024-08-19 20:09:01 +05:00
Alex Ant a6218d6510 update 2024-08-19 20:07:42 +05:00
Alex Ant 6ff9a9523e update 2024-07-22 10:41:40 +05:00
Alex Ant 59d9007a57 update 2024-06-24 17:37:48 +05:00
Alex Ant a07cfde5a7 update 2024-06-24 16:27:42 +05:00
Alex Ant fbfc014ba5 update 2024-06-24 16:05:25 +05:00
Alex Ant f84f4e27ed update 2024-06-24 16:02:29 +05:00
Alex Ant 8768614141 update 2024-06-24 15:34:10 +05:00
Alex Ant 7cfe2b864c update 2024-06-24 15:24:13 +05:00
Alex Ant ae1a2bf1ca disable plugin 2024-06-24 15:21:07 +05:00
Alex Ant 4ee6a97dc7 gitignore 2024-06-24 15:19:01 +05:00
Alex Ant 2ad2917b6a Merge branch 'master' into big-update 2024-06-24 15:17:50 +05:00
Alex Ant dbb8c172fa release 2024-06-24 15:11:33 +05:00
Alex Ant f19a8ef924 update 2024-06-01 14:10:28 +05:00
Alex Ant 8079012ba8 update 2024-05-23 22:45:53 +05:00
Alex Ant d0bb0f9612 update 2024-04-30 14:53:26 +03:00
Dark Sun bcc4dfba3c update 2024-04-09 23:45:29 +03:00
Dark Sun a4bd35ed99 invite 2024-04-09 23:40:14 +03:00
Dark Sun 397ed33dcc update 2024-04-09 23:06:44 +03:00
Dark Sun ce4733014c update 2024-02-03 11:57:13 +05:00
Dark Sun aaf8849e5d push 2024-01-30 20:09:47 +05:00
Dark Sun 8e214ea276 update 2024-01-01 22:47:07 +05:00
Dark Sun 67f72fc0a5 update 2023-12-29 00:45:21 +05:00
Dark Sun 4873bde14e update 2023-12-29 00:38:47 +05:00
Dark Sun 75ab75e254 update 2023-12-12 00:54:58 +03:00
Dark Sun 47584feac5 update 2023-12-08 01:25:13 +03:00
Dark Sun 203f83cdf2 update 2023-12-07 01:24:10 +03:00
Dark Sun d23c297173 update 2023-12-07 01:09:26 +03:00
Dark Sun 179c50a1f5 update 2023-12-07 01:03:52 +03:00
Dark Sun 9d1109e99e update 2023-12-05 21:18:41 +03:00
Dark Sun 46677200f3 update 2023-12-05 21:12:56 +03:00
Dark Sun 6fb0eea334 update 2023-12-05 00:51:00 +03:00
Dark Sun da97bc391e update 2023-12-04 21:19:32 +03:00
Alex Ant 042de58748 Update mkdocs.yml 2023-11-04 13:32:02 +03:00
Alex Ant 601ccbcc4d Update mkdocs.yml 2023-11-04 13:03:12 +03:00
Dark Sun f9765abf31 update 2023-10-19 22:33:01 +03:00
Dark Sun 8eb2ea3eff update 2023-10-19 22:24:08 +03:00
Dark Sun 734b2ecf9e update 2023-10-19 19:52:58 +03:00
Alex Ant 8a24da4e35 Merge pull request #2 from DICoop/igor
Update index.md
2023-10-19 18:52:45 +03:00
Alex Ant f7f6c65b79 Merge pull request #1 from DICoop/igor
Update index.md
2023-10-19 18:07:42 +03:00
1726 changed files with 225125 additions and 1374 deletions
Vendored
BIN
View File
Binary file not shown.
+1
View File
@@ -0,0 +1 @@
BASE_PATH=~/dacom-code/foundation
-27
View File
@@ -1,27 +0,0 @@
name: ci
on:
push:
branches:
- master
- main
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.x
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
- uses: actions/cache@v3
with:
key: mkdocs-material-${{ env.cache_id }}
path: .cache
restore-keys: |
mkdocs-material-
- run: pip install mkdocs-material
- run: pip install mkdocs-awesome-pages-plugin
- run: pip install mkdocs-toc-md
- run: mkdocs gh-deploy --force
+183
View File
@@ -0,0 +1,183 @@
name: Publish Coopenomics Website
on:
push:
branches:
- master
repository_dispatch:
types: [deploy_from_mono]
# Gitea не умеет repository_dispatch через API — mono дёргает пересборку
# через workflow_dispatch (см. mono/.github/workflows/release.yaml,
# job trigger-coopenomics-docs). Входы информативные, билд их не использует.
workflow_dispatch:
inputs:
mono_sha:
description: 'SHA коммита в mono, инициировавшего пересборку'
required: false
default: ''
mono_ref:
description: 'ref в mono (тег/ветка)'
required: false
default: ''
jobs:
build-and-publish-docs:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Clone mono repository
run: |
git clone https://github.com/coopenomics/mono.git mono-repo
cd mono-repo
git checkout marketplace2
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install Doxygen 1.9.3
run: |
curl -L "https://sourceforge.net/projects/doxygen/files/rel-1.9.3/doxygen-1.9.3.linux.bin.tar.gz/download" -o doxygen.tar.gz
tar xzf doxygen.tar.gz
sudo cp doxygen-1.9.3/bin/doxygen /usr/local/bin/
doxygen --version
- name: Install pnpm
run: npm install -g pnpm
- name: Install redocly
run: npm install -g @redocly/cli
- name: Install Python requirements
run: |
python -m venv venv
source venv/bin/activate
pip install mkdocs-material mkdocs-macros-plugin mkdocs-section-index pymdown-extensions
- name: Install Node.js dependencies
run: pnpm install
- name: Generate contracts documentation with Doxygen
run: |
cd mono-repo/components/contracts
doxygen
- name: Generate cooptypes docs
run: |
cd mono-repo/components/cooptypes
pnpm install
pnpm run build
pnpm run docs
- name: Generate SDK documentation
run: |
cd mono-repo/components/sdk
pnpm install
pnpm run build
pnpm run docs
- name: Generate Chain API documentation
run: |
mkdir -p docs/api/chain
redocly build-docs coopos/chain.swagger.yaml --output docs/api/chain/index.html
- name: Generate DB Size API documentation
run: |
mkdir -p docs/api/db_size
redocly build-docs coopos/db_size.swagger.yaml --output docs/api/db_size/index.html
- name: Generate Net API documentation
run: |
mkdir -p docs/api/net
redocly build-docs coopos/net.swagger.yaml --output docs/api/net/index.html
- name: Generate Trace API documentation
run: |
mkdir -p docs/api/trace
redocly build-docs coopos/trace_api.swagger.yaml --output docs/api/trace/index.html
- name: Generate Producer API documentation
run: |
mkdir -p docs/api/producer
redocly build-docs coopos/producer.swagger.yaml --output docs/api/producer/index.html
# Redocly вшивает redoc.standalone.js с cdn.redocly.com — из РФ/части сетей CDN таймаутит.
# Кладём тот же артефакт рядом со страницами и подменяем src на относительный путь.
- name: Self-host Redoc bundle (replace CDN)
run: |
set -e
VER=$(grep -hoE 'cdn\.redocly\.com/redoc/[^/]+' docs/api/*/index.html 2>/dev/null | head -1 | sed 's|.*/||')
if [ -z "$VER" ]; then
if ls docs/api/*/index.html >/dev/null 2>&1; then
echo "ERROR: есть docs/api/*/index.html, но не найден cdn.redocly.com — формат вывода Redocly сменился."
exit 1
fi
exit 0
fi
curl -fsSL "https://cdn.jsdelivr.net/npm/redoc@${VER}/bundles/redoc.standalone.js" -o docs/api/redoc.standalone.js
for f in docs/api/*/index.html; do
sed -i 's|https://cdn\.redocly\.com/redoc/[^/]*/bundles/redoc\.standalone\.js|../redoc.standalone.js|g' "$f"
done
- name: Copy contracts documentation
run: |
mkdir -p docs/contracts
cp -r mono-repo/components/contracts/docs/html/* docs/contracts/
- name: Copy SDK documentation
run: |
mkdir -p docs/sdk
rsync -av --exclude='typedoc.json' mono-repo/components/sdk/docs/ docs/sdk/
- name: Copy cooptypes documentation
run: |
mkdir -p docs/cooptypes
cp -r mono-repo/components/cooptypes/docs/* docs/cooptypes/
# ── standards-site → /standards/ на docs.coopenomics.world ───────
# Отдельный Vue-сайт с BPMN-графом кооперативных стандартов;
# Vite собирает с base='/standards/' (см. vite.config.ts), dist
# кладётся в docs/standards/ ДО mkdocs build — mkdocs сам
# включит статику в итоговый site/ как обычные ассеты.
# Пока graph-standarts не смержен в капитал-ветку клона — шаг
# пропускается (`components/contracts/standards-site/` отсутствует).
- name: Build standards-site
run: |
if [ -d mono-repo/components/contracts/standards-site ]; then
cd mono-repo/components/contracts/standards-site
pnpm install
pnpm run build
else
echo "⚠ standards-site отсутствует в клонированной ветке mono — пропускаем сборку"
fi
- name: Copy standards-site into docs/standards
run: |
if [ -d mono-repo/components/contracts/standards-site/dist ]; then
mkdir -p docs/standards
cp -r mono-repo/components/contracts/standards-site/dist/* docs/standards/
else
echo "⚠ dist/ standards-site не собран — пропускаем копирование"
fi
- name: Build docs (mkdocs)
run: |
source venv/bin/activate
mkdocs build
- name: Publish to GitHub Pages
run: npx gh-pages --nojekyll -d site --repo https://x-access-token:${GITHUB_TOKEN}@github.com/coopenomics/coopenomics.git
env:
GIT_AUTHOR_NAME: github-actions
GIT_AUTHOR_EMAIL: github-actions@github.com
GIT_COMMITTER_NAME: github-actions
GIT_COMMITTER_EMAIL: github-actions@github.com
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+2
View File
@@ -0,0 +1,2 @@
node_modules
site
+962
View File
@@ -0,0 +1,962 @@
openapi: 3.0.0
info:
title: API цепи COOPOS
description: Спецификация Chain API узла COOPOS (nodeos). Подробности — в документации на https://coopenomics.world.
version: 1.0.0
license:
name: MIT
url: https://opensource.org/licenses/MIT
contact:
url: https://coopenomics.world
servers:
- url: "{protocol}://{host}:{port}/v1/chain"
variables:
protocol:
enum:
- http
- https
default: http
host:
default: localhost
port:
default: "8080"
components:
schemas: {}
paths:
/get_account:
post:
summary: Сведения об учётной записи
description: Возвращает объект с подробностями об указанной учётной записи в блокчейне.
operationId: get_account
requestBody:
description: JSON-объект с единственным полем «account_name»
content:
application/json:
schema:
type: object
required:
- account_name
properties:
account_name:
$ref: "schemas/Name.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
$ref: "schemas/Account.yaml"
/get_block:
post:
summary: Получить блок
description: Возвращает объект с подробностями об указанном блоке блокчейна.
operationId: get_block
requestBody:
content:
application/json:
schema:
type: object
required:
- block_num_or_id
properties:
block_num_or_id:
type: string
description: Укажите номер блока или идентификатор блока
responses:
"200":
description: Успешно
content:
application/json:
schema:
$ref: "schemas/Block.yaml"
/get_block_info:
post:
summary: Краткие сведения о блоке
description: Аналогично `get_block`, но возвращает фиксированный урезанный набор данных блока меньшего размера.
operationId: get_block_info
requestBody:
content:
application/json:
schema:
type: object
required:
- block_num
properties:
block_num:
type: integer
description: Укажите номер блока
responses:
"200":
description: Успешно
content:
application/json:
schema:
$ref: "schemas/BlockInfo.yaml"
/get_info:
post:
summary: Общие сведения о цепи
description: Возвращает объект с общими сведениями о блокчейне.
operationId: get_info
security: []
responses:
"200":
description: Успешно
content:
application/json:
schema:
$ref: "schemas/Info.yaml"
/push_transaction:
post:
summary: Применить транзакцию (push)
description: Ожидает транзакцию в формате JSON и пытается применить её к блокчейну.
operationId: push_transaction
requestBody:
content:
application/json:
schema:
type: object
properties:
signatures:
type: array
description: Массив подписей, необходимых для авторизации транзакции
items:
$ref: "schemas/Signature.yaml"
compression:
type: boolean
description: Использование сжатия; обычно false
packed_context_free_data:
type: string
description: JSON в шестнадцатеричном виде
packed_trx:
type: string
description: Объект транзакции (JSON) в шестнадцатеричном виде
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: Тело ответа пустое
/send_transaction:
post:
summary: Применить транзакцию (send)
description: Ожидает транзакцию в формате JSON и пытается применить её к блокчейну.
operationId: send_transaction
requestBody:
content:
application/json:
schema:
type: object
properties:
signatures:
type: array
description: Массив подписей, необходимых для авторизации транзакции
items:
$ref: "schemas/Signature.yaml"
compression:
type: boolean
description: Использование сжатия; обычно false
packed_context_free_data:
type: string
description: JSON в шестнадцатеричном виде
packed_trx:
type: string
description: Объект транзакции (JSON) в шестнадцатеричном виде
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: Тело ответа пустое
/push_transactions:
post:
summary: Применить несколько транзакций
description: Ожидает одну или несколько транзакций в формате JSON и пытается применить их к блокчейну.
operationId: push_transactions
requestBody:
content:
application/json:
schema:
type: array
items:
$ref: "schemas/Transaction.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: Тело ответа пустое
/get_block_header_state:
post:
summary: Состояние заголовка блока
description: Возвращает состояние заголовка блока.
operationId: get_block_header_state
requestBody:
content:
application/json:
schema:
type: object
required:
- block_num_or_id
properties:
block_num_or_id:
type: string
description: Укажите номер блока или идентификатор блока
responses:
"200":
description: Успешно
content:
application/json:
schema:
$ref: "schemas/BlockHeaderState.yaml"
/get_abi:
post:
summary: ABI контракта
description: Возвращает ABI контракта по имени учётной записи.
operationId: get_abi
requestBody:
content:
application/json:
schema:
type: object
required:
- account_name
properties:
account_name:
$ref: "schemas/Name.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
$ref: "schemas/Abi.yaml"
/get_currency_balance:
post:
summary: Баланс токена
description: Возвращает текущий баланс токена.
operationId: get_currency_balance
requestBody:
content:
application/json:
schema:
type: object
required:
- code
- account
- symbol
properties:
code:
$ref: "schemas/Name.yaml"
account:
$ref: "schemas/Name.yaml"
symbol:
$ref: "schemas/Symbol.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: array
items:
$ref: "schemas/Symbol.yaml"
/get_currency_stats:
post:
summary: Статистика токена
description: Возвращает статистику по выпуску валюты (токена).
operationId: get_currency_stats
requestBody:
content:
application/json:
schema:
type: object
properties:
code:
$ref: "schemas/Name.yaml"
symbol:
$ref: "schemas/Symbol.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: "Объект с одним ключом — запрошенный символ; внутри поля: supply (Symbol), max_supply (Symbol), issuer (Name)"
/get_required_keys:
post:
summary: Ключи для подписи транзакции
description: Возвращает ключи, необходимые для подписи транзакции.
operationId: get_required_keys
requestBody:
content:
application/json:
schema:
type: object
required:
- transaction
- available_keys
properties:
transaction:
$ref: "schemas/Transaction.yaml"
available_keys:
type: array
description: Доступные публичные ключи
items:
$ref: "schemas/PublicKey.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
{}
/get_producers:
post:
summary: Список продюсеров
description: Возвращает список продюсеров блокчейна.
operationId: get_producers
requestBody:
content:
application/json:
schema:
title: "GetProducersRequest"
type: object
required:
- limit
- lower_bound
properties:
limit:
type: string
description: Сколько продюсеров вернуть
lower_bound:
type: string
description: Вместе с limit задаёт постраничную выборку; например limit=10 и lower_bound=10 — вторая страница
json:
type: boolean
description: Вернуть результат в формате JSON
responses:
"200":
description: Успешно
content:
application/json:
schema:
title: "GetProducersResponse"
type: object
properties:
rows:
type: array
nullable: true
items:
$ref: "schemas/Producer.yaml"
total_producer_vote_weight:
type: string
description: Сумма весов голосов за всех продюсеров.
more:
type: string
description: Если не все продюсеры поместились в ответ, здесь нижняя граница для следующего запроса.
/get_raw_code_and_abi:
post:
summary: Сырой WASM и ABI
description: Возвращает сырой WASM и ABI контракта по имени учётной записи.
operationId: get_raw_code_and_abi
requestBody:
content:
application/json:
schema:
type: object
required:
- account_name
properties:
account_name:
$ref: "schemas/Name.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
account_name:
$ref: "schemas/Name.yaml"
wasm:
type: string
description: WASM в кодировке base64
abi:
type: string
description: ABI в кодировке base64
/get_scheduled_transactions:
post:
summary: Запланированные транзакции
description: Возвращает отложенные (запланированные) транзакции.
operationId: get_scheduled_transactions
requestBody:
content:
application/json:
schema:
type: object
properties:
lower_bound:
$ref: "schemas/DateTimeSeconds.yaml"
limit:
description: Максимальное число транзакций в ответе
type: integer
json:
description: true — упакованная транзакция преобразуется в JSON
type: boolean
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
transactions:
type: array
items:
$ref: "schemas/Transaction.yaml"
/get_table_by_scope:
post:
summary: Области таблиц (scopes)
description: Возвращает области (scopes) таблиц контракта.
operationId: get_table_by_scope
requestBody:
content:
application/json:
schema:
type: object
required:
- code
properties:
code:
type: string
description: "Имя (`name`) контракта, для которого нужны данные таблиц"
table:
type: string
description: Фильтр по имени таблицы
lower_bound:
type: string
description: Первый элемент не меньше указанного значения в упорядоченном наборе
upper_bound:
type: string
description: Первый элемент строго больше указанного значения в упорядоченном наборе
limit:
type: integer
description: Ограничение числа записей в ответе.
format: int32
default: 10
reverse:
type: boolean
description: Обратить порядок строк
default: false
show_payer:
type: boolean
description: Показывать плательщика RAM
default: false
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
rows:
type: array
items:
$ref: "schemas/TableScope.yaml"
more:
$ref: "schemas/Name.yaml"
/get_table_rows:
post:
summary: Строки таблицы состояния
description: Возвращает строки указанной таблицы состояния контракта.
operationId: get_table_rows
requestBody:
content:
application/json:
schema:
type: object
required:
- code
- table
- scope
properties:
code:
type: string
description: Имя смарт-контракта, которому принадлежит таблица
table:
type: string
description: Имя таблицы
scope:
type: string
description: Учётная запись-владелец данных (scope)
index_position:
type: string
description: Позиция индекса; допустимые значения `primary`, `secondary`, `tertiary`, `fourth`, `fifth`, `sixth`, `seventh`, `eighth`, `ninth`, `tenth`
key_type:
type: string
description: Тип ключа для index_position (например `uint64_t` или `name`)
encode_type:
type: string
lower_bound:
type: string
description: Первый элемент не меньше указанного значения
upper_bound:
type: string
description: Первый элемент строго больше указанного значения
limit:
type: integer
description: Ограничение числа строк в ответе.
format: int32
default: 10
reverse:
type: boolean
description: Обратить порядок строк
default: false
show_payer:
type: boolean
description: Показывать плательщика RAM
default: false
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
rows:
type: array
items: {}
/get_code:
post:
summary: Код контракта (WASM)
description: Возвращает объект с WASM-кодом смарт-контракта.
operationId: get_code
requestBody:
content:
application/json:
schema:
type: object
required:
- account_name
- code_as_wasm
properties:
account_name:
$ref: "schemas/Name.yaml"
code_as_wasm:
type: integer
default: 1
description: Должно быть 1 (истина)
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
title: GetCodeResponse.yaml
properties:
name:
$ref: "schemas/Name.yaml"
code_hash:
$ref: "schemas/Sha256.yaml"
wast:
type: string
wasm:
type: string
abi:
$ref: "schemas/Abi.yaml"
/get_raw_abi:
post:
summary: Сырой ABI контракта
description: Возвращает объект с сырым ABI смарт-контракта.
operationId: get_raw_abi
requestBody:
content:
application/json:
schema:
type: object
required:
- account_name
properties:
account_name:
$ref: "schemas/Name.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
account_name:
$ref: "schemas/Name.yaml"
code_hash:
$ref: "schemas/Sha256.yaml"
abi_hash:
allOf:
- $ref: "schemas/Sha256.yaml"
abi:
type: string
/get_activated_protocol_features:
post:
summary: Активированные возможности протокола
description: Возвращает активированные на узле продюсера протокольные возможности.
operationId: get_activated_protocol_features
requestBody:
content:
application/json:
schema:
type: object
properties:
lower_bound:
type: integer
description: Нижняя граница
upper_bound:
type: integer
description: Верхняя граница
limit:
type: integer
description: Лимит записей; по умолчанию 10
search_by_block_num:
type: boolean
description: Искать по номеру блока
reverse:
type: boolean
description: Обратный порядок обхода
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
description: Активированные протокольные возможности
required:
- activated_protocol_features
properties:
activated_protocol_features:
type: array
description: Массив идентификаторов активированных протокольных возможностей
items:
type: string
more:
type: integer
description: "Если активированных возможностей больше, чем limit, здесь порядковый номер следующей не вошедшей в ответ; иначе 0."
/get_accounts_by_authorizers:
post:
summary: Учётные записи по авторизующим
description: По набору имён учётных записей и публичных ключей находит разрешения (authorities), которые полностью или частично могут быть удовлетворены этими данными.
operationId: get_accounts_by_authorizers
requestBody:
content:
application/json:
schema:
type: object
properties:
accounts:
type: array
description: Список учётных записей и/или пар actor/permission
items:
anyOf:
- $ref: "schemas/Name.yaml"
- $ref: "schemas/PermissionLevel.yaml"
keys:
type: array
description: Список авторизующих ключей
items:
$ref: "schemas/PublicKey.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
description: Учётные записи, авторизация которых целиком или частично покрывается переданными аккаунтами и ключами
required:
- accounts
properties:
accounts:
type: array
description: Массив троек account, permission и данные авторизатора
items:
type: object
description: Одна тройка account — permission — авторизующие данные
required:
- account_name
- permission_name
- authorizer
- weight
- threshold
properties:
account_name:
$ref: "schemas/Name.yaml"
permission_name:
$ref: "schemas/Name.yaml"
authorizer:
oneOf:
- $ref: "schemas/PublicKey.yaml"
- $ref: "schemas/Authority.yaml"
weight:
type: "integer"
description: Вклад этого авторизатора в удовлетворение разрешения
threshold:
type: "integer"
description: Порог — сумма весов, которую нужно достичь или превысить
/get_transaction_status:
post:
summary: Статус транзакции (финальность)
description: Возвращает состояние цепи и при наличии — информацию о транзакции по её идентификатору. Требуется включённая функция статуса финальности транзакций в плагине chain (параметр nodeos `--transaction-finality-status-max-storage-size-gb`).
operationId: get_transaction_status
requestBody:
content:
application/json:
schema:
type: object
required:
- id
properties:
id:
type: string
description: Идентификатор транзакции для запроса статуса.
responses:
"200":
description: Успешно
content:
application/json:
schema:
$ref: "schemas/TransactionStatus.yaml"
/send_transaction2:
post:
summary: Применить транзакцию (send v2)
description: |
Пытается применить транзакцию в формате JSON к блокчейну. Поддерживает полную трассировку неудачной транзакции и повторные попытки через nodeos, если они включены на узле. При включённом повторе API-узел досылает транзакцию в P2P-сеть до истечения срока, включения в блок или необратимости.
Внимание: по умолчанию вместо исключений возвращается полная трассировка ошибки. Не путайте наличие трассировки с успешным выполнением — проверяйте поля «receipt» и «except».
operationId: send_transaction2
requestBody:
content:
application/json:
schema:
type: object
properties:
return_failure_trace:
type: boolean
description: Если true — исключения транзакции вкладываются в возвращаемую трассировку.
retry_trx:
type: boolean
description: Если true — повторять отправку до блока заданной высоты (см. retry_trx_num_blocks), необратимости или истечения срока.
retry_trx_num_blocks:
type: integer
description: При retry_trx — повторять до блока с этой высотой; если не задано — до lib.
transaction:
type: object
properties:
signatures:
type: array
description: Массив подписей для авторизации транзакции.
items:
$ref: "schemas/Signature.yaml"
compression:
type: boolean
description: Сжатие; обычно false
packed_context_free_data:
type: string
description: JSON в hex
packed_trx:
type: string
description: Транзакция (JSON) в hex
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: Тело ответа пустое
/compute_transaction:
post:
summary: Симуляция транзакции без записи
description: |
Выполняет указанную транзакцию, формирует трассировку (включая расход ресурсов), затем откатывает все изменения состояния; субъективный биллинг для аккаунта не увеличивается. Подписи, если есть, обрабатываются, ошибки подписи игнорируются. Неуспешные транзакции всё равно содержат трассировку сбоя.
Внимание: на публичных узлах с включённым compute_transaction нужно ограничивать частоту запросов (защита от DoS).
operationId: compute_transaction
requestBody:
content:
application/json:
schema:
type: object
properties:
signatures:
type: array
description: Массив подписей для авторизации транзакции
items:
$ref: "schemas/Signature.yaml"
compression:
type: boolean
description: Сжатие; обычно false
packed_context_free_data:
type: string
description: JSON в hex
packed_trx:
type: string
description: Объект транзакции, JSON в hex
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: Тело ответа пустое
/get_code_hash:
post:
summary: Хеш кода контракта
description: Возвращает хеш кода смарт-контракта в блокчейне. Его можно сравнить с ожидаемым значением, чтобы убедиться, что код не менялся.
operationId: get_code_hash
requestBody:
content:
application/json:
schema:
type: object
properties:
account_name:
description: Имя учётной записи владельца кода контракта.
type: string
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
account_name:
description: Учётная запись, на которой развёрнут контракт.
type: string
code_hash:
type: string
description: Хеш WASM-кода контракта указанной учётной записи.
/get_transaction_id:
post:
summary: Идентификатор транзакции
description: Возвращает идентификатор транзакции (хеш транзакции) для переданной транзакции.
operationId: get_transaction_id
requestBody:
description: Тело запроса — объект транзакции в формате JSON.
content:
application/json:
schema:
$ref: "schemas/Transaction.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: string
description: Идентификатор транзакции.
/get_producer_schedule:
post:
summary: Расписание продюсеров
description: Возвращает текущее расписание продюсеров — активный список и порядок ротации.
operationId: get_producer_schedule
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
active:
description: JSON-объект со списком активных продюсеров и версией расписания.
$ref: "schemas/ProducerSchedule.yaml"
pending:
description: JSON-объект с ожидающим расписанием продюсеров и версией.
$ref: "schemas/ProducerSchedule.yaml"
proposed:
description: JSON-объект с предлагаемым расписанием продюсеров и версией.
$ref: "schemas/ProducerSchedule.yaml"
/send_read_only_transaction:
post:
summary: Транзакция только для чтения
description: Отправляет транзакцию только для чтения в формате JSON; она не предназначена для включения в блокчейн. Если транзакция меняет состояние цепи, узел отклонит её.
operationId: send_read_only_transaction
requestBody:
content:
application/json:
schema:
type: object
properties:
transaction:
type: object
properties:
compression:
type: boolean
description: Сжатие; обычно false
packed_context_free_data:
type: string
description: JSON в hex
packed_trx:
type: string
description: Транзакция (JSON) в hex
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: Тело ответа пустое
/push_block:
post:
summary: Передать блок в цепь
description: Передаёт блок в блокчейн (для специальных сценариев узла).
operationId: push_block
requestBody:
content:
application/json:
schema:
$ref: "schemas/Block.yaml"
responses:
"200":
description: Успешно
content:
application/json:
schema:
description: Тело ответа пустое
+492
View File
@@ -0,0 +1,492 @@
# Percentage of cpu block production time used to produce block. Whole number percentages, e.g. 80 for 80% (eosio::producer_plugin)
# cpu-effort-percent = 80
# Percentage of cpu block production time used to produce last block. Whole number percentages, e.g. 80 for 80% (eosio::producer_plugin)
# last-block-cpu-effort-percent = 80
# the location of the blocks directory (absolute path or relative to application data dir) (eosio::chain_plugin)
# blocks-dir = "blocks"
# split the block log file when the head block number is the multiple of the stride
# When the stride is reached, the current block log and index will be renamed '<blocks-retained-dir>/blocks-<start num>-<end num>.log/index'
# and a new current block log and index will be created with the most recent block. All files following
# this format will be used to construct an extended block log. (eosio::chain_plugin)
# blocks-log-stride =
# the maximum number of blocks files to retain so that the blocks in those files can be queried.
# When the number is reached, the oldest block file would be moved to archive dir or deleted if the archive dir is empty.
# The retained block log files should not be manipulated by users. (eosio::chain_plugin)
# max-retained-block-files =
# the location of the blocks retained directory (absolute path or relative to blocks dir).
# If the value is empty, it is set to the value of blocks dir. (eosio::chain_plugin)
# blocks-retained-dir =
# the location of the blocks archive directory (absolute path or relative to blocks dir).
# If the value is empty, blocks files beyond the retained limit will be deleted.
# All files in the archive directory are completely under user's control, i.e. they won't be accessed by nodeos anymore. (eosio::chain_plugin)
# blocks-archive-dir =
# the location of the state directory (absolute path or relative to application data dir) (eosio::chain_plugin)
# state-dir = "state"
# the location of the protocol_features directory (absolute path or relative to application config dir) (eosio::chain_plugin)
# protocol-features-dir = "protocol_features"
# Pairs of [BLOCK_NUM,BLOCK_ID] that should be enforced as checkpoints. (eosio::chain_plugin)
# checkpoint =
# Override default WASM runtime ( "eos-vm-jit", "eos-vm")
# "eos-vm-jit" : A WebAssembly runtime that compiles WebAssembly code to native x86 code prior to execution.
# "eos-vm" : A WebAssembly interpreter.
# (eosio::chain_plugin)
# wasm-runtime = eos-vm-jit
# The name of an account whose code will be profiled (eosio::chain_plugin)
# profile-account =
# Override default maximum ABI serialization time allowed in ms (eosio::chain_plugin)
# abi-serializer-max-time-ms = 15
# Maximum size (in MiB) of the chain state database (eosio::chain_plugin)
# chain-state-db-size-mb = 1024
# Safely shut down node when free space remaining in the chain state database drops below this size (in MiB). (eosio::chain_plugin)
# chain-state-db-guard-size-mb = 128
# Percentage of actual signature recovery cpu to bill. Whole number percentages, e.g. 50 for 50% (eosio::chain_plugin)
# signature-cpu-billable-pct = 50
# Number of worker threads in controller thread pool (eosio::chain_plugin)
# chain-threads = 2
# print contract's output to console (eosio::chain_plugin)
# contracts-console = false
# print deeper information about chain operations (eosio::chain_plugin)
deep-mind = false
# Account added to actor whitelist (may specify multiple times) (eosio::chain_plugin)
# actor-whitelist =
# Account added to actor blacklist (may specify multiple times) (eosio::chain_plugin)
# actor-blacklist =
# Contract account added to contract whitelist (may specify multiple times) (eosio::chain_plugin)
# contract-whitelist =
# Contract account added to contract blacklist (may specify multiple times) (eosio::chain_plugin)
# contract-blacklist =
# Action (in the form code::action) added to action blacklist (may specify multiple times) (eosio::chain_plugin)
# action-blacklist =
# Public key added to blacklist of keys that should not be included in authorities (may specify multiple times) (eosio::chain_plugin)
# key-blacklist =
# Deferred transactions sent by accounts in this list do not have any of the subjective whitelist/blacklist checks applied to them (may specify multiple times) (eosio::chain_plugin)
# sender-bypass-whiteblacklist =
# Database read mode ("head", "irreversible", "speculative").
# In "head" mode: database contains state changes up to the head block; transactions received by the node are relayed if valid.
# In "irreversible" mode: database contains state changes up to the last irreversible block; transactions received via the P2P network are not relayed and transactions cannot be pushed via the chain API.
# In "speculative" mode: database contains state changes by transactions in the blockchain up to the head block as well as some transactions not yet included in the blockchain; transactions received by the node are relayed if valid.
# (eosio::chain_plugin)
# read-mode = head
# Allow API transactions to be evaluated and relayed if valid. (eosio::chain_plugin)
api-accept-transactions = true
# Chain validation mode ("full" or "light").
# In "full" mode all incoming blocks will be fully validated.
# In "light" mode all incoming blocks headers will be fully validated; transactions in those validated blocks will be trusted
# (eosio::chain_plugin)
# validation-mode = full
# Disable the check which subjectively fails a transaction if a contract bills more RAM to another account within the context of a notification handler (i.e. when the receiver is not the code of the action). (eosio::chain_plugin)
# disable-ram-billing-notify-checks = false
# Subjectively limit the maximum length of variable components in a variable legnth signature to this size in bytes (eosio::chain_plugin)
# maximum-variable-signature-length = 16384
# Indicate a producer whose blocks headers signed by it will be fully validated, but transactions in those validated blocks will be trusted. (eosio::chain_plugin)
# trusted-producer =
# Database map mode ("mapped", "heap", or "locked").
# In "mapped" mode database is memory mapped as a file.
# In "heap" mode database is preloaded in to swappable memory and will use huge pages if available.
# In "locked" mode database is preloaded, locked in to memory, and will use huge pages if available.
# (eosio::chain_plugin)
# database-map-mode = mapped
# Maximum size (in MiB) of the EOS VM OC code cache (eosio::chain_plugin)
# eos-vm-oc-cache-size-mb = 1024
# Number of threads to use for EOS VM OC tier-up (eosio::chain_plugin)
# eos-vm-oc-compile-threads = 1
# Enable EOS VM OC tier-up runtime (eosio::chain_plugin)
# eos-vm-oc-enable = false
# enable queries to find accounts by various metadata. (eosio::chain_plugin)
# enable-account-queries = false
# maximum allowed size (in bytes) of an inline action for a nonprivileged account (eosio::chain_plugin)
# max-nonprivileged-inline-action-size = 4096
# Maximum size (in GiB) allowed to be allocated for the Transaction Retry feature. Setting above 0 enables this feature. (eosio::chain_plugin)
# transaction-retry-max-storage-size-gb =
# How often, in seconds, to resend an incoming transaction to network if not seen in a block.
# Needs to be at least twice as large as p2p-dedup-cache-expire-time-sec. (eosio::chain_plugin)
# transaction-retry-interval-sec = 20
# Maximum allowed transaction expiration for retry transactions, will retry transactions up to this value.
# Should be larger than transaction-retry-interval-sec. (eosio::chain_plugin)
# transaction-retry-max-expiration-sec = 120
# Maximum size (in GiB) allowed to be allocated for the Transaction Finality Status feature. Setting above 0 enables this feature. (eosio::chain_plugin)
# transaction-finality-status-max-storage-size-gb =
# Duration (in seconds) a successful transaction's Finality Status will remain available from being first identified. (eosio::chain_plugin)
# transaction-finality-status-success-duration-sec = 180
# Duration (in seconds) a failed transaction's Finality Status will remain available from being first identified. (eosio::chain_plugin)
# transaction-finality-status-failure-duration-sec = 180
# Log the state integrity hash on startup (eosio::chain_plugin)
# integrity-hash-on-start = false
# Log the state integrity hash on shutdown (eosio::chain_plugin)
# integrity-hash-on-stop = false
# If set to greater than 0, periodically prune the block log to store only configured number of most recent blocks.
# If set to 0, no blocks are be written to the block log; block log file is removed after startup. (eosio::chain_plugin)
# block-log-retain-blocks =
# The filename (relative to data-dir) to create a unix socket for HTTP RPC; set blank to disable. (eosio::http_plugin)
# unix-socket-path =
# The local IP and port to listen for incoming http connections; set blank to disable. (eosio::http_plugin)
# http-server-address = 127.0.0.1:8888
# Specify the Access-Control-Allow-Origin to be returned on each request (eosio::http_plugin)
# access-control-allow-origin =
# Specify the Access-Control-Allow-Headers to be returned on each request (eosio::http_plugin)
# access-control-allow-headers =
# Specify the Access-Control-Max-Age to be returned on each request. (eosio::http_plugin)
# access-control-max-age =
# Specify if Access-Control-Allow-Credentials: true should be returned on each request. (eosio::http_plugin)
# access-control-allow-credentials = false
# The maximum body size in bytes allowed for incoming RPC requests (eosio::http_plugin)
# max-body-size = 2097152
# Maximum size in megabytes http_plugin should use for processing http requests. -1 for unlimited. 429 error response when exceeded. (eosio::http_plugin)
# http-max-bytes-in-flight-mb = 500
# Maximum number of requests http_plugin should use for processing http requests. 429 error response when exceeded. (eosio::http_plugin)
# http-max-in-flight-requests = -1
# Maximum time for processing a request, -1 for unlimited (eosio::http_plugin)
# http-max-response-time-ms = 30
# Append the error log to HTTP responses (eosio::http_plugin)
# verbose-http-errors = false
# If set to false, then any incoming "Host" header is considered valid (eosio::http_plugin)
# http-validate-host = true
# Additionaly acceptable values for the "Host" header of incoming HTTP requests, can be specified multiple times. Includes http/s_server_address by default. (eosio::http_plugin)
# http-alias =
# Number of worker threads in http thread pool (eosio::http_plugin)
# http-threads = 2
# If set to false, do not keep HTTP connections alive, even if client requests. (eosio::http_plugin)
# http-keep-alive = true
# The actual host:port used to listen for incoming p2p connections. (eosio::net_plugin)
# p2p-listen-endpoint = 0.0.0.0:9876
# An externally accessible host:port for identifying this node. Defaults to p2p-listen-endpoint. (eosio::net_plugin)
# p2p-server-address =
# The public endpoint of a peer node to connect to. Use multiple p2p-peer-address options as needed to compose a network.
# Syntax: host:port[:<trx>|<blk>]
# The optional 'trx' and 'blk' indicates to node that only transactions 'trx' or blocks 'blk' should be sent. Examples:
# p2p.eos.io:9876
# p2p.trx.eos.io:9876:trx
# p2p.blk.eos.io:9876:blk
# (eosio::net_plugin)
# p2p-peer-address =
# Maximum number of client nodes from any single IP address (eosio::net_plugin)
# p2p-max-nodes-per-host = 1
# Allow transactions received over p2p network to be evaluated and relayed if valid. (eosio::net_plugin)
# p2p-accept-transactions = true
# The account and public p2p endpoint of a block producer node to automatically connect to when the it is in producer schedule proximity
# . Syntax: account,host:port
# Example,
# eosproducer1,p2p.eos.io:9876
# eosproducer2,p2p.trx.eos.io:9876:trx
# eosproducer3,p2p.blk.eos.io:9876:blk
# (eosio::net_plugin)
# p2p-auto-bp-peer =
# The name supplied to identify this node amongst the peers. (eosio::net_plugin)
# agent-name = EOS Test Agent
# Can be 'any' or 'producers' or 'specified' or 'none'. If 'specified', peer-key must be specified at least once. If only 'producers', peer-key is not required. 'producers' and 'specified' may be combined. (eosio::net_plugin)
# allowed-connection = any
# Optional public key of peer allowed to connect. May be used multiple times. (eosio::net_plugin)
# peer-key =
# Tuple of [PublicKey, WIF private key] (may specify multiple times) (eosio::net_plugin)
# peer-private-key =
# Maximum number of clients from which connections are accepted, use 0 for no limit (eosio::net_plugin)
# max-clients = 25
# number of seconds to wait before cleaning up dead connections (eosio::net_plugin)
# connection-cleanup-period = 30
# max connection cleanup time per cleanup call in milliseconds (eosio::net_plugin)
# max-cleanup-time-msec = 10
# Maximum time to track transaction for duplicate optimization (eosio::net_plugin)
# p2p-dedup-cache-expire-time-sec = 10
# Number of worker threads in net_plugin thread pool (eosio::net_plugin)
# net-threads = 4
# number of blocks to retrieve in a chunk from any individual peer during synchronization (eosio::net_plugin)
# sync-fetch-span = 100
# Enable experimental socket read watermark optimization (eosio::net_plugin)
# use-socket-read-watermark = false
# The string used to format peers when logging messages about them. Variables are escaped with ${<variable name>}.
# Available Variables:
# _name self-reported name
#
# _cid assigned connection id
#
# _id self-reported ID (64 hex characters)
#
# _sid first 8 characters of _peer.id
#
# _ip remote IP address of peer
#
# _port remote port number of peer
#
# _lip local IP address connected to peer
#
# _lport local port number connected to peer
#
# (eosio::net_plugin)
# peer-log-format = ["${_name}" - ${_cid} ${_ip}:${_port}]
# peer heartbeat keepalive message interval in milliseconds (eosio::net_plugin)
# p2p-keepalive-interval-ms = 10000
# Enable block production, even if the chain is stale. (eosio::producer_plugin)
# enable-stale-production = false
# Start this node in a state where production is paused (eosio::producer_plugin)
# pause-on-startup = false
# Limits the maximum time (in milliseconds) that is allowed a pushed transaction's code to execute before being considered invalid (eosio::producer_plugin)
# max-transaction-time = 30
# Limits the maximum age (in seconds) of the DPOS Irreversible Block for a chain this node will produce blocks on (use negative value to indicate unlimited) (eosio::producer_plugin)
# max-irreversible-block-age = -1
# ID of producer controlled by this node (e.g. inita; may specify multiple times) (eosio::producer_plugin)
# producer-name =
# Key=Value pairs in the form <public-key>=<provider-spec>
# Where:
# <public-key> is a string form of a valid COOPOS public key
#
# <provider-spec> is a string in the form <provider-type>:<data>
#
# <provider-type> is KEY, KEOSD, or SE
#
# KEY:<data> is a string form of a valid COOPOS private key which maps to the provided public key
#
# KEOSD:<data> is the URL where keosd is available and the approptiate wallet(s) are unlocked
#
# (eosio::producer_plugin)
# signature-provider = EOS6MRyAjQq8ud7hVNYcfnVPJqcVpscN5So8BhtHuGYqET5GDW5CV=KEY:5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3
# account that can not access to extended CPU/NET virtual resources (eosio::producer_plugin)
# greylist-account =
# Limit (between 1 and 1000) on the multiple that CPU/NET virtual resources can extend during low usage (only enforced subjectively; use 1000 to not enforce any limit) (eosio::producer_plugin)
# greylist-limit = 1000
# Offset of non last block producing time in microseconds. Valid range 0 .. -block_time_interval. (eosio::producer_plugin)
# produce-time-offset-us = 0
# Offset of last block producing time in microseconds. Valid range 0 .. -block_time_interval. (eosio::producer_plugin)
# last-block-time-offset-us = -200000
# Percentage of cpu block production time used to produce block. Whole number percentages, e.g. 80 for 80% (eosio::producer_plugin)
# cpu-effort-percent = 10
# Percentage of cpu block production time used to produce last block. Whole number percentages, e.g. 80 for 80% (eosio::producer_plugin)
# last-block-cpu-effort-percent = 10
# Threshold of CPU block production to consider block full; when within threshold of max-block-cpu-usage block can be produced immediately (eosio::producer_plugin)
# max-block-cpu-usage-threshold-us = 5000
# Threshold of NET block production to consider block full; when within threshold of max-block-net-usage block can be produced immediately (eosio::producer_plugin)
# max-block-net-usage-threshold-bytes = 1024
# Maximum wall-clock time, in milliseconds, spent retiring scheduled transactions (and incoming transactions according to incoming-defer-ratio) in any block before returning to normal transaction processing. (eosio::producer_plugin)
# max-scheduled-transaction-time-per-block-ms = 100
# Time in microseconds allowed for a transaction that starts with insufficient CPU quota to complete and cover its CPU usage. (eosio::producer_plugin)
# subjective-cpu-leeway-us = 31000
# Sets the maximum amount of failures that are allowed for a given account per window size. (eosio::producer_plugin)
# subjective-account-max-failures = 3
# Sets the window size in number of blocks for subjective-account-max-failures. (eosio::producer_plugin)
# subjective-account-max-failures-window-size = 1
# Sets the time to return full subjective cpu for accounts (eosio::producer_plugin)
# subjective-account-decay-time-minutes = 1440
# ratio between incoming transactions and deferred transactions when both are queued for execution (eosio::producer_plugin)
# incoming-defer-ratio = 1
# Maximum size (in MiB) of the incoming transaction queue. Exceeding this value will subjectively drop transaction with resource exhaustion. (eosio::producer_plugin)
# incoming-transaction-queue-size-mb = 1024
# Disable subjective CPU billing for API/P2P transactions (eosio::producer_plugin)
# disable-subjective-billing = true
# Account which is excluded from subjective CPU billing (eosio::producer_plugin)
# disable-subjective-account-billing =
# Disable subjective CPU billing for P2P transactions (eosio::producer_plugin)
# disable-subjective-p2p-billing = true
# Disable subjective CPU billing for API transactions (eosio::producer_plugin)
# disable-subjective-api-billing = true
# Number of worker threads in producer thread pool (eosio::producer_plugin)
# producer-threads = 1
# the location of the snapshots directory (absolute path or relative to application data dir) (eosio::producer_plugin)
# snapshots-dir = "snapshots"
# Number of worker threads in read-only execution thread pool. Max 8. (eosio::producer_plugin)
# read-only-threads =
# Time in microseconds the write window lasts. (eosio::producer_plugin)
# read-only-write-window-time-us = 200000
# Time in microseconds the read window lasts. (eosio::producer_plugin)
# read-only-read-window-time-us = 60000
# The local IP and port to listen for incoming prometheus metrics http request. (eosio::prometheus_plugin)
# prometheus-exporter-address = 127.0.0.1:9101
# Time in seconds between two consecutive checks of resource usage. Should be between 1 and 300 (eosio::resource_monitor_plugin)
# resource-monitor-interval-seconds = 2
# Threshold in terms of percentage of used space vs total space. If used space is above (threshold - 5%), a warning is generated. Unless resource-monitor-not-shutdown-on-threshold-exceeded is enabled, a graceful shutdown is initiated if used space is above the threshold. The value should be between 6 and 99 (eosio::resource_monitor_plugin)
# resource-monitor-space-threshold = 90
# Absolute threshold in gibibytes of remaining space; applied to each monitored directory. If remaining space is less than value for any monitored directories then threshold is considered exceeded.Overrides resource-monitor-space-threshold value. (eosio::resource_monitor_plugin)
# resource-monitor-space-absolute-gb =
# Used to indicate nodeos will not shutdown when threshold is exceeded. (eosio::resource_monitor_plugin)
# resource-monitor-not-shutdown-on-threshold-exceeded =
# Number of resource monitor intervals between two consecutive warnings when the threshold is hit. Should be between 1 and 450 (eosio::resource_monitor_plugin)
# resource-monitor-warning-interval = 30
# Limits the maximum time (in milliseconds) that is allowed for sending requests to a keosd provider for signing (eosio::signature_provider_plugin)
# keosd-provider-timeout = 5
# the location of the state-history directory (absolute path or relative to application data dir) (eosio::state_history_plugin)
# state-history-dir = "state-history"
# the location of the state history retained directory (absolute path or relative to state-history dir). (eosio::state_history_plugin)
# state-history-retained-dir =
# the location of the state history archive directory (absolute path or relative to state-history dir).
# If the value is empty string, blocks files beyond the retained limit will be deleted.
# All files in the archive directory are completely under user's control, i.e. they won't be accessed by nodeos anymore. (eosio::state_history_plugin)
# state-history-archive-dir =
# split the state history log files when the block number is the multiple of the stride
# When the stride is reached, the current history log and index will be renamed '*-history-<start num>-<end num>.log/index'
# and a new current history log and index will be created with the most recent blocks. All files following
# this format will be used to construct an extended history log. (eosio::state_history_plugin)
# state-history-stride =
# the maximum number of history file groups to retain so that the blocks in those files can be queried.
# When the number is reached, the oldest history file would be moved to archive dir or deleted if the archive dir is empty.
# The retained history log files should not be manipulated by users. (eosio::state_history_plugin)
# max-retained-history-files =
# enable trace history (eosio::state_history_plugin)
# trace-history = false
# enable chain state history (eosio::state_history_plugin)
# chain-state-history = false
# the endpoint upon which to listen for incoming connections. Caution: only expose this port to your internal network. (eosio::state_history_plugin)
# state-history-endpoint = 127.0.0.1:8080
# the path (relative to data-dir) to create a unix socket upon which to listen for incoming connections. (eosio::state_history_plugin)
# state-history-unix-socket-path =
# enable debug mode for trace history (eosio::state_history_plugin)
# trace-history-debug-mode = false
# if set, periodically prune the state history files to store only configured number of most recent blocks (eosio::state_history_plugin)
# state-history-log-retain-blocks =
# the location of the trace directory (absolute path or relative to application data dir) (eosio::trace_api_plugin)
# trace-dir = "traces"
# the number of blocks each "slice" of trace data will contain on the filesystem (eosio::trace_api_plugin)
# trace-slice-stride = 10000
# Number of blocks to ensure are kept past LIB for retrieval before "slice" files can be automatically removed.
# A value of -1 indicates that automatic removal of "slice" files will be turned off. (eosio::trace_api_plugin)
# trace-minimum-irreversible-history-blocks = -1
# Number of blocks to ensure are uncompressed past LIB. Compressed "slice" files are still accessible but may carry a performance loss on retrieval
# A value of -1 indicates that automatic compression of "slice" files will be turned off. (eosio::trace_api_plugin)
# trace-minimum-uncompressed-irreversible-history-blocks = -1
# ABIs used when decoding trace RPC responses.
# There must be at least one ABI specified OR the flag trace-no-abis must be used.
# ABIs are specified as "Key=Value" pairs in the form <account-name>=<abi-def>
# Where <abi-def> can be:
# an absolute path to a file containing a valid JSON-encoded ABI
# a relative path from `data-dir` to a file containing a valid JSON-encoded ABI
# (eosio::trace_api_plugin)
# trace-rpc-abi =
# Use to indicate that the RPC responses will not use ABIs.
# Failure to specify this option when there are no trace-rpc-abi configuations will result in an Error.
# This option is mutually exclusive with trace-rpc-api (eosio::trace_api_plugin)
# trace-no-abis =
# Plugin(s) to enable, may be specified multiple times
# plugin =
+61
View File
@@ -0,0 +1,61 @@
openapi: 3.0.0
info:
title: API размера БД COOPOS
description: Спецификация DB Size API узла COOPOS (nodeos). Включение плагина — в документации на https://coopenomics.world.
version: 1.0.0
license:
name: MIT
url: https://opensource.org/licenses/MIT
contact:
url: https://coopenomics.world
servers:
- url: '{protocol}://{host}:{port}/v1/'
variables:
protocol:
enum:
- http
- https
default: http
host:
default: localhost
port:
default: "8080"
components:
schemas: {}
paths:
/db_size/get:
post:
summary: Получить статистику
description: Возвращает статистику по размеру и использованию базы данных узла.
operationId: get
parameters: []
requestBody:
content:
application/json:
schema:
type: object
properties: {}
responses:
'200':
description: Успешно
content:
application/json:
schema:
type: object
description: Показатели базы данных
properties:
free_bytes:
type: integer
used_bytes:
type: integer
size:
type: integer
indices:
type: array
items:
type: object
properties:
index:
type: string
row_count:
type: integer
+228
View File
@@ -0,0 +1,228 @@
openapi: 3.0.0
info:
title: API сети COOPOS
description: Спецификация Net API узла COOPOS (nodeos). Включение плагина — в документации на https://coopenomics.world.
version: 1.0.0
license:
name: MIT
url: https://opensource.org/licenses/MIT
contact:
url: https://coopenomics.world
servers:
- url: '{protocol}://{host}:{port}/v1/'
variables:
protocol:
enum:
- http
- https
default: http
host:
default: localhost
port:
default: "8080"
components:
schemas: {}
paths:
/net/connections:
post:
summary: Соединения
description: Возвращает массив состояний всех пиринговых соединений.
operationId: connections
parameters: []
requestBody:
content:
application/json:
schema:
type: object
properties: {}
responses:
'200':
description: Успешно
content:
application/json:
schema:
type: array
items:
type: object
properties:
peer:
description: IP-адрес или URL пира
type: string
connecting:
description: true, если идёт установление соединения; иначе false
type: boolean
syncing:
description: true, если пир в процессе синхронизации; иначе false
type: boolean
last_handshake:
description: Структура с подробностями последнего рукопожатия
type: object
properties:
network_version:
description: Инкрементальное значение относительно вычисленной базы
type: integer
chain_id:
$ref: 'schemas/Sha256.yaml'
node_id:
$ref: 'schemas/Sha256.yaml'
key:
$ref: 'schemas/PublicKey.yaml'
time:
$ref: 'schemas/DateTimeSeconds.yaml'
token:
$ref: 'schemas/Sha256.yaml'
sig:
$ref: 'schemas/Signature.yaml'
p2p_address:
description: IP-адрес или URL пира
type: string
last_irreversible_block_num:
description: Номер последнего необратимого блока
type: integer
last_irreversible_block_id:
$ref: 'schemas/Sha256.yaml'
head_num:
description: Номер головы цепи
type: integer
head_id:
$ref: 'schemas/Sha256.yaml'
os:
description: Название операционной системы
type: string
agent:
description: Имя агента (строка идентификации узла)
type: string
generation:
description: Номер поколения
type: integer
/net/connect:
post:
summary: Подключиться
description: Инициирует соединение с указанным пиром.
operationId: connect
parameters: []
requestBody:
content:
application/json:
schema:
type: object
required:
- endpoint
properties:
endpoint:
type: string
description: Конечная точка для подключения — IP-адрес или URL
responses:
'200':
description: Успешно
content:
application/json:
schema:
type: string
description: '«already connected» или «added connection»'
/net/disconnect:
post:
summary: Отключиться
description: Инициирует разрыв соединения с указанным пиром.
operationId: disconnect
parameters: []
requestBody:
content:
application/json:
schema:
type: object
required:
- endpoint
properties:
endpoint:
type: string
description: Конечная точка для отключения — IP-адрес или URL
responses:
'200':
description: Успешно
content:
application/json:
schema:
type: string
description: '«connection removed» или «no known connection for host»'
/net/status:
post:
summary: Статус
description: Возвращает состояние соединения с указанным пиром.
operationId: status
parameters: []
requestBody:
content:
application/json:
schema:
type: object
required:
- endpoint
properties:
endpoint:
type: string
description: Конечная точка, для которой запрашивается статус — IP-адрес или URL
responses:
'200':
description: Успешно
content:
application/json:
schema:
type: object
properties:
peer:
description: IP-адрес или URL пира
type: string
connecting:
description: true, если идёт установление соединения; иначе false
type: boolean
syncing:
description: true, если пир в процессе синхронизации; иначе false
type: boolean
last_handshake:
description: Структура с подробностями последнего рукопожатия
type: object
properties:
network_version:
description: Инкрементальное значение относительно вычисленной базы
type: integer
chain_id:
$ref: 'schemas/Sha256.yaml'
node_id:
$ref: 'schemas/Sha256.yaml'
key:
$ref: 'schemas/PublicKey.yaml'
time:
$ref: 'schemas/DateTimeSeconds.yaml'
token:
$ref: 'schemas/Sha256.yaml'
sig:
$ref: 'schemas/Signature.yaml'
p2p_address:
description: IP-адрес или URL пира
type: string
last_irreversible_block_num:
description: Номер последнего необратимого блока
type: integer
last_irreversible_block_id:
$ref: 'schemas/Sha256.yaml'
head_num:
description: Номер головы цепи
type: integer
head_id:
$ref: 'schemas/Sha256.yaml'
os:
description: Название операционной системы
type: string
agent:
description: Имя агента
type: string
generation:
description: Номер поколения
type: integer
+892
View File
@@ -0,0 +1,892 @@
openapi: 3.0.0
info:
title: API продюсера COOPOS
description: Спецификация Producer API узла COOPOS (nodeos). Включение плагина — в документации на https://coopenomics.world.
version: 1.0.0
license:
name: MIT
url: https://opensource.org/licenses/MIT
contact:
url: https://coopenomics.world
tags:
- name: Версия протокола 4.0
description: Тег релиза бинарников COOPOS совпадает с версией протокола
servers:
- url: "{protocol}://{host}:{port}/v1"
variables:
protocol:
enum:
- http
- https
default: http
host:
default: localhost
port:
default: "8080"
security:
- {}
paths:
/producer/pause:
post:
summary: Приостановить
description: Приостанавливает выпуск блоков узлом-продюсером. Без аргументов; тело ответа не задаётся.
operationId: pause
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/OK"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/resume:
post:
summary: Возобновить
description: Возобновляет выпуск блоков узлом-продюсером. Без аргументов; тело ответа не задаётся.
operationId: resume
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/OK"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/paused:
post:
summary: Статус паузы
description: Возвращает, приостановлен ли узел-продюсер. Без аргументов.
operationId: paused
responses:
"201":
description: Успешно
content:
text/plain:
schema:
description: Строка «true» или «false»
type: string
example: false
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_runtime_options:
post:
summary: Параметры времени выполнения
description: Возвращает текущие параметры времени выполнения узла-продюсера.
operationId: get_runtime_options
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/Runtime_Options"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/update_runtime_options:
post:
summary: Обновить параметры времени выполнения
description: Обновляет параметры времени выполнения узла-продюсера. Можно передать любое подмножество полей.
operationId: update_runtime_options
requestBody:
content:
application/json:
schema:
$ref: "#/components/schemas/Runtime_Options"
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/OK"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_greylist:
post:
summary: Список серой зоны
description: Возвращает серый список (greylist) узла-продюсера.
operationId: get_greylist
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
properties:
accounts:
type: array
description: Имена учётных записей в сером списке
items:
$ref: "schemas/Name.yaml"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/add_greylist_accounts:
post:
summary: Добавить в серый список
description: Добавляет учётные записи в серый список узла-продюсера. Нужна хотя бы одна запись.
operationId: add_greylist_accounts
requestBody:
content:
application/json:
schema:
type: object
properties:
accounts:
type: array
description: Имена учётных записей для добавления
items:
$ref: "schemas/Name.yaml"
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/OK"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/remove_greylist_accounts:
post:
summary: Убрать из серого списка
description: Удаляет учётные записи из серого списка узла-продюсера. Нужна хотя бы одна запись.
operationId: remove_greylist_accounts
requestBody:
content:
application/json:
schema:
type: object
properties:
accounts:
type: array
description: Имена учётных записей для удаления
items:
$ref: "schemas/Name.yaml"
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/OK"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_whitelist_blacklist:
post:
summary: Белые и чёрные списки
description: Возвращает белые и чёрные списки узла-продюсера в виде JSON-объекта.
operationId: get_whitelist_blacklist
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
properties:
actor_whitelist:
type: array
items:
$ref: "schemas/Name.yaml"
actor_blacklist:
type: array
items:
$ref: "schemas/Name.yaml"
contract_whitelist:
type: array
items:
$ref: "schemas/Name.yaml"
contract_blacklist:
type: array
items:
$ref: "schemas/Name.yaml"
action_blacklist:
type: array
items:
type: array
description: Два элемента — имя контракта и имя действия
items:
allOf:
- $ref: "schemas/Name.yaml"
- $ref: "schemas/CppSignature.yaml"
key_blacklist:
type: array
items:
- $ref: "schemas/KeyType.yaml"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/set_whitelist_blacklist:
post:
summary: Задать белые и чёрные списки
description: Задаёт белые и чёрные списки узла-продюсера. Тело запроса — JSON с полями списков.
operationId: set_whitelist_blacklist
requestBody:
content:
application/json:
schema:
type: object
properties:
actor_whitelist:
type: array
items:
$ref: "schemas/Name.yaml"
actor_blacklist:
type: array
items:
$ref: "schemas/Name.yaml"
contract_whitelist:
type: array
items:
$ref: "schemas/Name.yaml"
contract_blacklist:
type: array
items:
$ref: "schemas/Name.yaml"
action_blacklist:
type: array
items:
type: array
description: Два элемента — имя контракта и имя действия
items:
anyOf:
- $ref: "schemas/Name.yaml"
- $ref: "schemas/CppSignature.yaml"
key_blacklist:
type: array
items:
$ref: "schemas/KeyType.yaml"
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/OK"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/create_snapshot:
post:
summary: Создать снимок
description: Создаёт снимок состояния узла-продюсера. При ошибке возвращает ответ с ошибкой.
operationId: create_snapshot
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
properties:
head_block_id:
$ref: "schemas/Sha256.yaml"
head_block_num:
type: integer
description: Номер головного блока цепи
example: 5102
head_block_time:
type: string
description: Метка времени головного блока (Unix)
example: 2020-11-16T00:00:00.000
version:
type: integer
description: Номер версии формата снимка
example: 6
snapshot_name:
type: string
description: Путь и имя файла снимка
example: /home/me/nodes/node-name/snapshots/snapshot-0000999f99999f9f999f99f99ff9999f999f9fff99ff99ffff9f9f9fff9f9999.bin
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/schedule_snapshot:
post:
summary: Запланировать снимки
description: Запрашивает периодическое создание снимков по заданным параметрам. Пустое тело — немедленное создание снимка. При невозможности принять расписание — ошибка.
operationId: schedule_snapshot
requestBody:
content:
application/json:
schema:
type: object
properties:
block_spacing:
type: integer
description: Создавать снимок каждые block_spacing блоков
start_block_num:
type: integer
description: Номер блока начала расписания
example: 5102
end_block_num:
type: integer
description: Номер блока окончания расписания
example: 15102
snapshot_description:
type: string
description: Описание снимка / задания
example: Daily snapshot
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
required:
- snapshot_request_id
- block_spacing
- start_block_num
- end_block_num
- snapshot_description
properties:
snapshot_request_id:
type: integer
description: Уникальный идентификатор запроса на снимки
block_spacing:
type: integer
description: Создавать снимок каждые block_spacing блоков
start_block_num:
type: integer
description: Номер блока начала расписания
example: 5102
end_block_num:
type: integer
description: Номер блока окончания расписания
example: 15102
snapshot_description:
type: string
description: Описание снимка / задания
example: Daily snapshot
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_snapshot_requests:
post:
summary: Список запланированных снимков
description: Возвращает список запросов на периодические снимки.
operationId: get_snapshot_requests
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
properties:
snapshot_requests:
type: array
description: Запланированные запросы на снимки
items:
type: object
required:
- snapshot_request_id
- block_spacing
- start_block_num
- end_block_num
- snapshot_description
- pending_snapshots
properties:
snapshot_request_id:
type: integer
description: Уникальный идентификатор запроса на снимки
block_spacing:
type: integer
description: Создавать снимок каждые block_spacing блоков
start_block_num:
type: integer
description: Номер блока начала расписания
example: 5102
end_block_num:
type: integer
description: Номер блока окончания расписания
example: 15102
snapshot_description:
type: string
description: Описание снимка / задания
example: Daily snapshot
pending_snapshots:
type: array
description: Ожидающие снимки
items:
type: object
required:
- head_block_id
- head_block_num
- head_block_time
- version
- snapshot_name
properties:
head_block_id:
$ref: "schemas/Sha256.yaml"
head_block_num:
type: integer
description: Номер головного блока цепи
example: 5102
head_block_time:
type: string
description: Метка времени головного блока (Unix)
example: 2020-11-16T00:00:00.000
version:
type: integer
description: Номер версии формата снимка
example: 6
snapshot_name:
type: string
description: Путь и имя файла снимка
example: /home/me/nodes/node-name/snapshots/snapshot-0000999f99999f9f999f99f99ff9999f999f9fff99ff99ffff9f9f9fff9f9999.bin
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/unschedule_snapshot:
post:
summary: Отменить расписание снимков
description: Удаляет запрос на снимки по идентификатору. Ошибка, если такого запроса нет.
operationId: unschedule_snapshot
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
snapshot_request_id:
type: integer
description: Идентификатор запроса на снимки
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
required:
- snapshot_request_id
- block_spacing
- start_block_num
- end_block_num
- snapshot_description
properties:
snapshot_request_id:
type: integer
description: Уникальный идентификатор запроса на снимки
block_spacing:
type: integer
description: Создавать снимок каждые block_spacing блоков
start_block_num:
type: integer
description: Номер блока начала расписания
example: 5102
end_block_num:
type: integer
description: Номер блока окончания расписания
example: 15102
snapshot_description:
type: string
description: Описание снимка / задания
example: Daily snapshot
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_integrity_hash:
post:
summary: Хеш целостности
description: Возвращает хеш целостности состояния узла-продюсера.
operationId: get_integrity_hash
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
description: Данные хеша целостности
properties:
head_block_id:
$ref: "schemas/Sha256.yaml"
integrity_hash:
$ref: "schemas/Sha256.yaml"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/schedule_protocol_feature_activations:
post:
summary: Запланировать активацию протокольных возможностей
description: Планирует активацию протокольных возможностей на узле-продюсере. Часть возможностей требует предварительной активации. Дубликаты и нарушение порядка предварительной активации дают ошибку.
operationId: schedule_protocol_feature_activations
requestBody:
content:
application/json:
schema:
type: object
properties:
protocol_features_to_activate:
type: array
description: Список протокольных возможностей для активации
items:
$ref: "schemas/Sha256.yaml"
responses:
"201":
description: Успешно
content:
application/json:
schema:
$ref: "#/components/schemas/OK"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_supported_protocol_features:
post:
summary: Поддерживаемые протокольные возможности
description: Возвращает поддерживаемые узлом протокольные возможности. Фильтры передаются в теле запроса.
operationId: get_supported_protocol_features
requestBody:
content:
application/json:
schema:
type: object
properties:
exclude_disabled:
type: boolean
description: Исключить отключённые возможности
example: false
default: false
exclude_unactivatable:
type: boolean
description: Исключить возможности, которые нельзя активировать
default: false
example: false
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: array
description: Массив объектов с описанием поддерживаемых протокольных возможностей
items:
type: object
properties:
feature_digest:
$ref: "schemas/Sha256.yaml"
subjective_restrictions:
type: object
properties:
enabled:
type: boolean
example: true
preactivation_required:
type: boolean
example: true
earliest_allowed_activation_time:
type: string
example: "1970-01-01T00:00:00.000"
description_digest:
$ref: "schemas/Sha256.yaml"
dependencies:
type: array
items:
$ref: "schemas/Sha256.yaml"
protocol_feature_type:
type: string
example: "builtin"
specification:
type: array
items:
type: object
properties:
name:
type: string
value:
type: string
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_account_ram_corrections:
post:
summary: Корректировки RAM по аккаунтам
description: Возвращает учётные записи с корректировками RAM.
operationId: get_account_ram_corrections
requestBody:
content:
application/json:
schema:
type: object
properties:
lower_bound:
type: integer
description: Нижняя граница ключа аккаунта
upper_bound:
type: integer
description: Верхняя граница ключа аккаунта
limit:
type: integer
description: Число строк для обхода
default: 10
example: 10
reverse:
type: boolean
description: Направление обхода
example: false
default: false
responses:
"201":
description: Успешно
content:
application/json:
schema:
type: object
required:
- rows
properties:
rows:
type: array
items:
type: string
more:
type: array
items:
- $ref: "schemas/Name.yaml"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
/producer/get_unapplied_transactions:
post:
summary: Неприменённые транзакции
description: Возвращает транзакции, ожидающие применения (неприменённые).
operationId: get_unapplied_transactions
requestBody:
content:
application/json:
schema:
type: object
properties:
limit:
type: integer
description: Максимальное число транзакций в ответе
default: 100
example: 100
lower_bound:
$ref: "schemas/Sha256.yaml"
time_limit_ms:
type: integer
description: Лимит времени ответа (мс); по умолчанию как у http-max-response-time-ms узла
default: http-max-response-time-ms
example: 10
responses:
"200":
description: Успешно
content:
application/json:
schema:
type: object
properties:
size:
type: integer
default: 0
example: 12428
incoming_size:
type: integer
default: 0
example: 4475
trxs:
type: array
items:
type: object
properties:
trx_id:
$ref: "schemas/Sha256.yaml"
expiration:
type: string
example: "2022-09-17T16:30:16"
trx_type:
type: string
example: "aborted"
first_auth:
type: string
example: "jkbsg.wam"
first_receiver:
type: string
example: "m.federation"
first_action:
type: string
example: "mine"
total_actions:
type: integer
default: 0
example: 1
billed_cpu_time_us:
type: integer
default: 0
example: 504
size:
type: integer
default: 0
example: 934
more:
$ref: "schemas/Sha256.yaml"
"400":
description: Ошибка клиента
content:
application/json:
schema:
$ref: "#/components/schemas/Error"
components:
securitySchemes: {}
schemas:
Error:
type: object
properties:
code:
type: integer
description: HTTP-код ответа
example: 400
message:
type: string
description: Краткое описание ошибки
example: Invalid Request
error:
type: object
description: Подробности ошибки
properties:
code:
type: integer
description: Внутренний код ошибки
example: 3200006
name:
type: string
description: Имя ошибки
example: invalid_http_request
what:
type: string
description: Человекочитаемое описание ошибки
example: invalid http request
details:
type: array
description: Дополнительные сведения для отладки
items:
type: object
properties:
message:
type: string
description: Сообщение отладки
example: Unable to parse valid input from POST body
file:
type: string
description: Файл, в котором возникла ошибка
example: http_plugin.hpp
line_number:
type: integer
description: Номер строки в файле
example: 246
method:
type: string
description: Функция, при выполнении которой произошла ошибка
example: parse_params
OK:
type: object
properties:
result:
type: string
description: Статус операции
example: ok
Runtime_Options:
type: object
properties:
max_transaction_time:
type: integer
description: Максимальное время выполнения транзакции
example: 100
max_irreversible_block_age:
type: integer
description: Максимальный «возраст» необратимого блока
example: -1
produce_time_offset_us:
type: integer
description: Смещение времени производства (мкс)
example: -100000
last_block_time_offset_us:
type: integer
description: Смещение времени последнего блока (мкс)
example: -200000
max_scheduled_transaction_time_per_block_ms:
type: integer
description: Максимальное время отложенных транзакций на блок (мс)
example: 100
subjective_cpu_leeway_us:
type: integer
description: Допуск субъективного CPU (мкс)
example: 10
incoming_defer_ratio:
type: string
description: Доля входящих отложенных транзакций (строка, парсится в double)
example: "1.00000000000000000"
greylist_limit:
type: integer
description: Лимит числа имён (Name) в сером списке
example: 1000
+50
View File
@@ -0,0 +1,50 @@
type: "object"
additionalProperties: false
required:
- "version"
- "types"
- "structs"
- "actions"
- "tables"
- "abi_extensions"
- "error_messages"
- "ricardian_clauses"
- "variants"
properties:
version:
type: string
description: Строка версии ABI.
types:
type: "array"
items:
$ref: "AbiType.yaml"
structs:
type: "array"
items:
$ref: "AbiStruct.yaml"
actions:
type: "array"
items:
$ref: "AbiAction.yaml"
tables:
type: "array"
items:
$ref: "AbiTable.yaml"
abi_extensions:
type: "array"
items:
$ref: "Extension.yaml"
error_messages:
type: "array"
items:
type: "string"
ricardian_clauses:
type: "array"
items:
type: "string"
variants:
type: "array"
items:
type: "string"
title: ABI контракта
+17
View File
@@ -0,0 +1,17 @@
type: object
additionalProperties: false
required:
- name
- type
- ricardian_contract
properties:
name:
type: string
description: Имя действия.
type:
type: string
description: Имя структуры аргументов действия.
ricardian_contract:
type: string
description: Текст Ricardian-контракта (может быть пустым).
title: Действие в ABI
+29
View File
@@ -0,0 +1,29 @@
type: object
additionalProperties: false
required:
- name
- base
- fields
properties:
name:
type: string
description: Имя структуры.
base:
type: string
description: Базовая структура (может быть пустой строкой).
fields:
type: array
description: Поля структуры.
items:
type: object
required:
- name
- type
properties:
name:
type: string
description: Имя поля.
type:
type: string
description: Тип поля в нотации ABI.
title: Структура ABI
+29
View File
@@ -0,0 +1,29 @@
type: object
additionalProperties: false
required:
- name
- index_type
- key_names
- key_types
- type
properties:
name:
type: string
description: Имя таблицы.
index_type:
type: string
description: Тип индекса (например primary).
key_names:
type: array
description: Имена ключей индекса.
items:
type: string
key_types:
type: array
description: Типы ключей.
items:
type: string
type:
type: string
description: Имя структуры строки таблицы.
title: Таблица ABI
+13
View File
@@ -0,0 +1,13 @@
type: object
additionalProperties: false
required:
- new_type_name
- type
properties:
new_type_name:
type: string
description: Имя нового типа в ABI.
type:
type: string
description: Исходный тип или алиас.
title: Тип ABI
+63
View File
@@ -0,0 +1,63 @@
type: "object"
additionalProperties: false
minProperties: 18
required:
- "account_name"
- "head_block_num"
- "head_block_time"
- "last_code_update"
- "created"
- "refund_request"
- "ram_quota"
- "net_limit"
- "cpu_limit"
- "total_resources"
- "core_liquid_balance"
- "self_delegated_bandwidth"
- "net_weight"
- "cpu_weight"
- "ram_usage"
- "privileged"
- "permissions"
- "voter_info"
properties:
account_name:
$ref: "Name.yaml"
head_block_num:
type: "integer"
head_block_time:
$ref: "DateTimeSeconds.yaml"
last_code_update:
$ref: "DateTimeSeconds.yaml"
created:
$ref: "DateTimeSeconds.yaml"
refund_request:
$ref: "RefundRequest.yaml"
ram_quota:
$ref: "WholeNumber.yaml"
net_limit:
$ref: "ResourceLimits.yaml"
cpu_limit:
$ref: "ResourceLimits.yaml"
total_resources:
$ref: "ResourceOverview.yaml"
core_liquid_balance:
$ref: "Symbol.yaml"
self_delegated_bandwidth:
$ref: "ResourceDelegation.yaml"
net_weight:
$ref: "WholeNumber.yaml"
cpu_weight:
$ref: "WholeNumber.yaml"
ram_usage:
$ref: "WholeNumber.yaml"
privileged:
type: "boolean"
permissions:
type: "array"
items:
$ref: "Permission.yaml"
voter_info:
$ref: "VoterInfo.yaml"
title: Учётная запись
+23
View File
@@ -0,0 +1,23 @@
type: object
additionalProperties: false
required:
- account
- name
- authorization
- data
properties:
account:
description: Учётная запись контракта, которому принадлежит действие.
$ref: Name.yaml
name:
description: Имя действия (action).
$ref: Name.yaml
authorization:
description: Список уровней разрешения, авторизующих действие.
type: array
items:
$ref: PermissionLevel.yaml
data:
type: string
description: Аргументы действия в шестнадцатеричном виде.
title: Действие (action)
+27
View File
@@ -0,0 +1,27 @@
type: object
description: Трассировка одного действия (формат v0).
additionalProperties: true
properties:
receipt:
type: object
description: Квитанция выполнения действия.
act:
$ref: Action.yaml
elapsed:
type: integer
description: Время выполнения, микросекунды.
console:
type: string
description: Вывод из print контракта.
trx_id:
$ref: Sha256.yaml
block_num:
type: integer
block_time:
type: string
producer_block_id:
$ref: Sha256.yaml
except:
type: string
description: Сообщение об ошибке, если действие завершилось сбоем.
title: Трассировка действия v0
+35
View File
@@ -0,0 +1,35 @@
type: object
description: Трассировка действия (формат v2), расширенные поля.
additionalProperties: true
properties:
action_ordinal:
type: integer
description: Порядковый номер действия в транзакции.
creator_action_ordinal:
type: integer
receipt:
type: object
description: Квитанция выполнения.
receiver:
type: string
description: Получатель действия (имя аккаунта).
act:
$ref: Action.yaml
context_free:
type: boolean
elapsed:
type: integer
description: Время выполнения, микросекунды.
console:
type: string
trx_id:
$ref: Sha256.yaml
block_num:
type: integer
block_time:
type: string
producer_block_id:
$ref: Sha256.yaml
except:
type: string
title: Трассировка действия v2
+44
View File
@@ -0,0 +1,44 @@
# Полномочие учётной записи (threshold / keys / accounts / waits).
type: object
additionalProperties: false
required:
- threshold
- keys
- accounts
- waits
properties:
threshold:
type: integer
description: Сумма весов, необходимая для удовлетворения полномочия.
keys:
type: array
description: Список ключей с весами.
items:
type: object
required:
- key
- weight
properties:
key:
$ref: PublicKey.yaml
weight:
type: integer
accounts:
type: array
description: Делегированные полномочия других аккаунтов.
items:
type: object
required:
- permission
- weight
properties:
permission:
$ref: PermissionLevel.yaml
weight:
type: integer
waits:
type: array
description: Задержки по времени (для мультиподписи со временем ожидания).
items:
$ref: WaitWeight.yaml
title: Полномочие (authority)
+59
View File
@@ -0,0 +1,59 @@
type: object
additionalProperties: false
minProperties: 9
required:
- timestamp
- producer
- confirmed
- previous
- transaction_mroot
- action_mroot
- schedule_version
- new_producers
- producer_signature
properties:
timestamp:
$ref: DateTimeSeconds.yaml
producer:
oneOf:
- $ref: EmptyString.yaml
- $ref: Name.yaml
confirmed:
description: Число предыдущих блоков, подтверждённых этим продюсером в текущем расписании.
type: integer
previous:
$ref: Sha256.yaml
transaction_mroot:
$ref: Sha256.yaml
action_mroot:
$ref: Sha256.yaml
schedule_version:
description: Сколько раз расписание продюсеров менялось с генезиса.
type: integer
new_producers:
$ref: ProducerSchedule.yaml
header_extensions:
$ref: Extension.yaml
new_protocol_features:
description: Новые протокольные возможности, активированные в блоке.
type: array
items:
type: object
producer_signature:
$ref: Signature.yaml
transactions:
description: Квитанции транзакций, включённых в блок.
type: array
items:
$ref: TransactionReceipt.yaml
block_extensions:
$ref: Extension.yaml
id:
$ref: Sha256.yaml
block_num:
description: Высота блока в цепи.
type: integer
ref_block_prefix:
description: 32-битная часть идентификатора блока.
type: integer
title: Блок
+72
View File
@@ -0,0 +1,72 @@
type: "object"
additionalProperties: false
minProperties: 16
required:
- "id"
- "block_num"
- "header"
- "dpos_proposed_irreversible_blocknum"
- "dpos_irreversible_blocknum"
- "bft_irreversible_blocknum"
- "pending_schedule_lib_num"
- "pending_schedule_hash"
- "pending_schedule"
- "active_schedule"
- "blockroot_merkle"
- "producer_to_last_produced"
- "producer_to_last_implied_irb"
- "block_signing_key"
- "confirm_count"
- "confirmations"
properties:
id:
type: string
description: Идентификатор блока.
block_num:
description: Высота блока в цепи.
type: "integer"
header:
$ref: "Block.yaml"
dpos_proposed_irreversible_blocknum:
$ref: "WholeNumber.yaml"
dpos_irreversible_blocknum:
$ref: "WholeNumber.yaml"
bft_irreversible_blocknum:
$ref: "WholeNumber.yaml"
pending_schedule_lib_num:
$ref: "WholeNumber.yaml"
pending_schedule_hash:
$ref: "Sha256.yaml"
pending_schedule:
$ref: "ProducerSchedule.yaml"
active_schedule:
$ref: "ProducerSchedule.yaml"
blockroot_merkle:
$ref: "BlockrootMerkle.yaml"
producer_to_last_produced:
type: "array"
items:
type: "array"
items:
anyOf:
- $ref: "Name.yaml"
- $ref: "WholeNumber.yaml"
producer_to_last_implied_irb:
type: "array"
items:
type: "array"
items:
anyOf:
- $ref: "Name.yaml"
- $ref: "WholeNumber.yaml"
block_signing_key:
$ref: "PublicKey.yaml"
confirm_count:
type: "array"
items:
$ref: "WholeNumber.yaml"
confirmations:
type: "array"
items: {}
title: Состояние заголовка блока
+49
View File
@@ -0,0 +1,49 @@
type: object
additionalProperties: false
minProperties: 12
required:
- block_num
- ref_block_num
- id
- timestamp
- producer
- confirmed
- previous
- transaction_mroot
- action_mroot
- schedule_version
- producer_signature
- ref_block_prefix
properties:
block_num:
description: Высота блока в цепи.
type: integer
ref_block_num:
description: Младшие 16 бит номера блока (ссылка на блок в транзакции).
type: integer
id:
$ref: Sha256.yaml
timestamp:
$ref: DateTimeSeconds.yaml
producer:
oneOf:
- $ref: EmptyString.yaml
- $ref: Name.yaml
confirmed:
description: Число предыдущих блоков, подтверждённых продюсером этого блока в текущем расписании.
type: integer
previous:
$ref: Sha256.yaml
transaction_mroot:
$ref: Sha256.yaml
action_mroot:
$ref: Sha256.yaml
schedule_version:
description: Сколько раз расписание продюсеров менялось с генезиса.
type: integer
producer_signature:
$ref: Signature.yaml
ref_block_prefix:
description: 32-битная часть идентификатора блока.
type: integer
title: Краткие сведения о блоке
+35
View File
@@ -0,0 +1,35 @@
type: "object"
additionalProperties: false
minProperties: 7
required:
- "id"
- "number"
- "previous_id"
- "status"
- "timestamp"
- "producer"
- "transactions"
properties:
id:
$ref: "Sha256.yaml"
number:
description: Высота блока в цепи.
type: "integer"
previous_id:
$ref: "Sha256.yaml"
status:
description: Состояние блока — ожидает финализации или необратим.
type: "string"
timestamp:
$ref: "DateTimeSeconds.yaml"
producer:
oneOf:
- $ref: "EmptyString.yaml"
- $ref: "Name.yaml"
transactions:
description: Список трассировок транзакций из блока.
type: "array"
items:
$ref: "TransactionTraceV0.yaml"
title: Трассировка блока (v0)
+45
View File
@@ -0,0 +1,45 @@
type: "object"
additionalProperties: false
minProperties: 10
required:
- "id"
- "number"
- "previous_id"
- "status"
- "timestamp"
- "producer"
- "transaction_mroot"
- "action_mroot"
- "schedule_version"
- "transactions"
properties:
id:
$ref: "Sha256.yaml"
number:
description: Высота блока в цепи.
type: "integer"
previous_id:
$ref: "Sha256.yaml"
status:
description: Состояние блока — ожидает финализации или необратим.
type: "string"
timestamp:
$ref: "DateTimeSeconds.yaml"
producer:
oneOf:
- $ref: "EmptyString.yaml"
- $ref: "Name.yaml"
transaction_mroot:
$ref: "Sha256.yaml"
action_mroot:
$ref: "Sha256.yaml"
schedule_version:
description: Сколько раз расписание продюсеров менялось с генезиса.
type: "integer"
transactions:
description: Список трассировок транзакций из блока.
type: "array"
items:
$ref: "TransactionTraceV1.yaml"
title: Трассировка блока (v1)
+69
View File
@@ -0,0 +1,69 @@
type: object
properties:
id:
$ref: "Sha256.yaml"
number:
type: integer
example: 31
previous_id:
$ref: "Sha256.yaml"
status:
type: string
enum:
- "irreversible"
- "executed"
- "pending"
- "soft_fail"
- "hard_fail"
- "delayed"
- "expired"
example: executed
timestamp:
type: string
example: "2019-06-18T00:00:00"
producer:
type: string
example: myproducer
transaction_mroot:
$ref: "Sha256.yaml"
action_mroot:
$ref: "Sha256.yaml"
schedule_version:
type: integer
example: 1
transactions:
oneOf:
- title: Транзакции формата v3
type: array
items:
type: object
properties:
block_num:
type: integer
example: 31
block_time:
type: string
example: "2019-06-18T00:00:00"
producer_block_id:
$ref: "Sha256.yaml"
- title: Транзакции формата v2
type: array
items:
type: object
properties:
id:
$ref: "Sha256.yaml"
block_num:
type: integer
example: 31
block_time:
type: string
example: "2019-06-18T00:00:00"
producer_block_id:
$ref: "Sha256.yaml"
actions:
type: array
items:
$ref: "ActionTraceV2.yaml"
transaction_header:
$ref: "TransactionHeader.yaml"
+9
View File
@@ -0,0 +1,9 @@
type: object
description: Корень Меркла для связанных блоков в состоянии заголовка.
properties:
_active_nodes:
type: array
description: Активные узлы дерева Меркла (hex-строки).
items:
type: string
title: Дерево Меркла корней блоков
+4
View File
@@ -0,0 +1,4 @@
type: string
description: Сигнатура действия в стиле C++ (имя для чёрного списка действий).
pattern: "^([a-z1-9]{1}[a-z1-9_]{0,30}[a-z1-9]{1})$"
title: Сигнатура действия (C++)
+3
View File
@@ -0,0 +1,3 @@
type: string
description: Дата и время истечения транзакции (строка в формате, принимаемом узлом COOPOS).
title: Дата и время
+4
View File
@@ -0,0 +1,4 @@
type: string
description: Дата и время в формате YYYY-MM-DDTHH:MM:SS.sss
pattern: "^[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}.[0-9]{3}$"
title: Дата и время с секундами
+5
View File
@@ -0,0 +1,5 @@
type: string
enum:
- ""
description: Единственное допустимое значение — пустая строка (например поле продюсера в особых случаях).
title: Пустая строка
+13
View File
@@ -0,0 +1,13 @@
type: object
additionalProperties: false
required:
- type
- data
properties:
type:
type: integer
description: Числовой идентификатор типа расширения.
data:
type: string
description: Данные расширения (часто hex).
title: Расширение (extension)
+65
View File
@@ -0,0 +1,65 @@
type: object
additionalProperties: false
required:
- server_version
- chain_id
- head_block_num
- head_block_id
- head_block_time
- head_block_producer
- last_irreversible_block_num
- last_irreversible_block_id
- virtual_block_cpu_limit
- virtual_block_net_limit
- block_cpu_limit
- block_net_limit
- server_version_string
- fork_db_head_block_num
- fork_db_head_block_id
properties:
server_version:
type: string
description: Хеш последнего коммита в помеченном релизе узла.
chain_id:
type: string
description: Идентификатор цепи (хеш).
head_block_num:
type: integer
description: Номер головного (последнего) блока в цепи.
head_block_id:
type: string
description: Идентификатор головного блока.
head_block_time:
type: string
description: Метка времени головного блока (Unix).
head_block_producer:
type: string
description: Продюсер, подписавший головной блок.
last_irreversible_block_num:
type: integer
description: Номер последнего необратимо применённого к состоянию блока.
last_irreversible_block_id:
type: string
description: Идентификатор последнего необратимого блока.
virtual_block_cpu_limit:
type: integer
description: Виртуальный лимит CPU после производства блока (порядка 1000× block_cpu_limit).
virtual_block_net_limit:
type: integer
description: Виртуальный лимит NET после производства блока (порядка 1000× block_net_limit).
block_cpu_limit:
type: integer
description: Фактический максимальный лимит CPU на блок.
block_net_limit:
type: integer
description: Фактический максимальный лимит NET на блок.
server_version_string:
type: string
description: Строка версии узла (формат «крупная.средняя.мелкая»; не строгий SEMVER).
fork_db_head_block_num:
type: integer
description: Номер лучшей известной головы в дереве базы форков.
fork_db_head_block_id:
type: string
description: Идентификатор лучшей известной головы в базе форков.
title: Сведения о цепи и узле
+3
View File
@@ -0,0 +1,3 @@
type: string
description: Публичный ключ в строковом представлении (для списков ключей узла).
title: Тип/значение ключа
+6
View File
@@ -0,0 +1,6 @@
anyOf:
- $ref: NamePrivileged.yaml
- $ref: NameBasic.yaml
- $ref: NameBid.yaml
- $ref: NameCatchAll.yaml
title: Имя учётной записи
+4
View File
@@ -0,0 +1,4 @@
type: string
pattern: '^[a-z1-5\.]{1,12}$'
description: Обычное имя учётной записи (до 12 символов, a-z, 1-5, точка).
title: Базовое имя
+4
View File
@@ -0,0 +1,4 @@
type: string
pattern: '^[a-z1-5\.]{1,12}$'
description: Имя, связанное с аукционом имён (.eos и т.п., формат узла).
title: Имя из аукциона
+4
View File
@@ -0,0 +1,4 @@
type: string
pattern: '^[a-z1-5\.]{1,12}$'
description: Прочие допустимые имена в соответствии с правилами узла.
title: Прочее имя
+4
View File
@@ -0,0 +1,4 @@
type: string
pattern: '^[a-z1-5\.]{1,13}$'
description: Имя привилегированной учётной записи (подмножество правил имён COOPOS).
title: Привилегированное имя
+17
View File
@@ -0,0 +1,17 @@
type: object
additionalProperties: false
required:
- perm_name
- parent
- required_auth
properties:
perm_name:
description: Имя разрешения (например active, owner).
$ref: Name.yaml
parent:
description: Родительское разрешение.
$ref: Name.yaml
required_auth:
description: Требуемое полномочие для удовлетворения этого разрешения.
$ref: Authority.yaml
title: Разрешение учётной записи
+13
View File
@@ -0,0 +1,13 @@
# Уровень разрешения (actor + permission) — как в теле действия.
type: object
additionalProperties: false
required:
- actor
- permission
properties:
actor:
$ref: Name.yaml
permission:
$ref: Name.yaml
title: Уровень разрешения
description: Пара «аккаунт — имя разрешения» для авторизации действия.
+18
View File
@@ -0,0 +1,18 @@
type: object
description: Сведения о продюсере блокчейна.
properties:
owner:
type: string
description: Имя учётной записи продюсера.
producer_authority:
$ref: ProducerAuthorityList.yaml
url:
type: string
description: URL продюсера (сайт, метаданные).
total_votes:
type: string
description: Суммарный вес голосов за продюсера (строка с большим целым).
producer_key:
type: string
description: Зарегистрированный публичный ключ продюсера.
title: Продюсер
@@ -0,0 +1,4 @@
description: Полномочия продюсера (подпись блоков); структура совпадает с authority.
allOf:
- $ref: Authority.yaml
title: Полномочия продюсера
+17
View File
@@ -0,0 +1,17 @@
type: object
description: Расписание продюсеров и его версия.
properties:
version:
type: integer
description: Версия расписания (увеличивается при каждом изменении).
producers:
type: array
description: Список продюсеров.
items:
type: object
properties:
producer_name:
type: string
description: Имя продюсера.
authority:
$ref: ProducerAuthorityList.yaml
+4
View File
@@ -0,0 +1,4 @@
type: string
description: Публичный ключ в кодировке Base58 (префиксы EOS, PUB_K1_, PUB_R1_, PUB_WA_).
pattern: "^(EOS|PUB_([RK]1|WA)_)[1-9A-HJ-NP-Za-km-z]+$"
title: Публичный ключ
+12
View File
@@ -0,0 +1,12 @@
type: object
nullable: true
description: Запрос на возврат делегированных ресурсов (если есть).
properties:
owner:
$ref: Name.yaml
request_time:
$ref: DateTimeSeconds.yaml
net_amount:
type: string
description: Сумма NET к возврату (строка актива).
title: Запрос возврата
+12
View File
@@ -0,0 +1,12 @@
type: object
description: Самоделегирование полосы пропускания (NET/CPU).
properties:
from:
$ref: Name.yaml
to:
$ref: Name.yaml
net_weight:
$ref: WholeNumber.yaml
cpu_weight:
$ref: WholeNumber.yaml
title: Делегирование ресурсов
+10
View File
@@ -0,0 +1,10 @@
type: object
description: Лимиты ресурса (NET или CPU) для учётной записи.
properties:
used:
$ref: WholeNumber.yaml
available:
$ref: WholeNumber.yaml
max:
$ref: WholeNumber.yaml
title: Лимиты ресурса
+12
View File
@@ -0,0 +1,12 @@
type: object
description: Сводка выделенных ресурсов.
properties:
owner:
$ref: Name.yaml
ram_bytes:
$ref: WholeNumber.yaml
net_weight:
$ref: WholeNumber.yaml
cpu_weight:
$ref: WholeNumber.yaml
title: Обзор ресурсов
+4
View File
@@ -0,0 +1,4 @@
type: string
pattern: "^[0-9A-Fa-f]{64}$"
description: 64-символьная шестнадцатеричная строка (хеш SHA-256).
title: Хеш SHA-256
+4
View File
@@ -0,0 +1,4 @@
type: string
description: Криптографическая подпись в Base58 (префикс SIG_ и тип ключа R1/K1/WA).
pattern: "^SIG_([RK]1|WA)_[1-9A-HJ-NP-Za-km-z]+$"
title: Подпись
+4
View File
@@ -0,0 +1,4 @@
type: string
description: Строка актива COOPOS — дробная часть с точностью 4 и символ из 1–7 заглавных букв через пробел, например «1.0000 ABC».
pattern: "^([0-9]{1,32}.[0-9]{4} [A-Z]{1,7})$"
title: Символ актива
+22
View File
@@ -0,0 +1,22 @@
type: object
additionalProperties: false
minProperties: 5
required:
- code
- scope
- table
- payer
- count
properties:
code:
$ref: Name.yaml
scope:
$ref: Name.yaml
table:
$ref: Name.yaml
payer:
$ref: Name.yaml
count:
description: Число строк (записей), попадающих в область.
type: integer
title: Область таблицы (scope)
+42
View File
@@ -0,0 +1,42 @@
type: "object"
additionalProperties: false
minProperties: 8
required:
- "expiration"
- "ref_block_num"
- "ref_block_prefix"
- "max_net_usage_words"
- "max_cpu_usage_ms"
- "delay_sec"
- "context_free_actions"
- "actions"
properties:
expiration:
description: Момент времени, до которого транзакция должна быть принята в блок.
allOf:
- $ref: DateTime.yaml
ref_block_num:
type: "integer"
ref_block_prefix:
description: 32-битная часть идентификатора блока.
type: integer
max_net_usage_words:
$ref: "WholeNumber.yaml"
max_cpu_usage_ms:
$ref: "WholeNumber.yaml"
delay_sec:
type: "integer"
context_free_actions:
type: "array"
items:
$ref: "Action.yaml"
actions:
type: "array"
items:
$ref: "Action.yaml"
transaction_extensions:
type: "array"
items:
$ref: "Extension.yaml"
title: Транзакция
+27
View File
@@ -0,0 +1,27 @@
type: object
additionalProperties: false
required:
- expiration
- ref_block_num
- ref_block_prefix
- max_net_usage_words
- max_cpu_usage_ms
- delay_sec
properties:
expiration:
description: Время, до которого транзакция должна быть подтверждена.
$ref: DateTime.yaml
ref_block_num:
type: integer
description: Номер блока отсчёта (uint16-часть ссылки на блок).
ref_block_prefix:
type: integer
description: 32-битный префикс идентификатора блока.
max_net_usage_words:
$ref: WholeNumber.yaml
max_cpu_usage_ms:
$ref: WholeNumber.yaml
delay_sec:
type: integer
description: Отложенное выполнение, секунды.
title: Заголовок транзакции
+17
View File
@@ -0,0 +1,17 @@
type: object
description: Квитанция о включении транзакции в блок.
properties:
status:
type: string
description: Статус обработки транзакции в блоке.
cpu_usage_us:
type: integer
description: Использование CPU, микросекунды.
net_usage_words:
type: integer
description: Использование сети, в 64-битных словах.
trx:
description: Упакованная транзакция и связанные поля (формат зависит от версии узла).
type: object
additionalProperties: true
title: Квитанция транзакции
+60
View File
@@ -0,0 +1,60 @@
type: object
additionalProperties: false
minProperties: 8
required:
- state
- head_number
- head_id
- head_timestamp
- irreversible_number
- irreversible_id
- irreversible_timestamp
- last_tracked_block_id
properties:
state:
description: |
Состояние транзакции. Возможные значения:
LOCALLY_APPLIED, FORKED_OUT, IN_BLOCK, IRREVERSIBLE, FAILED, UNKNOWN.
type: string
block_number:
description: Номер блока, в который включена транзакция (если применимо).
type: integer
block_id:
description: Идентификатор блока с транзакцией.
allOf:
- $ref: Sha256.yaml
block_timestamp:
description: Метка времени блока с транзакцией.
allOf:
- $ref: DateTime.yaml
expiration:
description: Время истечения транзакции.
allOf:
- $ref: DateTimeSeconds.yaml
head_number:
description: Номер головного блока на момент запроса.
type: integer
head_id:
description: Идентификатор головного блока.
allOf:
- $ref: Sha256.yaml
head_timestamp:
description: Метка времени головного блока.
allOf:
- $ref: DateTime.yaml
irreversible_number:
description: Номер последнего необратимого блока.
type: integer
irreversible_id:
description: Идентификатор последнего необратимого блока.
allOf:
- $ref: Sha256.yaml
irreversible_timestamp:
description: Метка времени последнего необратимого блока.
allOf:
- $ref: DateTime.yaml
last_tracked_block_id:
description: Идентификатор последнего отслеживаемого блока для статуса.
allOf:
- $ref: Sha256.yaml
title: Статус транзакции
+15
View File
@@ -0,0 +1,15 @@
type: "object"
additionalProperties: false
minProperties: 2
required:
- "id"
- "actions"
properties:
id:
$ref: "Sha256.yaml"
actions:
type: "array"
items:
$ref: "ActionTraceV0.yaml"
title: Трассировка транзакции (v0)
+45
View File
@@ -0,0 +1,45 @@
type: "object"
additionalProperties: false
minProperties: 7
required:
- "id"
- "actions"
- "status"
- "cpu_usage_us"
- "net_usage_words"
- "signatures"
- "transaction_header"
properties:
id:
$ref: "Sha256.yaml"
actions:
type: "array"
items:
$ref: "ActionTraceV0.yaml"
status:
type: "string"
enum:
- "executed"
- "soft_fail"
- "hard_fail"
- "delayed"
- "expired"
description: |
Статус выполнения:
* executed — успех, обработчик ошибок не вызывался;
* soft_fail — объективный сбой (не выполнено), сработал обработчик ошибок;
* hard_fail — сбой и сбой обработчика, состояние не менялось;
* delayed — отложенная транзакция;
* expired — истек срок, место в хранилище возвращено.
cpu_usage_us:
type: "integer"
net_usage_words:
type: "integer"
signatures:
type: "array"
items:
$ref: "Signature.yaml"
transaction_header:
$ref: "TransactionHeader.yaml"
title: Трассировка транзакции (v1)
+56
View File
@@ -0,0 +1,56 @@
type: object
properties:
id:
$ref: "Sha256.yaml"
number:
type: integer
example: 31
previous_id:
$ref: "Sha256.yaml"
status:
type: string
enum:
- "irreversible"
- "executed"
- "pending"
- "soft_fail"
- "hard_fail"
- "delayed"
- "expired"
example: executed
timestamp:
type: string
example: "2019-06-18T00:00:00"
producer:
type: string
example: myproducer
transaction_mroot:
$ref: "Sha256.yaml"
action_mroot:
$ref: "Sha256.yaml"
schedule_version:
type: integer
example: 1
transactions:
type: array
items:
type: object
properties:
id:
$ref: "Sha256.yaml"
block_num:
type: integer
example: 31
block_time:
type: string
example: "2019-06-18T00:00:00"
producer_block_id:
$ref: "Sha256.yaml"
actions:
type: array
items:
$ref: "ActionTraceV2.yaml"
transaction_header:
$ref: "TransactionHeader.yaml"
title: Трассировка транзакции (v2)
+16
View File
@@ -0,0 +1,16 @@
type: "object"
additionalProperties: false
minProperties: 2
required:
- "block_num"
- "block_time"
properties:
block_num:
number:
type: "integer"
block_time:
$ref: "DateTimeSeconds.yaml"
producer_block_id:
$ref: "Sha256.yaml"
title: Трассировка транзакции (v3)
+23
View File
@@ -0,0 +1,23 @@
type: object
description: Сведения об участии учётной записи в голосовании за продюсеров.
additionalProperties: true
properties:
owner:
$ref: Name.yaml
proxy:
description: Имя прокси голосования; пустое, если голосует самостоятельно.
type: string
producers:
type: array
description: Список имён продюсеров, за которых отданы голоса.
items:
$ref: Name.yaml
staked:
type: string
description: Застейканная сумма (строка).
last_vote_weight:
type: string
is_proxy:
type: integer
description: 1, если аккаунт является прокси.
title: Информация голосующего
+13
View File
@@ -0,0 +1,13 @@
type: object
additionalProperties: false
required:
- wait_sec
- weight
properties:
wait_sec:
type: integer
description: Ожидание в секундах.
weight:
type: integer
description: Вес, применяемый после ожидания.
title: Вес с задержкой
+4
View File
@@ -0,0 +1,4 @@
type: integer
minimum: 0
description: Неотрицательное целое (в цепи часто соответствует uint64).
title: Неотрицательное целое
+232
View File
@@ -0,0 +1,232 @@
openapi: 3.0.0
info:
title: API трассировки COOPOS
description: Спецификация Trace API узла COOPOS (nodeos). Включение плагина и параметры — в документации разработчика на https://coopenomics.world.
version: 1.0.0
license:
name: MIT
url: https://opensource.org/licenses/MIT
contact:
url: https://coopenomics.world
servers:
- url: '{protocol}://{host}:{port}/v1/'
variables:
protocol:
enum:
- http
- https
default: http
host:
default: localhost
port:
default: "8080"
components:
schemas:
TRACE:
type: object
properties:
global_squence:
type: integer
example: 669
receiver:
type: string
example: myproducer
account:
type: string
example: esio.token
action:
type: string
example: transfer
authorization:
type: array
items:
type: object
properties:
account:
type: string
example: myaccount
permission:
type: string
example: active
data:
type: string
$ref: "schemas/Sha256.yaml"
return_value:
type: string
example: ""
params:
type: object
properties:
from:
type: string
example: eosio
to:
type: string
example: myproducer
quantity:
type: string
example: "10.000 SYS"
memo:
type: string
example: "first transfer"
ERROR_DETAILS:
type: object
properties:
code:
type: integer
example: 0
name:
type: string
what:
type: string
details:
type: array
items:
type: string
security:
- {}
paths:
/trace_api/get_block:
post:
summary: Получить блок
description: Возвращает объект трассировки блока с отработанными действиями и сопутствующими метаданными.
operationId: get_block
requestBody:
content:
application/json:
schema:
type: object
required:
- block_num
properties:
block_num:
type: integer
description: Номер блока
responses:
"200":
description: Успешно — корректное тело ответа
content:
application/json:
schema:
oneOf:
- $ref: "schemas/BlockTraceV0.yaml"
- $ref: "schemas/BlockTraceV1.yaml"
- $ref: "schemas/BlockTraceV2.yaml"
"400":
description: Ошибка — неверный номер блока (не число, превышает максимум int)
content:
application/json:
schema:
type: object
properties:
code:
type: integer
example: 400
message:
type: string
example: "bad or missing block_num"
error:
$ref: "#/components/schemas/ERROR_DETAILS"
"404":
description: Ошибка — на узле нет запрошенных данных
content:
application/json:
schema:
type: object
properties:
code:
type: integer
example: 400
message:
type: string
example: "bad or missing block_num"
error:
$ref: "#/components/schemas/ERROR_DETAILS"
"500":
description: Ошибка — аварийная ситуация при получении трассировки блока (например повреждённые файлы)
content:
application/json:
schema:
type: object
properties:
code:
type: integer
example: 500
message:
type: string
example: "Trace API encountered an Error which it cannot recover from. Please resolve the error and relaunch the process"
error:
$ref: "#/components/schemas/ERROR_DETAILS"
/trace_api/get_transaction_trace:
post:
summary: Трассировка транзакции
description: Сканирует файлы трассировки в поиске указанной транзакции.
operationId: get_transaction_trace
requestBody:
content:
application/json:
schema:
type: object
required:
- id
properties:
id:
type: integer
description: Идентификатор транзакции
responses:
"200":
description: Успешно
content:
application/json:
schema:
oneOf:
- $ref: "schemas/TransactionTraceV0.yaml"
- $ref: "schemas/TransactionTraceV1.yaml"
- $ref: "schemas/TransactionTraceV2.yaml"
- $ref: "schemas/TransactionTraceV3.yaml"
"400":
description: Ошибка — неверный запрос (некорректный идентификатор транзакции)
content:
application/json:
schema:
type: object
properties:
code:
type: integer
example: 400
message:
type: string
example: "bad or missing block_num"
error:
$ref: "#/components/schemas/ERROR_DETAILS"
"404":
description: Ошибка — на узле нет запрошенных данных
content:
application/json:
schema:
type: object
properties:
code:
type: integer
example: 400
message:
type: string
example: "bad or missing block_num"
error:
$ref: "#/components/schemas/ERROR_DETAILS"
"500":
description: Ошибка — аварийная ситуация при получении трассировки транзакции (например повреждённые файлы)
content:
application/json:
schema:
type: object
properties:
code:
type: integer
example: 500
message:
type: string
example: "Trace API encountered an Error which it cannot recover from. Please resolve the error and relaunch the process"
error:
$ref: "#/components/schemas/ERROR_DETAILS"
BIN
View File
Binary file not shown.
+1 -1
View File
@@ -1 +1 @@
dicoop.space
docs.coopenomics.world
Binary file not shown.

After

Width:  |  Height:  |  Size: 265 KiB

BIN
View File
Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 MiB

Some files were not shown because too many files have changed in this diff Show More