Versions in this module Expand all Collapse all v0 v0.7.0 Apr 14, 2025 Changes in this version + const SubscriptionService_AllocateCredits_FullMethodName + const SubscriptionService_BillAccount_FullMethodName + const SubscriptionService_GetAccountCredits_FullMethodName + const WorkflowService_BatchGetCreditsForAccounts_FullMethodName + const WorkflowService_ConsumeCredits_FullMethodName + const WorkflowService_ConsumeReservation_FullMethodName + const WorkflowService_GetAccountCredits_FullMethodName + const WorkflowService_ReleaseReservation_FullMethodName + const WorkflowService_ReserveCredits_FullMethodName + const WorkflowService_WorkflowReceipt_FullMethodName + var File_billing_pb_billing_service_proto protoreflect.FileDescriptor + var SubscriptionService_ServiceDesc = grpc.ServiceDesc + var WorkflowService_ServiceDesc = grpc.ServiceDesc + func RegisterSubscriptionServiceServer(s grpc.ServiceRegistrar, srv SubscriptionServiceServer) + func RegisterWorkflowServiceServer(s grpc.ServiceRegistrar, srv WorkflowServiceServer) + type AccountCredits struct + CreatedAt *timestamppb.Timestamp + CreditType string + Credits float32 + CreditsReserved float32 + UpdatedAt *timestamppb.Timestamp + func (*AccountCredits) Descriptor() ([]byte, []int) + func (*AccountCredits) ProtoMessage() + func (x *AccountCredits) GetCreatedAt() *timestamppb.Timestamp + func (x *AccountCredits) GetCreditType() string + func (x *AccountCredits) GetCredits() float32 + func (x *AccountCredits) GetCreditsReserved() float32 + func (x *AccountCredits) GetUpdatedAt() *timestamppb.Timestamp + func (x *AccountCredits) ProtoReflect() protoreflect.Message + func (x *AccountCredits) Reset() + func (x *AccountCredits) String() string + type AccountCreditsInput struct + CreditType string + Credits float32 + func (*AccountCreditsInput) Descriptor() ([]byte, []int) + func (*AccountCreditsInput) ProtoMessage() + func (x *AccountCreditsInput) GetCreditType() string + func (x *AccountCreditsInput) GetCredits() float32 + func (x *AccountCreditsInput) ProtoReflect() protoreflect.Message + func (x *AccountCreditsInput) Reset() + func (x *AccountCreditsInput) String() string + type AccountWithCredits struct + AccountId string + Credits []*AccountCredits + func (*AccountWithCredits) Descriptor() ([]byte, []int) + func (*AccountWithCredits) ProtoMessage() + func (x *AccountWithCredits) GetAccountId() string + func (x *AccountWithCredits) GetCredits() []*AccountCredits + func (x *AccountWithCredits) ProtoReflect() protoreflect.Message + func (x *AccountWithCredits) Reset() + func (x *AccountWithCredits) String() string + type AllocateCreditsRequest struct + AccountId string + Credits []*AccountCreditsInput + func (*AllocateCreditsRequest) Descriptor() ([]byte, []int) + func (*AllocateCreditsRequest) ProtoMessage() + func (x *AllocateCreditsRequest) GetAccountId() string + func (x *AllocateCreditsRequest) GetCredits() []*AccountCreditsInput + func (x *AllocateCreditsRequest) ProtoReflect() protoreflect.Message + func (x *AllocateCreditsRequest) Reset() + func (x *AllocateCreditsRequest) String() string + type AllocateCreditsResponse struct + Success bool + func (*AllocateCreditsResponse) Descriptor() ([]byte, []int) + func (*AllocateCreditsResponse) ProtoMessage() + func (x *AllocateCreditsResponse) GetSuccess() bool + func (x *AllocateCreditsResponse) ProtoReflect() protoreflect.Message + func (x *AllocateCreditsResponse) Reset() + func (x *AllocateCreditsResponse) String() string + type BatchGetCreditsForAccountsRequest struct + AccountIds []string + func (*BatchGetCreditsForAccountsRequest) Descriptor() ([]byte, []int) + func (*BatchGetCreditsForAccountsRequest) ProtoMessage() + func (x *BatchGetCreditsForAccountsRequest) GetAccountIds() []string + func (x *BatchGetCreditsForAccountsRequest) ProtoReflect() protoreflect.Message + func (x *BatchGetCreditsForAccountsRequest) Reset() + func (x *BatchGetCreditsForAccountsRequest) String() string + type BatchGetCreditsForAccountsResponse struct + Accounts []*AccountWithCredits + func (*BatchGetCreditsForAccountsResponse) Descriptor() ([]byte, []int) + func (*BatchGetCreditsForAccountsResponse) ProtoMessage() + func (x *BatchGetCreditsForAccountsResponse) GetAccounts() []*AccountWithCredits + func (x *BatchGetCreditsForAccountsResponse) ProtoReflect() protoreflect.Message + func (x *BatchGetCreditsForAccountsResponse) Reset() + func (x *BatchGetCreditsForAccountsResponse) String() string + type BillAccountRequest struct + AccountId string + Amt float32 + Currency string + IdempotencyKey string + func (*BillAccountRequest) Descriptor() ([]byte, []int) + func (*BillAccountRequest) ProtoMessage() + func (x *BillAccountRequest) GetAccountId() string + func (x *BillAccountRequest) GetAmt() float32 + func (x *BillAccountRequest) GetCurrency() string + func (x *BillAccountRequest) GetIdempotencyKey() string + func (x *BillAccountRequest) ProtoReflect() protoreflect.Message + func (x *BillAccountRequest) Reset() + func (x *BillAccountRequest) String() string + type BillAccountResponse struct + BillId string + func (*BillAccountResponse) Descriptor() ([]byte, []int) + func (*BillAccountResponse) ProtoMessage() + func (x *BillAccountResponse) GetBillId() string + func (x *BillAccountResponse) ProtoReflect() protoreflect.Message + func (x *BillAccountResponse) Reset() + func (x *BillAccountResponse) String() string + type ConsumeCreditsRequest struct + AccountId string + Credits []*AccountCreditsInput + WorkflowId string + func (*ConsumeCreditsRequest) Descriptor() ([]byte, []int) + func (*ConsumeCreditsRequest) ProtoMessage() + func (x *ConsumeCreditsRequest) GetAccountId() string + func (x *ConsumeCreditsRequest) GetCredits() []*AccountCreditsInput + func (x *ConsumeCreditsRequest) GetWorkflowId() string + func (x *ConsumeCreditsRequest) ProtoReflect() protoreflect.Message + func (x *ConsumeCreditsRequest) Reset() + func (x *ConsumeCreditsRequest) String() string + type ConsumeCreditsResponse struct + Success bool + func (*ConsumeCreditsResponse) Descriptor() ([]byte, []int) + func (*ConsumeCreditsResponse) ProtoMessage() + func (x *ConsumeCreditsResponse) GetSuccess() bool + func (x *ConsumeCreditsResponse) ProtoReflect() protoreflect.Message + func (x *ConsumeCreditsResponse) Reset() + func (x *ConsumeCreditsResponse) String() string + type ConsumeReservationRequest struct + AccountId string + WorkflowExecutionId string + WorkflowId string + func (*ConsumeReservationRequest) Descriptor() ([]byte, []int) + func (*ConsumeReservationRequest) ProtoMessage() + func (x *ConsumeReservationRequest) GetAccountId() string + func (x *ConsumeReservationRequest) GetWorkflowExecutionId() string + func (x *ConsumeReservationRequest) GetWorkflowId() string + func (x *ConsumeReservationRequest) ProtoReflect() protoreflect.Message + func (x *ConsumeReservationRequest) Reset() + func (x *ConsumeReservationRequest) String() string + type ConsumeReservationResponse struct + Success bool + func (*ConsumeReservationResponse) Descriptor() ([]byte, []int) + func (*ConsumeReservationResponse) ProtoMessage() + func (x *ConsumeReservationResponse) GetSuccess() bool + func (x *ConsumeReservationResponse) ProtoReflect() protoreflect.Message + func (x *ConsumeReservationResponse) Reset() + func (x *ConsumeReservationResponse) String() string + type EmptyRequest struct + func (*EmptyRequest) Descriptor() ([]byte, []int) + func (*EmptyRequest) ProtoMessage() + func (x *EmptyRequest) ProtoReflect() protoreflect.Message + func (x *EmptyRequest) Reset() + func (x *EmptyRequest) String() string + type EmptyResponse struct + Message string + func (*EmptyResponse) Descriptor() ([]byte, []int) + func (*EmptyResponse) ProtoMessage() + func (x *EmptyResponse) GetMessage() string + func (x *EmptyResponse) ProtoReflect() protoreflect.Message + func (x *EmptyResponse) Reset() + func (x *EmptyResponse) String() string + type GetAccountCreditsRequest struct + AccountId string + func (*GetAccountCreditsRequest) Descriptor() ([]byte, []int) + func (*GetAccountCreditsRequest) ProtoMessage() + func (x *GetAccountCreditsRequest) GetAccountId() string + func (x *GetAccountCreditsRequest) ProtoReflect() protoreflect.Message + func (x *GetAccountCreditsRequest) Reset() + func (x *GetAccountCreditsRequest) String() string + type GetAccountCreditsResponse struct + AccountId string + Credits []*AccountCredits + func (*GetAccountCreditsResponse) Descriptor() ([]byte, []int) + func (*GetAccountCreditsResponse) ProtoMessage() + func (x *GetAccountCreditsResponse) GetAccountId() string + func (x *GetAccountCreditsResponse) GetCredits() []*AccountCredits + func (x *GetAccountCreditsResponse) ProtoReflect() protoreflect.Message + func (x *GetAccountCreditsResponse) Reset() + func (x *GetAccountCreditsResponse) String() string + type ReleaseReservationRequest struct + AccountId string + WorkflowExecutionId string + WorkflowId string + func (*ReleaseReservationRequest) Descriptor() ([]byte, []int) + func (*ReleaseReservationRequest) ProtoMessage() + func (x *ReleaseReservationRequest) GetAccountId() string + func (x *ReleaseReservationRequest) GetWorkflowExecutionId() string + func (x *ReleaseReservationRequest) GetWorkflowId() string + func (x *ReleaseReservationRequest) ProtoReflect() protoreflect.Message + func (x *ReleaseReservationRequest) Reset() + func (x *ReleaseReservationRequest) String() string + type ReleaseReservationResponse struct + Success bool + func (*ReleaseReservationResponse) Descriptor() ([]byte, []int) + func (*ReleaseReservationResponse) ProtoMessage() + func (x *ReleaseReservationResponse) GetSuccess() bool + func (x *ReleaseReservationResponse) ProtoReflect() protoreflect.Message + func (x *ReleaseReservationResponse) Reset() + func (x *ReleaseReservationResponse) String() string + type ReserveCreditsRequest struct + AccountId string + Credits []*AccountCreditsInput + WorkflowExecutionId string + WorkflowId string + func (*ReserveCreditsRequest) Descriptor() ([]byte, []int) + func (*ReserveCreditsRequest) ProtoMessage() + func (x *ReserveCreditsRequest) GetAccountId() string + func (x *ReserveCreditsRequest) GetCredits() []*AccountCreditsInput + func (x *ReserveCreditsRequest) GetWorkflowExecutionId() string + func (x *ReserveCreditsRequest) GetWorkflowId() string + func (x *ReserveCreditsRequest) ProtoReflect() protoreflect.Message + func (x *ReserveCreditsRequest) Reset() + func (x *ReserveCreditsRequest) String() string + type ReserveCreditsResponse struct + Success bool + func (*ReserveCreditsResponse) Descriptor() ([]byte, []int) + func (*ReserveCreditsResponse) ProtoMessage() + func (x *ReserveCreditsResponse) GetSuccess() bool + func (x *ReserveCreditsResponse) ProtoReflect() protoreflect.Message + func (x *ReserveCreditsResponse) Reset() + func (x *ReserveCreditsResponse) String() string + type SubmitWorkflowReceiptRequest struct + AccountId string + Metering *pb.MeteringReport + WorkflowExecutionId string + WorkflowId string + func (*SubmitWorkflowReceiptRequest) Descriptor() ([]byte, []int) + func (*SubmitWorkflowReceiptRequest) ProtoMessage() + func (x *SubmitWorkflowReceiptRequest) GetAccountId() string + func (x *SubmitWorkflowReceiptRequest) GetMetering() *pb.MeteringReport + func (x *SubmitWorkflowReceiptRequest) GetWorkflowExecutionId() string + func (x *SubmitWorkflowReceiptRequest) GetWorkflowId() string + func (x *SubmitWorkflowReceiptRequest) ProtoReflect() protoreflect.Message + func (x *SubmitWorkflowReceiptRequest) Reset() + func (x *SubmitWorkflowReceiptRequest) String() string + type SubmitWorkflowReceiptResponse struct + Success bool + func (*SubmitWorkflowReceiptResponse) Descriptor() ([]byte, []int) + func (*SubmitWorkflowReceiptResponse) ProtoMessage() + func (x *SubmitWorkflowReceiptResponse) GetSuccess() bool + func (x *SubmitWorkflowReceiptResponse) ProtoReflect() protoreflect.Message + func (x *SubmitWorkflowReceiptResponse) Reset() + func (x *SubmitWorkflowReceiptResponse) String() string + type SubscriptionServiceClient interface + AllocateCredits func(ctx context.Context, in *AllocateCreditsRequest, opts ...grpc.CallOption) (*AllocateCreditsResponse, error) + BillAccount func(ctx context.Context, in *BillAccountRequest, opts ...grpc.CallOption) (*BillAccountResponse, error) + GetAccountCredits func(ctx context.Context, in *GetAccountCreditsRequest, opts ...grpc.CallOption) (*GetAccountCreditsResponse, error) + func NewSubscriptionServiceClient(cc grpc.ClientConnInterface) SubscriptionServiceClient + type SubscriptionServiceServer interface + AllocateCredits func(context.Context, *AllocateCreditsRequest) (*AllocateCreditsResponse, error) + BillAccount func(context.Context, *BillAccountRequest) (*BillAccountResponse, error) + GetAccountCredits func(context.Context, *GetAccountCreditsRequest) (*GetAccountCreditsResponse, error) + type UnimplementedSubscriptionServiceServer struct + func (UnimplementedSubscriptionServiceServer) AllocateCredits(context.Context, *AllocateCreditsRequest) (*AllocateCreditsResponse, error) + func (UnimplementedSubscriptionServiceServer) BillAccount(context.Context, *BillAccountRequest) (*BillAccountResponse, error) + func (UnimplementedSubscriptionServiceServer) GetAccountCredits(context.Context, *GetAccountCreditsRequest) (*GetAccountCreditsResponse, error) + type UnimplementedWorkflowServiceServer struct + func (UnimplementedWorkflowServiceServer) BatchGetCreditsForAccounts(context.Context, *BatchGetCreditsForAccountsRequest) (*BatchGetCreditsForAccountsResponse, error) + func (UnimplementedWorkflowServiceServer) ConsumeCredits(context.Context, *ConsumeCreditsRequest) (*ConsumeCreditsResponse, error) + func (UnimplementedWorkflowServiceServer) ConsumeReservation(context.Context, *ConsumeReservationRequest) (*ConsumeReservationResponse, error) + func (UnimplementedWorkflowServiceServer) GetAccountCredits(context.Context, *GetAccountCreditsRequest) (*GetAccountCreditsResponse, error) + func (UnimplementedWorkflowServiceServer) ReleaseReservation(context.Context, *ReleaseReservationRequest) (*ReleaseReservationResponse, error) + func (UnimplementedWorkflowServiceServer) ReserveCredits(context.Context, *ReserveCreditsRequest) (*ReserveCreditsResponse, error) + func (UnimplementedWorkflowServiceServer) WorkflowReceipt(context.Context, *SubmitWorkflowReceiptRequest) (*SubmitWorkflowReceiptResponse, error) + type UnsafeSubscriptionServiceServer interface + type UnsafeWorkflowServiceServer interface + type WorkflowServiceClient interface + BatchGetCreditsForAccounts func(ctx context.Context, in *BatchGetCreditsForAccountsRequest, ...) (*BatchGetCreditsForAccountsResponse, error) + ConsumeCredits func(ctx context.Context, in *ConsumeCreditsRequest, opts ...grpc.CallOption) (*ConsumeCreditsResponse, error) + ConsumeReservation func(ctx context.Context, in *ConsumeReservationRequest, opts ...grpc.CallOption) (*ConsumeReservationResponse, error) + GetAccountCredits func(ctx context.Context, in *GetAccountCreditsRequest, opts ...grpc.CallOption) (*GetAccountCreditsResponse, error) + ReleaseReservation func(ctx context.Context, in *ReleaseReservationRequest, opts ...grpc.CallOption) (*ReleaseReservationResponse, error) + ReserveCredits func(ctx context.Context, in *ReserveCreditsRequest, opts ...grpc.CallOption) (*ReserveCreditsResponse, error) + WorkflowReceipt func(ctx context.Context, in *SubmitWorkflowReceiptRequest, opts ...grpc.CallOption) (*SubmitWorkflowReceiptResponse, error) + func NewWorkflowServiceClient(cc grpc.ClientConnInterface) WorkflowServiceClient + type WorkflowServiceServer interface + BatchGetCreditsForAccounts func(context.Context, *BatchGetCreditsForAccountsRequest) (*BatchGetCreditsForAccountsResponse, error) + ConsumeCredits func(context.Context, *ConsumeCreditsRequest) (*ConsumeCreditsResponse, error) + ConsumeReservation func(context.Context, *ConsumeReservationRequest) (*ConsumeReservationResponse, error) + GetAccountCredits func(context.Context, *GetAccountCreditsRequest) (*GetAccountCreditsResponse, error) + ReleaseReservation func(context.Context, *ReleaseReservationRequest) (*ReleaseReservationResponse, error) + ReserveCredits func(context.Context, *ReserveCreditsRequest) (*ReserveCreditsResponse, error) + WorkflowReceipt func(context.Context, *SubmitWorkflowReceiptRequest) (*SubmitWorkflowReceiptResponse, error)