NetworkCoinsTransferResult network.coins-transfer-result@1

Generated at from openvibe-contracts v0.53.0 and openvibe-sdk v0.11.0.

Version
1.0.0
Owner
network
Visibility
first-party
Status
active
Compatibility
backward
Schema
https://openvibe.network/contracts/network/coins-transfer-result.v1.json

network.coins-transfer-result@1: the answer of network.coins.transfer on OpenVibe.Network. POST /internal/coins/transfer → { from_balance, to_balance }: both wallets right after the transfer (a replayed idempotency_key answers the balances of the original transfer). Refusals are listed on network.coins-transfer-request@1.

Fields

FieldTypeRequiredDescriptionConstraints
from_balanceintegeryes
  • minimum 0
to_balanceintegeryes
  • minimum 0

Examples

From the contract's own test fixtures: valid ones validate, rejected ones must fail.

Valid: balances
{
  "from_balance": 960,
  "to_balance": 140
}
Rejected: missing-to
{
  "from_balance": 960
}

Validate

const contracts = require('openvibe-contracts');
contracts.validate('network.coins-transfer-result@1', value);   // { valid, errors: [{ path, message }] }