Skip to content

Commit 463459d

Browse files
authored
feat: add frontier endpoint to access billing account details (#409)
1 parent 9ed9335 commit 463459d

2 files changed

Lines changed: 17 additions & 0 deletions

File tree

raystack/frontier/v1beta1/frontier.proto

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1931,6 +1931,8 @@ message GetBillingAccountRequest {
19311931

19321932
bool with_payment_methods = 3;
19331933

1934+
bool with_billing_details = 4;
1935+
19341936
repeated string expand = 101;
19351937
}
19361938

@@ -1940,6 +1942,9 @@ message GetBillingAccountResponse {
19401942

19411943
// List of payment methods
19421944
repeated PaymentMethod payment_methods = 2;
1945+
1946+
// Billing details
1947+
BillingAccountDetails billing_details = 3;
19431948
}
19441949

19451950
message UpdateBillingAccountRequest {

raystack/frontier/v1beta1/models.proto

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -605,6 +605,18 @@ message BillingAccount {
605605
Organization organization = 101 [(google.api.field_behavior) = OUTPUT_ONLY];
606606
}
607607

608+
message BillingAccountDetails {
609+
// credit_min is the minimum credit limit for the billing account
610+
// default is 0, negative numbers work as overdraft, positive
611+
// numbers work as minimum purchase limit
612+
int64 credit_min = 1;
613+
614+
// due_in_days is the number of days after the invoice finalization
615+
// that it will be considered overdue, if set to 0, the customer will
616+
// be charged immediately
617+
int64 due_in_days = 2;
618+
}
619+
608620
message Subscription {
609621
reserved 9;
610622

0 commit comments

Comments
 (0)