daml/ledger-api/grpc-definitions/com/digitalasset/ledger/api/v1/transaction.proto
Digital Asset GmbH 05e691f558 open-sourcing daml
2019-04-04 09:33:38 +01:00

98 lines
2.5 KiB
Protocol Buffer

// Copyright (c) 2019 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved.
// SPDX-License-Identifier: Apache-2.0
syntax = "proto3";
package com.digitalasset.ledger.api.v1;
import "com/digitalasset/ledger/api/v1/event.proto";
import "com/digitalasset/ledger/api/v1/trace_context.proto";
import "google/protobuf/timestamp.proto";
option java_outer_classname = "TransactionOuterClass";
option java_package = "com.digitalasset.ledger.api.v1";
// Complete view of an on-ledger transaction.
message TransactionTree {
// Assigned by the server. Useful for correlating logs.
// Required
string transaction_id = 1;
// The ID of the command which resulted in this transaction. Missing for everyone except the submitting party.
// Optional
string command_id = 2;
// The workflow id used in command submission. Only set if the workflow_id for the command was set.
// Optional
string workflow_id = 3;
// Ledger effective time.
// Required
google.protobuf.Timestamp effective_at = 4;
// field ID 5 deprecated
// The absolute offset. The format of this field is described in ledger_offset.proto.
// Required
string offset = 6;
// Changes to the ledger that were caused by this transaction. Nodes of the transaction tree.
// Required
map<string, TreeEvent> events_by_id = 7;
// Roots of the transaction tree.
// Required
repeated string root_event_ids = 8;
// Zipkin trace context.
// This field is a future extension point and is currently not supported.
// Optional
TraceContext trace_context = 1000;
}
message TreeEvent {
oneof kind {
CreatedEvent created = 1;
ExercisedEvent exercised = 2;
}
}
// Filtered view of an on-ledger transaction.
message Transaction {
// Assigned by the server. Useful for correlating logs.
// Required
string transaction_id = 1;
// The ID of the command which resulted in this transaction. Missing for everyone except the submitting party.
// Optional
string command_id = 2;
// The workflow id used in command submission.
// Optional
string workflow_id = 3;
// Ledger effective time.
// Required
google.protobuf.Timestamp effective_at = 4;
// The collection of events.
// Only contains CreatedEvent or ArchivedEvent.
// Required
repeated Event events = 5;
// The absolute offset. The format of this field is described in ledger_offset.proto.
// Required
string offset = 6;
// Zipkin trace context.
// This field is a future extension point and is currently not supported.
// Optional
TraceContext trace_context = 1000;
}