Skip to content

Commit 8dc553b

Browse files
refactor: deprecate billing_id in entitlement and usage RPCs
Mark billing_id field as deprecated in the following RPCs: - CheckFeatureEntitlement - CreateBillingUsage - RevertBillingUsage The billing_id will now be automatically inferred from org_id on the backend. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 80fc5ba commit 8dc553b

File tree

2 files changed

+24
-16
lines changed

2 files changed

+24
-16
lines changed

raystack/frontier/v1beta1/admin.proto

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1098,12 +1098,14 @@ message RevertBillingUsageRequest {
10981098
string org_id = 1;
10991099
string project_id = 2;
11001100

1101-
// either provide billing_id of the org or API can infer the default
1102-
// billing ID from either org_id or project_id, not both
1103-
string billing_id = 3 [(validate.rules).string = {
1104-
ignore_empty: true,
1105-
uuid: true
1106-
}];
1101+
// DEPRECATED: billing_id will be inferred from org_id
1102+
string billing_id = 3 [
1103+
deprecated = true,
1104+
(validate.rules).string = {
1105+
ignore_empty: true,
1106+
uuid: true
1107+
}
1108+
];
11071109

11081110
// usage id to revert, a usage can only be allowed to revert once
11091111
string usage_id = 4 [(validate.rules).string = {uuid: true}];

raystack/frontier/v1beta1/frontier.proto

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2030,11 +2030,14 @@ message HasTrialedResponse {
20302030

20312031
message CreateBillingUsageRequest {
20322032
string org_id = 1;
2033-
// ID of the billing account to update the subscription for
2034-
string billing_id = 2 [(validate.rules).string = {
2035-
ignore_empty: true,
2036-
uuid: true
2037-
}];
2033+
// DEPRECATED: billing_id will be inferred from org_id
2034+
string billing_id = 2 [
2035+
deprecated = true,
2036+
(validate.rules).string = {
2037+
ignore_empty: true,
2038+
uuid: true
2039+
}
2040+
];
20382041

20392042
// either provide billing_id of the org or API can infer the default
20402043
// billing ID from either org_id or project_id, not both
@@ -2253,11 +2256,14 @@ message ListPlansResponse {
22532256

22542257
message CheckFeatureEntitlementRequest {
22552258
string org_id = 1;
2256-
// ID of the billing account to update the subscription for
2257-
string billing_id = 2 [(validate.rules).string = {
2258-
ignore_empty: true,
2259-
uuid: true
2260-
}];
2259+
// DEPRECATED: billing_id will be inferred from org_id
2260+
string billing_id = 2 [
2261+
deprecated = true,
2262+
(validate.rules).string = {
2263+
ignore_empty: true,
2264+
uuid: true
2265+
}
2266+
];
22612267

22622268
// either provide billing_id of the org or API can infer the default
22632269
// billing ID from either org_id or project_id, not both

0 commit comments

Comments
 (0)