neq quotation definition + priced_at field
This commit is contained in:
59
api/proto/payments/quotation/v2/interface.proto
Normal file
59
api/proto/payments/quotation/v2/interface.proto
Normal file
@@ -0,0 +1,59 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package payments.quotation.v2;
|
||||
|
||||
option go_package = "github.com/tech/sendico/pkg/proto/payments/quotation/v2;quotationv2";
|
||||
|
||||
import "google/protobuf/timestamp.proto";
|
||||
import "api/proto/common/storable/v1/storable.proto";
|
||||
import "api/proto/common/money/v1/money.proto";
|
||||
import "api/proto/common/fx/v1/fx.proto";
|
||||
import "api/proto/billing/fees/v1/fees.proto";
|
||||
import "api/proto/oracle/v1/oracle.proto";
|
||||
|
||||
enum QuoteKind {
|
||||
QUOTE_KIND_UNSPECIFIED = 0;
|
||||
|
||||
QUOTE_KIND_EXECUTABLE = 1; // can be executed now (subject to execution-time checks)
|
||||
QUOTE_KIND_INDICATIVE = 2; // informational only
|
||||
}
|
||||
|
||||
enum QuoteState {
|
||||
QUOTE_STATE_UNSPECIFIED = 0;
|
||||
|
||||
QUOTE_STATE_ACTIVE = 1;
|
||||
QUOTE_STATE_EXPIRED = 2;
|
||||
}
|
||||
|
||||
enum QuoteBlockReason {
|
||||
QUOTE_BLOCK_REASON_UNSPECIFIED = 0;
|
||||
|
||||
QUOTE_BLOCK_REASON_ROUTE_UNAVAILABLE = 1;
|
||||
QUOTE_BLOCK_REASON_LIMIT_BLOCKED = 2;
|
||||
QUOTE_BLOCK_REASON_RISK_BLOCKED = 3;
|
||||
QUOTE_BLOCK_REASON_INSUFFICIENT_LIQUIDITY = 4;
|
||||
QUOTE_BLOCK_REASON_PRICE_STALE = 5;
|
||||
QUOTE_BLOCK_REASON_AMOUNT_TOO_SMALL = 6;
|
||||
QUOTE_BLOCK_REASON_AMOUNT_TOO_LARGE = 7;
|
||||
}
|
||||
|
||||
|
||||
message PaymentQuote {
|
||||
common.storable.v1.Storable storable = 1;
|
||||
QuoteKind kind = 2;
|
||||
QuoteState state = 3;
|
||||
optional QuoteBlockReason block_reason = 4;
|
||||
|
||||
common.money.v1.Money debit_amount = 5;
|
||||
common.money.v1.Money credit_amount = 6;
|
||||
|
||||
repeated fees.v1.DerivedPostingLine fee_lines = 7;
|
||||
repeated fees.v1.AppliedRule fee_rules = 8;
|
||||
|
||||
oracle.v1.Quote fx_quote = 9;
|
||||
|
||||
string quote_ref = 10;
|
||||
|
||||
google.protobuf.Timestamp expires_at = 11;
|
||||
google.protobuf.Timestamp priced_at = 12;
|
||||
}
|
||||
37
api/proto/payments/quotation/v2/quotation.proto
Normal file
37
api/proto/payments/quotation/v2/quotation.proto
Normal file
@@ -0,0 +1,37 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package payments.quotation.v2;
|
||||
|
||||
option go_package = "github.com/tech/sendico/pkg/proto/payments/quotation/v2;quotationv2";
|
||||
|
||||
import "api/proto/payments/shared/v1/shared.proto";
|
||||
import "api/proto/payments/transfer/v1/transfer.proto";
|
||||
import "api/proto/payments/quotation/v2/interface.proto";
|
||||
|
||||
|
||||
message QuotePaymentRequest {
|
||||
payments.shared.v1.RequestMeta meta = 1;
|
||||
string idempotency_key = 2;
|
||||
payments.transfer.v1.TransferIntent intent = 3;
|
||||
bool preview_only = 4;
|
||||
string initiator_ref = 5;
|
||||
}
|
||||
|
||||
message QuotePaymentResponse {
|
||||
payments.quotation.v2.PaymentQuote quote = 1;
|
||||
string idempotency_key = 2;
|
||||
}
|
||||
|
||||
message QuotePaymentsRequest {
|
||||
payments.shared.v1.RequestMeta meta = 1;
|
||||
string idempotency_key = 2;
|
||||
repeated payments.transfer.v1.TransferIntent intents = 3;
|
||||
bool preview_only = 4;
|
||||
string initiator_ref = 5;
|
||||
}
|
||||
|
||||
message QuotePaymentsResponse {
|
||||
string quote_ref = 1;
|
||||
repeated payments.quotation.v2.PaymentQuote quotes = 3;
|
||||
string idempotency_key = 4;
|
||||
}
|
||||
Reference in New Issue
Block a user