frostfs-api/accounting/service.proto
Stanislav Bogatyrev 42e35fefff [#45] Fix linter errors
- Changed package names adding version
- Added documentation descriptions (sometimes useless) for all fields
- Changed enum format
- Made SessionToken and BearerToken field names more clear

Signed-off-by: Stanislav Bogatyrev <stanislav@nspcc.ru>
2020-08-13 22:57:00 +03:00

75 lines
2.4 KiB
Protocol Buffer

syntax = "proto3";
package neo.fs.v2.accounting;
option go_package = "github.com/nspcc-dev/neofs-api-go/v2/accounting;accounting";
option csharp_namespace = "NeoFS.API.v2.Accounting";
import "refs/types.proto";
import "service/meta.proto";
import "service/verify.proto";
// The service provides methods for obtaining information
// about the account balance in NeoFS system.
service AccountingService {
// Returns the amount of funds for the requested NeoFS account.
rpc Balance (BalanceRequest) returns (BalanceResponse);
}
// Message defines the request body of Balance method.
//
// To indicate the account for which the balance is requested, it's identifier
// is used.
//
// To gain access to the requested information, the request body must be formed
// according to the requirements from the system specification.
message BalanceRequest {
//Request body
message Body {
// Carries user identifier in NeoFS system for which the balance
// is requested.
neo.fs.v2.refs.OwnerID owner_id = 1;
}
// Body of the balance request message.
Body body = 1;
// Carries request meta information. Header data is used only to regulate
// message transport and does not affect request execution.
neo.fs.v2.service.RequestMetaHeader meta_header = 2;
// Carries request verification information. This header is used to
// authenticate the nodes of the message route and check the correctness
// of transmission.
neo.fs.v2.service.RequestVerificationHeader verify_header = 3;
}
// Decimal represents the decimal numbers.
message Decimal {
// value carries number value.
int64 value = 1;
// precision carries value precision.
uint32 precision = 2;
}
// Message defines the response body of Balance method.
//
// The amount of funds is calculated in decimal numbers.
message BalanceResponse {
//Request body
message Body {
// Carries the amount of funds on the account.
Decimal balance = 1;
}
// Body of the balance response message.
Body body = 1;
// Carries response meta information. Header data is used only to regulate
// message transport and does not affect request execution.
neo.fs.v2.service.ResponseMetaHeader meta_header = 2;
// Carries response verification information. This header is used to
// authenticate the nodes of the message route and check the correctness
// of transmission.
neo.fs.v2.service.ResponseVerificationHeader verify_header = 3;
}