Skip to content

update pricing.yaml files#6

Merged
agreea merged 2 commits into
flowglad:mainfrom
lpmsh:pay-as-you-go
Jan 1, 2026
Merged

update pricing.yaml files#6
agreea merged 2 commits into
flowglad:mainfrom
lpmsh:pay-as-you-go

Conversation

@lpmsh

@lpmsh lpmsh commented Dec 31, 2025

Copy link
Copy Markdown
Contributor

The previous pricing.yaml was not able to be imported into Flowglad as a pricing model. I re-exported it to update the pricing file.

Summary by CodeRabbit

  • Chores
    • Updated pricing configuration schema: per-product pricing entries are now single objects instead of arrays.
    • Preserved all existing pricing values while consolidating price-related fields under the single price object.
    • Added/standardized optional trial period and usage-meter metadata in some products for consistent price definitions.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai

coderabbitai Bot commented Dec 31, 2025

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

Converted per-product pricing from a prices array to a single price mapping across multiple subscription pricing YAMLs; field names and values were preserved or moved into the new price object (some entries gained a trialPeriodDays key or had usageMeterId relocated).

Changes

Cohort / File(s) Summary
Pay-as-you-go pricing
pay-as-you-go/pricing.yaml
Replaced prices: [...] with price: { ... }. All nested price fields preserved and inlined from the previous array entry.
Generation-based subscription
generation-based-subscription/pricing.yaml
Replaced per-product prices arrays with single price objects; added trialPeriodDays: null in several price objects where present.
Tiered usage gated subscription
tiered-usage-gated-subscription/pricing.yaml
Converted each product's prices list into a singular price mapping; preserved fields (intervalUnit, intervalCount, type, isDefault, unitPrice, usageEventsPerUnit, active, slug, usageMeterId).
Usage-limit subscription
usage-limit-subscription/pricing.yaml
Inlined prices array entries into price objects for multiple products (e.g., Fast Request Overages, Hobby, Pro, Pro+, Ultra); moved some usageMeterId values into the price object.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 I hopped through YAML, tidy and spry,
Now each product keeps its single price,
No lists to chase—just one neat line,
A carrot for schemas, crisp and fine! 🥕

Pre-merge checks

❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Title check ❓ Inconclusive The title 'update pricing.yaml files' is vague and generic, using non-descriptive language that fails to convey the specific structural changes made to the pricing schema across four configuration files. Provide a more specific title that captures the main change, such as 'Refactor pricing schema from array-based to single object per product' or 'Convert prices array to single price object in pricing files'.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

📜 Recent review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 497ab41 and d76a3c4.

📒 Files selected for processing (3)
  • generation-based-subscription/pricing.yaml
  • tiered-usage-gated-subscription/pricing.yaml
  • usage-limit-subscription/pricing.yaml
🔇 Additional comments (3)
generation-based-subscription/pricing.yaml (1)

113-292: LGTM! Structural conversion is consistent across all products.

The conversion from prices array to price object is applied uniformly across all 9 products. Field values are preserved, YAML syntax is correct, and the different field patterns (e.g., usageMeterSlug for usage-type products vs usageMeterId: null for subscription-type) appear intentional based on product type.

Please verify that these updated pricing files successfully import into Flowglad as pricing models to confirm the new structure meets the expected schema.

tiered-usage-gated-subscription/pricing.yaml (1)

159-384: LGTM! Consistent structural conversion across all products.

All 9 products have been successfully converted from prices array to price object format. The pattern is consistent: subscription products use usageMeterId: null, while usage-type tracking products include trialPeriodDays: null and usageMeterSlug. The YAML structure is valid.

usage-limit-subscription/pricing.yaml (1)

65-158: LGTM! All products converted consistently with correct trial period configuration.

The conversion from prices array to price object is complete across all 5 products. Notably, the Pro plan correctly specifies trialPeriodDays: 14, which aligns with the product description ("Free with 14-day Pro trial"). The usage-type product (Fast Request Overages) appropriately uses usageMeterSlug, while subscription products use usageMeterId: null.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@lpmsh lpmsh changed the title pay as you go pricing.yaml update pricing.yaml files Dec 31, 2025
@lpmsh

lpmsh commented Dec 31, 2025

Copy link
Copy Markdown
Contributor Author

I'll do this for the other examples too...

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
pay-as-you-go/pricing.yaml (1)

1-75: Schema change introduces incompatibility with Flowglad's documented format.

The restructuring changes products from using prices: (array) to price: (object), but Flowglad's official documentation specifies the expected schema uses prices: (plural, array). Additionally, this creates inconsistency with the other three pricing files in the repository (generation-based-subscription, tiered-usage-gated-subscription, and usage-limit-subscription), which all continue to use the prices: array format.

Before this change can be merged, verify whether:

  1. The schema should align with Flowglad's documented format (prices: array per product)
  2. All four pricing files need to be updated consistently
📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 82430d7 and 497ab41.

📒 Files selected for processing (1)
  • pay-as-you-go/pricing.yaml
🔇 Additional comments (3)
pay-as-you-go/pricing.yaml (3)

19-30: LGTM! Free Plan pricing structure updated correctly.

The conversion from prices array to price object is clean. The single-payment free plan configuration with unitPrice: 0 and appropriate null values for recurring fields is correct.


39-49: LGTM! Usage-based pricing structure updated correctly.

The conversion maintains all fields properly. The usage-type price with unitPrice: 0 and usageMeterSlug: "message_credits" correctly references the usage meter defined later in the file.


58-69: LGTM! Message Topup pricing structure updated correctly.

The single-payment topup product is properly configured with unitPrice: 10000 and correctly references the "100_messages" feature grant.

@angihe93 angihe93 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice, would be good to update the other yamls too

@agreea agreea merged commit a535334 into flowglad:main Jan 1, 2026
2 checks passed
@coderabbitai coderabbitai Bot mentioned this pull request Jan 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants