diff --git a/apps/billing-web/e2e/fixtures/scenario.ts b/apps/billing-web/e2e/fixtures/scenario.ts index 5e3093ae170..2701c28909c 100644 --- a/apps/billing-web/e2e/fixtures/scenario.ts +++ b/apps/billing-web/e2e/fixtures/scenario.ts @@ -43,6 +43,8 @@ export function capabilitiesWith( can_edit_workspace: false, can_invite_members: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_members: false, can_manage_subscription: true, can_open_plans: true, diff --git a/apps/billing-web/src/checkout/endingScreen.ts b/apps/billing-web/src/checkout/endingScreen.ts index d41def1e58b..1c541f77c07 100644 --- a/apps/billing-web/src/checkout/endingScreen.ts +++ b/apps/billing-web/src/checkout/endingScreen.ts @@ -56,6 +56,7 @@ const REFUSAL_COPY: Readonly> = { membership_managed_by_directory: 'unknown', personal_workspace_creator: 'unknown', workspace_creator: 'unknown', + workspace_owner: 'unknown', only_owner: 'unknown', billing_state_unknown: 'unknown', topup_purchases_paused: 'unknown', diff --git a/apps/billing-web/src/test/fakeBillingClient.ts b/apps/billing-web/src/test/fakeBillingClient.ts index d38b7c97b4a..9efef9e60f3 100644 --- a/apps/billing-web/src/test/fakeBillingClient.ts +++ b/apps/billing-web/src/test/fakeBillingClient.ts @@ -236,6 +236,8 @@ export function createFakeBillingClient( can_edit_workspace: false, can_invite_members: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_members: false, can_manage_subscription: false, can_open_plans: false, diff --git a/browser_tests/fixtures/data/billingCapabilities.ts b/browser_tests/fixtures/data/billingCapabilities.ts index bf4717ffb0a..286ed7c431c 100644 --- a/browser_tests/fixtures/data/billingCapabilities.ts +++ b/browser_tests/fixtures/data/billingCapabilities.ts @@ -33,6 +33,8 @@ export function createBillingCapabilities( can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: true, can_open_plans: true, can_run_workflows: false, @@ -77,6 +79,7 @@ export function createWorkspaceBillingCapabilities( can_reactivate: isOwner, can_subscribe_self_serve: isOwner, can_top_up: isOwner, + can_view_auto_top_up_member_notice: !isOwner, ...overrides }) } diff --git a/packages/account-core/src/core/billing/capabilities.test.ts b/packages/account-core/src/core/billing/capabilities.test.ts index 4f9a912062c..dd58f29369d 100644 --- a/packages/account-core/src/core/billing/capabilities.test.ts +++ b/packages/account-core/src/core/billing/capabilities.test.ts @@ -54,6 +54,8 @@ const CAPABILITIES = { can_revert_scheduled_change: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/packages/account-core/src/core/billing/capabilitiesCrossUser.test.ts b/packages/account-core/src/core/billing/capabilitiesCrossUser.test.ts index 86274f45331..3cfec94f5ef 100644 --- a/packages/account-core/src/core/billing/capabilitiesCrossUser.test.ts +++ b/packages/account-core/src/core/billing/capabilitiesCrossUser.test.ts @@ -59,6 +59,8 @@ const NO_RIGHTS: BillingCapabilities = { can_invite_members: false, can_leave_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_billing: false, can_manage_members: false, can_manage_partner_node_access: false, diff --git a/packages/account-core/src/core/billing/capabilityDenials.ts b/packages/account-core/src/core/billing/capabilityDenials.ts index 541770d0472..46d7d729e29 100644 --- a/packages/account-core/src/core/billing/capabilityDenials.ts +++ b/packages/account-core/src/core/billing/capabilityDenials.ts @@ -44,6 +44,7 @@ export type CapabilityDenialReason = | 'membership_managed_by_directory' | 'personal_workspace_creator' | 'workspace_creator' + | 'workspace_owner' | 'only_owner' | 'billing_state_unknown' | 'free_tier_exhausted' @@ -95,6 +96,7 @@ const KNOWN_REASONS: Readonly< membership_managed_by_directory: true, personal_workspace_creator: true, workspace_creator: true, + workspace_owner: true, only_owner: true, billing_state_unknown: true, free_tier_exhausted: true, diff --git a/packages/account-core/src/core/billing/contracts/billingCapabilities.contract.test.ts b/packages/account-core/src/core/billing/contracts/billingCapabilities.contract.test.ts index 4d5f5dc1f99..67558d007b6 100644 --- a/packages/account-core/src/core/billing/contracts/billingCapabilities.contract.test.ts +++ b/packages/account-core/src/core/billing/contracts/billingCapabilities.contract.test.ts @@ -25,6 +25,8 @@ function capabilities(): Capabilities { can_edit_workspace: true, can_invite_members: true, can_manage_auto_top_up: true, + can_view_auto_top_up: true, + can_view_auto_top_up_member_notice: false, can_manage_members: true, can_manage_subscription: true, can_open_plans: true, @@ -64,9 +66,11 @@ function capabilitiesBody( expectTypeOf().toEqualTypeOf< | 'auto_top_up_enabled' | 'auto_top_up_setup' + | 'billing_notice_audience' | 'capabilities' | 'denied_reason_params' | 'denied_reasons' + | 'ending_notice_starts_at' | 'expires_at' | 'has_parked_billing_operation' | 'payment_recovery_available' @@ -97,6 +101,8 @@ expectTypeOf().toEqualTypeOf<{ can_subscribe_self_serve: boolean can_top_up: boolean can_upgrade: boolean + can_view_auto_top_up: boolean + can_view_auto_top_up_member_notice: boolean can_view_own_usage?: boolean | undefined can_view_pending_invites: boolean can_view_team_usage: boolean diff --git a/packages/account-core/src/core/billing/scopedReader.test.ts b/packages/account-core/src/core/billing/scopedReader.test.ts index 3a5aac6c776..5984ca3219b 100644 --- a/packages/account-core/src/core/billing/scopedReader.test.ts +++ b/packages/account-core/src/core/billing/scopedReader.test.ts @@ -179,6 +179,8 @@ function capabilitiesBody(overrides: Record = {}) { can_revert_scheduled_change: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/packages/account-core/src/core/billing/topup.test.ts b/packages/account-core/src/core/billing/topup.test.ts index 7fa75ceee38..f219490585d 100644 --- a/packages/account-core/src/core/billing/topup.test.ts +++ b/packages/account-core/src/core/billing/topup.test.ts @@ -105,6 +105,8 @@ const CAPABILITIES = { can_revert_scheduled_change: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/packages/account-ui/src/billing/__fixtures__/billingHarness.ts b/packages/account-ui/src/billing/__fixtures__/billingHarness.ts index 653ca13aa03..ef756298e9f 100644 --- a/packages/account-ui/src/billing/__fixtures__/billingHarness.ts +++ b/packages/account-ui/src/billing/__fixtures__/billingHarness.ts @@ -126,6 +126,8 @@ export const CAPABILITIES = { can_revert_scheduled_change: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/packages/ingest-types/src/types.gen.ts b/packages/ingest-types/src/types.gen.ts index b01430aedc0..a06d88a5849 100644 --- a/packages/ingest-types/src/types.gen.ts +++ b/packages/ingest-types/src/types.gen.ts @@ -1534,8 +1534,9 @@ export type AutoReloadSettingsRequest = { * can_manage_auto_top_up. Frozen prevents enabling/editing; unavailable * means setup is not available. Owner read/disable authority remains separate. * These states do not determine surface visibility. Unified billing settings - * hide the auto top-up card when can_top_up is false, including paused or - * payment-failed billing. + * show the auto top-up card only when capabilities.can_view_auto_top_up is + * true; it is false when can_top_up is, including paused or payment-failed + * billing. * Ready does not authorize a charge or guarantee an off-session payment method. * This fact ignores saved consent and monthly budget. An absent fact is unknown. * @@ -1705,8 +1706,9 @@ export type BillingBalanceResponse = { * * When the deployment has billing disabled, this endpoint answers without * consulting billing-api: can_top_up is true; can_manage_members, - * can_invite_members, can_manage_subscription and can_manage_auto_top_up - * follow the owner role. Other billing-action fields are false. These role + * can_invite_members, can_manage_subscription, can_manage_auto_top_up and + * can_view_auto_top_up follow the owner role, and + * can_view_auto_top_up_member_notice is true for a non-owner. Other billing-action fields are false. These role * facts do not promise that billing endpoints are available. * */ @@ -2005,6 +2007,38 @@ export type BillingCapabilities = { * Whether at least one active catalog choice is an actionable upgrade from the current plan for this actor, including a Free-to-paid choice, longer interval or higher Team credit commitment. Uses the same exact target selector as plan actions, including seats, processing operations and scheduled changes. No current or ended plan is false: subscribe or resubscribe is a separate action. Unknown legacy bindings fail closed. False with no reason is unknown; this guidance does not authorize writes. */ can_upgrade: boolean + /** + * - Answers: should the client show the owner auto top-up card? + * - True: can_manage_auto_top_up and can_top_up are both true in this + * response. Render it as received; never recombine those two fields. + * - False: denied_reasons.can_view_auto_top_up names the first refusal, + * the can_manage_auto_top_up reason before the can_top_up reason. + * - When billing-api omits this field, ingest serves + * can_manage_auto_top_up and can_top_up as served here, and takes the + * reason from their denied_reasons in the same order. + * - Not: authorization to enable, edit or charge auto top-up, and not + * setup readiness, which auto_top_up_setup reports. auto_top_up_enabled + * still gates the rollout. + * + */ + can_view_auto_top_up: boolean + /** + * - Answers: should the client show the member auto top-up notice that + * sends a non-owner to a workspace owner? + * - True: the actor is a member but not an owner, and the workspace + * passes every can_top_up condition that does not depend on the + * actor: not past due or paused, a recognized tier and status, and + * purchases not paused by staff. Render it as received; never derive + * it from can_top_up, can_manage_auto_top_up or their reasons. + * - False: denied_reasons.can_view_auto_top_up_member_notice names the + * first refusal. + * - When billing-api omits this field, ingest serves true for a member + * who is not an owner, with no reason. + * - Not: authorization to buy credits or change auto top-up. + * auto_top_up_enabled still gates the rollout. + * + */ + can_view_auto_top_up_member_notice: boolean /** * Whether to offer the actor's own usage attribution view. Optional for rolling deployments; absent means unknown. True for a current workspace member with usage attribution enabled. Clients must use person/source ledger groupings or person/source filters, which the existing route scopes to the actor for members. This is not permission for the default model grouping, whole-workspace analytics, or other unscoped queries. Query authorization and filters are unchanged. Attribution disabled emits usage_attribution_unavailable; missing denial means unknown. */ @@ -2033,9 +2067,38 @@ export type BillingCapabilitiesResponse = { */ auto_top_up_enabled: boolean auto_top_up_setup?: AutoTopUpSetup + /** + * Which set of billing notices speaks to the plan. Rendered as received; + * never derive it from tier names, slugs or the workspace type. + * - none: no subscription, a reserved (scheduled) row, an ENTERPRISE plan, + * or a plan that is neither a Team plan nor a personal paid tier (FREE or + * unrecognised). ENTERPRISE wins over every other rule. + * - team: a Team plan, meaning the subscription has a team credit stop or a + * per-credit or retired seat-based Team plan slug. + * - personal: a STANDARD, CREATOR, PRO or FOUNDERS_EDITION plan that is not + * a Team plan. + * It ignores the plan's status (an ended plan keeps its audience) and the + * user's role. It is not a capability and not authorization. Absent in the + * same cases as recovery_route. + * + */ + billing_notice_audience?: 'none' | 'team' | 'personal' capabilities: BillingCapabilities denied_reason_params?: BillingCapabilityDenialParams denied_reasons?: BillingCapabilityDenials + /** + * When the ending notice of a canceled sales-managed plan starts: its + * cancel_at minus 14 days. The notice applies once the current time is + * at or after this instant; compare it on the client clock rather than + * caching a yes/no answer. Present only while plan_kind is sales_managed, + * the subscription is canceled and its cancel_at is still in the future. + * Absent otherwise (including for self-serve plans, whose ending notice + * shows as soon as they are canceled), when billing is disabled, when + * talking to a billing-api version that predates it, and when the + * upstream value is not a valid timestamp. + * + */ + ending_notice_starts_at?: string /** * Time after which the client must refetch this snapshot. */ @@ -2639,6 +2702,42 @@ export type BillingCapabilityDenials = { | 'billing_operation_in_progress' | 'sales_managed' | 'no_upgrade_available' + /** + * Why can_view_auto_top_up is false. Present only when that capability is false; absent means no recognized explanation, never permission. This does not authorize the action or explain a sibling capability. First reached wins in the order below: the can_manage_auto_top_up refusal, then the can_top_up refusal. + * - not_a_member: The actor is not a workspace member. + * - not_workspace_owner: The actor does not have the workspace owner role. + * - creator_only_provisioning: Only the creator can provision this workspace billing identity. + * - payment_past_due: The failed subscription payment must be resolved before credits can be bought. + * - tier_not_self_serve: The existing subscription tier is unrecognized. + * - subscription_status_unrecognized: The subscription status is unrecognized. + * - topup_purchases_paused: Staff paused customer credit purchases; this lifts without customer action. + * + */ + can_view_auto_top_up?: + | 'not_a_member' + | 'not_workspace_owner' + | 'creator_only_provisioning' + | 'payment_past_due' + | 'tier_not_self_serve' + | 'subscription_status_unrecognized' + | 'topup_purchases_paused' + /** + * Why can_view_auto_top_up_member_notice is false. Present only when that capability is false; absent means no recognized explanation, never permission. This does not authorize the action or explain a sibling capability. First reached wins in the order below: the role refusal, then the workspace refusals in the order can_top_up reaches them. + * - not_a_member: The actor is not a workspace member. + * - workspace_owner: The actor is a workspace owner, who sees the owner auto top-up card (can_view_auto_top_up) instead. + * - payment_past_due: The failed subscription payment must be resolved before credits can be bought, including a paused workspace. + * - tier_not_self_serve: The existing subscription tier is unrecognized. + * - subscription_status_unrecognized: The subscription status is unrecognized. + * - topup_purchases_paused: Staff paused customer credit purchases; this lifts without customer action. + * + */ + can_view_auto_top_up_member_notice?: + | 'not_a_member' + | 'workspace_owner' + | 'payment_past_due' + | 'tier_not_self_serve' + | 'subscription_status_unrecognized' + | 'topup_purchases_paused' /** * Why can_view_own_usage is false, in enum order. Attribution disabled emits usage_attribution_unavailable. Missing means no recognized explanation, including disabled team-workspaces or unreadable membership, never permission. This does not explain can_view_team_usage. */ @@ -13197,7 +13296,7 @@ export type CreateTopupQuoteData = { export type CreateTopupQuoteErrors = { /** * Refused: `INVALID_REQUEST`, `INVALID_AMOUNT`, - * `LEGACY_STRIPE_CHECKOUT_REQUIRED` (use Stripe Checkout), + * `TRANSITION_NOT_ALLOWED` (workspace not on the `stripe` billing rail), * `BILLING_PLAN_ENDED` (retained code for unresolved existing plan/tier/status), or * `BILLING_DISABLED`. * diff --git a/packages/ingest-types/src/zod.gen.ts b/packages/ingest-types/src/zod.gen.ts index c577213b67f..cd0456dd8ba 100644 --- a/packages/ingest-types/src/zod.gen.ts +++ b/packages/ingest-types/src/zod.gen.ts @@ -1064,8 +1064,9 @@ export const zAutoReloadSettingsRequest = z.object({ * can_manage_auto_top_up. Frozen prevents enabling/editing; unavailable * means setup is not available. Owner read/disable authority remains separate. * These states do not determine surface visibility. Unified billing settings - * hide the auto top-up card when can_top_up is false, including paused or - * payment-failed billing. + * show the auto top-up card only when capabilities.can_view_auto_top_up is + * true; it is false when can_top_up is, including paused or payment-failed + * billing. * Ready does not authorize a charge or guarantee an off-session payment method. * This fact ignores saved consent and monthly budget. An absent fact is unknown. * @@ -1126,8 +1127,9 @@ export const zBillingAddress = z.object({ * * When the deployment has billing disabled, this endpoint answers without * consulting billing-api: can_top_up is true; can_manage_members, - * can_invite_members, can_manage_subscription and can_manage_auto_top_up - * follow the owner role. Other billing-action fields are false. These role + * can_invite_members, can_manage_subscription, can_manage_auto_top_up and + * can_view_auto_top_up follow the owner role, and + * can_view_auto_top_up_member_notice is true for a non-owner. Other billing-action fields are false. These role * facts do not promise that billing endpoints are available. * */ @@ -1151,6 +1153,8 @@ export const zBillingCapabilities = z.object({ can_subscribe_self_serve: z.boolean(), can_top_up: z.boolean(), can_upgrade: z.boolean(), + can_view_auto_top_up: z.boolean(), + can_view_auto_top_up_member_notice: z.boolean(), can_view_own_usage: z.boolean().optional(), can_view_pending_invites: z.boolean(), can_view_team_usage: z.boolean() @@ -1377,6 +1381,27 @@ export const zBillingCapabilityDenials = z.object({ 'no_upgrade_available' ]) .optional(), + can_view_auto_top_up: z + .enum([ + 'not_a_member', + 'not_workspace_owner', + 'creator_only_provisioning', + 'payment_past_due', + 'tier_not_self_serve', + 'subscription_status_unrecognized', + 'topup_purchases_paused' + ]) + .optional(), + can_view_auto_top_up_member_notice: z + .enum([ + 'not_a_member', + 'workspace_owner', + 'payment_past_due', + 'tier_not_self_serve', + 'subscription_status_unrecognized', + 'topup_purchases_paused' + ]) + .optional(), can_view_own_usage: z .enum(['not_a_member', 'usage_attribution_unavailable']) .optional(), @@ -5172,9 +5197,11 @@ export const zBillingCapabilityDenialParams = z.object({ export const zBillingCapabilitiesResponse = z.object({ auto_top_up_enabled: z.boolean(), auto_top_up_setup: zAutoTopUpSetup.optional(), + billing_notice_audience: z.enum(['none', 'team', 'personal']).optional(), capabilities: zBillingCapabilities, denied_reason_params: zBillingCapabilityDenialParams.optional(), denied_reasons: zBillingCapabilityDenials.optional(), + ending_notice_starts_at: z.iso.datetime().optional(), expires_at: z.iso.datetime(), has_parked_billing_operation: z.boolean().optional(), payment_recovery_available: z.boolean().optional(), diff --git a/src/platform/auth/webSessionFlagOff.test.ts b/src/platform/auth/webSessionFlagOff.test.ts index 54dfb7cbe38..05002823407 100644 --- a/src/platform/auth/webSessionFlagOff.test.ts +++ b/src/platform/auth/webSessionFlagOff.test.ts @@ -176,6 +176,8 @@ const CAPABILITIES = { can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/src/platform/auth/webSessionFlagOn.test.ts b/src/platform/auth/webSessionFlagOn.test.ts index 28d9bc12457..a1cc66e3c1f 100644 --- a/src/platform/auth/webSessionFlagOn.test.ts +++ b/src/platform/auth/webSessionFlagOn.test.ts @@ -674,6 +674,8 @@ function capabilitiesResponse({ can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/src/platform/billing/api/__mocks__/billingApi.ts b/src/platform/billing/api/__mocks__/billingApi.ts index 8bf97dfd52f..ac9612341c8 100644 --- a/src/platform/billing/api/__mocks__/billingApi.ts +++ b/src/platform/billing/api/__mocks__/billingApi.ts @@ -36,6 +36,8 @@ export const billingApi = vi.mockObject( can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/src/platform/billing/components/billingTab/BillingLocalCreditBanner.capabilities.test.ts b/src/platform/billing/components/billingTab/BillingLocalCreditBanner.capabilities.test.ts index 44c93292032..a05d05fbad4 100644 --- a/src/platform/billing/components/billingTab/BillingLocalCreditBanner.capabilities.test.ts +++ b/src/platform/billing/components/billingTab/BillingLocalCreditBanner.capabilities.test.ts @@ -72,6 +72,8 @@ function capabilitiesBody(deniedReasons: Record) { can_invite_members: false, can_leave_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_billing: true, can_manage_members: false, can_manage_partner_node_access: false, diff --git a/src/platform/billing/composables/useBillingCapabilities.crossUser.test.ts b/src/platform/billing/composables/useBillingCapabilities.crossUser.test.ts index 062880fde2a..3e7e280a9ac 100644 --- a/src/platform/billing/composables/useBillingCapabilities.crossUser.test.ts +++ b/src/platform/billing/composables/useBillingCapabilities.crossUser.test.ts @@ -59,6 +59,8 @@ function capabilitiesFor( can_view_team_usage: isOwner, can_edit_workspace: isOwner, can_manage_auto_top_up: isOwner, + can_view_auto_top_up: isOwner, + can_view_auto_top_up_member_notice: !isOwner, can_manage_subscription: isOwner, can_open_plans: isOwner, can_run_workflows: isOwner, diff --git a/src/platform/billing/composables/useBillingCapabilities.test.ts b/src/platform/billing/composables/useBillingCapabilities.test.ts index b25ec6c5162..29e0046d7b0 100644 --- a/src/platform/billing/composables/useBillingCapabilities.test.ts +++ b/src/platform/billing/composables/useBillingCapabilities.test.ts @@ -83,6 +83,8 @@ function capabilitiesResponse( can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, @@ -1487,6 +1489,8 @@ describe('useBillingCapabilities on the SDK rail', () => { can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/src/platform/billing/sdk/billingCapabilitiesView.test.ts b/src/platform/billing/sdk/billingCapabilitiesView.test.ts index e2d6e64f7f0..89230deb128 100644 --- a/src/platform/billing/sdk/billingCapabilitiesView.test.ts +++ b/src/platform/billing/sdk/billingCapabilitiesView.test.ts @@ -19,6 +19,8 @@ const SNAPSHOT: CapabilitiesSnapshot = { can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/src/platform/billing/sdk/billingSdkTelemetryOwnership.test.ts b/src/platform/billing/sdk/billingSdkTelemetryOwnership.test.ts index 1a6174a704a..9ab7b4aca20 100644 --- a/src/platform/billing/sdk/billingSdkTelemetryOwnership.test.ts +++ b/src/platform/billing/sdk/billingSdkTelemetryOwnership.test.ts @@ -158,6 +158,8 @@ const CAPABILITIES = { can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/src/platform/billing/sdk/createBillingSdk.test.ts b/src/platform/billing/sdk/createBillingSdk.test.ts index f94bd60cf93..3c4e5b310b9 100644 --- a/src/platform/billing/sdk/createBillingSdk.test.ts +++ b/src/platform/billing/sdk/createBillingSdk.test.ts @@ -71,6 +71,8 @@ const CAPABILITIES = { can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false, diff --git a/src/platform/billing/telemetry/workspaceTelemetryContext.test.ts b/src/platform/billing/telemetry/workspaceTelemetryContext.test.ts index 60b4cf46a6e..52b08859ca3 100644 --- a/src/platform/billing/telemetry/workspaceTelemetryContext.test.ts +++ b/src/platform/billing/telemetry/workspaceTelemetryContext.test.ts @@ -179,6 +179,8 @@ describe('useBillingCapabilities workspace scope mismatch', () => { can_view_team_usage: false, can_edit_workspace: false, can_manage_auto_top_up: false, + can_view_auto_top_up: false, + can_view_auto_top_up_member_notice: false, can_manage_subscription: false, can_open_plans: false, can_run_workflows: false,