Add paidTierTrial to subscriptionUsage GraphQL API

What does this MR do and why?

Related to https://gitlab.com/gitlab-org/customers-gitlab-com/-/work_items/15815

This MR exposes the paid tier trial state from CustomersDot to support the UI showing a banner with link to CustomersDot.

This adds a new PaidTierTrialType GraphQL type with an isActive boolean field to the subscriptionUsage schema. The field delegates to CustomersDot and maps paidTierTrial.isActive from the metadata response.

Changes:

  • Extend CDOT metadata query to request paidTierTrial { isActive }
  • Add PaidTierTrialType GraphQL type with isActive field
  • Add paid_tier_trial method to SubscriptionUsage model
  • Update SubscriptionUsageType to include paid_tier_trial field

References

https://gitlab.com/gitlab-org/customers-gitlab-com/-/work_items/15815+

Screenshots or screen recordings

Screenshot_2026-02-02_at_4.58.06_PM

How to set up and validate locally

  1. Login to your GDK at http://localhost:3000

  2. Pick a group you want to test with and note the namespace path

  3. Go to http://localhost:3000/-/graphql-explorer

  4. Enter the query as shown below:

     query getSubscriptionUsage($namespacePath: ID) {
       subscriptionUsage(namespacePath: $namespacePath) {
         startDate
         endDate
         paidTierTrial {
           isActive
         }
       }
     }

    With variables:

    {
      "namespacePath": "clickhouse"
    }
  5. The response should contain the new paidTierTrial.isActive field.

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Tyler Amos

Merge request reports

Loading