tari_core 0.8.1

Core Tari protocol components
syntax = "proto3";

import "transaction.proto";
import "block.proto";
import "chain_metadata.proto";

package tari.base_node;

// Response type for a received BaseNodeService requests
message BaseNodeServiceResponse {
    uint64 request_key = 1;
    oneof response {
        // Indicates a ChainMetadata response.
        ChainMetadata chain_metadata = 2;
        // Indicates a TransactionKernels response.
        TransactionKernels transaction_kernels = 3;
        // Indicates a BlockHeaders response.
        BlockHeaders block_headers = 4;
        // Indicates a TransactionOutputs response.
        TransactionOutputs transaction_outputs = 5;
        // Indicates a HistoricalBlocks response.
        HistoricalBlocks historical_blocks = 6;
        // Indicates a NewBlockTemplate response.
        tari.core.NewBlockTemplate new_block_template = 7;
        // Indicates a NewBlock response.
        NewBlockResponse new_block = 8;
        // Indicates a TargetDifficulty response.
        uint64 target_difficulty = 9;
        // Block headers in range response
        BlockHeaders fetch_headers_after_response = 10;
        // Indicates a MmrNodes response
        MmrNodes MmrNodes = 12;
    }
    bool is_synced = 13;
}

message BlockHeaders {
    repeated tari.core.BlockHeader headers = 1;
}

message TransactionKernels {
    repeated tari.types.TransactionKernel kernels = 1;
}

message TransactionOutputs {
    repeated tari.types.TransactionOutput outputs = 1;
}

message HistoricalBlocks {
    repeated tari.core.HistoricalBlock blocks = 1;
}

message NewBlockResponse {
    bool success = 1;
    string error = 2;
    tari.core.Block block = 3;
 }

 message MmrNodes {
    repeated bytes added = 1;
    bytes deleted = 2;
}