Skip to content

Conversation

@hekike
Copy link
Contributor

@hekike hekike commented Sep 10, 2025

Overview

Fixes #(issue)

Notes for reviewer

Summary by CodeRabbit

  • Documentation

    • Updated “Subscriptions” description to emphasize you can start, cancel, and manage subscriptions, with examples (provisioning plans, assigning custom rate cards). Removed the prior “contact us for access” note. Reflected across API specs and generated docs.
  • Chores

    • Regenerated embedded API specifications to align SDKs and clients with the updated Subscriptions documentation, with no functional or API surface changes.

@hekike hekike requested a review from tothandras September 10, 2025 14:24
@hekike hekike requested a review from a team as a code owner September 10, 2025 14:24
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 10, 2025

📝 Walkthrough

Walkthrough

Replaces embedded swaggerSpec blobs in generated Go files and updates the Subscriptions tag description across OpenAPI YAML and TSP spec files. No code structure, control flow, or public API signatures changed; updates are content/text replacements only.

Changes

Cohort / File(s) Summary of changes
Generated Go swaggerSpec updates
api/api.gen.go, api/client/go/client.gen.go
Replaced the embedded swaggerSpec string slices with new data; GetSwagger behavior unchanged.
OpenAPI YAML tag description updates
api/openapi.yaml, api/openapi.cloud.yaml
Updated Subscriptions tag description text to an action-oriented phrasing with examples; no schema or endpoint changes.
TSP spec tag description updates
api/spec/src/main.tsp, api/spec/src/cloud/main.tsp
Updated Subscriptions tag metadata description text; no structural or API changes.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Pre-merge checks (3 passed)

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title succinctly describes the primary documentation change by indicating that the request access prompt has been removed from the API specification, reflecting the updates made to the Subscriptions tag descriptions without introducing extraneous details or ambiguity.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.

Tip

👮 Agentic pre-merge checks are now available in preview!

Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.

  • Built-in checks – Quickly apply ready-made checks to enforce title conventions, require pull request descriptions that follow templates, validate linked issues for compliance, and more.
  • Custom agentic checks – Define your own rules using CodeRabbit’s advanced agentic capabilities to enforce organization-specific policies and workflows. For example, you can instruct CodeRabbit’s agent to verify that API documentation is updated whenever API schema files are modified in a PR. Note: Upto 5 custom checks are currently allowed during the preview period. Pricing for this feature will be announced in a few weeks.

Please see the documentation for more information.

Example:

reviews:
  pre_merge_checks:
    custom_checks:
      - name: "Undocumented Breaking Changes"
        mode: "warning"
        instructions: |
          Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).

Please share your feedback with us on this Discord post.

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch docs/api-remove-request-access

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.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (6)
api/spec/src/cloud/main.tsp (1)

101-101: Optional copy tweak: remove “easily” and tighten phrasing.

Keeps a neutral tone and parallel structure.

-    description: "With Subscriptions, you can easily start, cancel, and manage customer subscriptions. For example, provisioning them on a specific plan or assigning custom rate cards.",
+    description: "With Subscriptions, you can start, cancel, and manage customer subscriptions—for example, provision them on a specific plan or assign custom rate cards.",
api/openapi.cloud.yaml (1)

14-14: Polish the example sentence to avoid a fragment and pronoun ambiguity.

Consider making the example a full sentence and replacing “them” with “customers.”

Apply:

-    description: With Subscriptions, you can easily start, cancel, and manage customer subscriptions. For example, provisioning them on a specific plan or assigning custom rate cards.
+    description: With Subscriptions, you can easily start, cancel, and manage customer subscriptions. For example, you can provision customers on a specific plan or assign custom rate cards.
api/spec/src/main.tsp (1)

109-109: Tone/grammar nit: tighten phrasing to match other tags.

Drop “easily” and fix the non-parallel “For example, provisioning…”.

-    description: "With Subscriptions, you can easily start, cancel, and manage customer subscriptions. For example, provisioning them on a specific plan or assigning custom rate cards.",
+    description: "Start, cancel, and manage customer subscriptions. For example, provision subscriptions on a specific plan or assign custom rate cards.",

Optional: mirror Notifications by adding a doc link if one exists (e.g., “Read more”).

api/openapi.yaml (1)

15-15: Wording nit: remove pronoun ambiguity and keep tone neutral.

“provisioning them” is ambiguous (subscriptions vs. customers). Suggest tightening.

-    description: With Subscriptions, you can easily start, cancel, and manage customer subscriptions. For example, provisioning them on a specific plan or assigning custom rate cards.
+    description: Manage customer subscriptions: start, cancel, and modify. For example, provision subscriptions on a specific plan or assign custom rate cards.
api/client/go/client.gen.go (1)

43117-43377: Reduce diff noise in future: prefer go:embed over base64 blobs.

If feasible in your generator pipeline, embed the OpenAPI JSON/YAML via Go 1.16+ //go:embed (or ship the spec as a separate asset). This keeps PRs readable and minimizes churn.

api/api.gen.go (1)

20636-20645: Optional: switch from huge string-literals to go:embed for smaller diffs

Embedding the raw YAML/JSON via go:embed (and gzip at build or serve time) reduces churn in PRs and keeps diffs readable. This is a non-blocking, future-facing improvement.

Example (outside this PR):

//go:generate oapi-codegen -generate types,server -o api.gen.go -package api api/openapi.yaml
//go:embed openapi.yaml
var openapiYAML []byte

func GetSwagger() []byte { return openapiYAML } // or gzip-compress once in init()
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 8cba184 and 24e0e1b.

📒 Files selected for processing (6)
  • api/api.gen.go (1 hunks)
  • api/client/go/client.gen.go (1 hunks)
  • api/openapi.cloud.yaml (1 hunks)
  • api/openapi.yaml (1 hunks)
  • api/spec/src/cloud/main.tsp (1 hunks)
  • api/spec/src/main.tsp (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
  • GitHub Check: Test
  • GitHub Check: Build
  • GitHub Check: Code Generators
  • GitHub Check: Lint
  • GitHub Check: Analyze (go)
🔇 Additional comments (11)
api/spec/src/cloud/main.tsp (2)

99-103: Request-access text removed — looks good and aligns with PR intent.

No API/signature impact; doc copy reflects capabilities without gating language.


99-103: Specs updated — no stale references found
No occurrences of “Request access” or contact@openmeter.cloud remain; the @tagMetadata("Subscriptions") description is present in api/spec/src/cloud/main.tsp, and no stale Swagger/OpenAPI blobs reference the old text.

api/openapi.cloud.yaml (2)

14-14: Removal of “request access” language looks good.

This aligns the docs with self-serve onboarding and avoids funneling users to support.


11-17: Subscriptions description consistency verified
The description text is identical in api/openapi.yaml, api/openapi.cloud.yaml, api/spec/src/main.tsp, and api/spec/src/cloud/main.tsp, and no stale “Request access” remains.

api/spec/src/main.tsp (1)

107-111: Docs copy cleanup is good.

Removing the “request access” language aligns the tag with GA availability.

api/openapi.yaml (2)

15-15: Change aligns with PR goal (removes request-access prompt).

This updates the Subscriptions tag description without altering API semantics. LGTM.


15-15: No leftover “Request access” or contact email references found
Verified a repo-wide search for “Request access”, “request access”, and “contact@openmeter.cloud” returned no matches.

api/client/go/client.gen.go (2)

43117-43377: Regenerated swaggerSpec blob — LGTM.

Only the embedded data changed; the slice literal structure and GetSwagger entry point remain intact. Safe to merge from a code perspective.


43117-43377: Approved swaggerSpec doc-only update
Decoded swaggerSpec (OpenAPI 3.0.0), confirmed the updated Subscriptions tag description, and found no added or removed paths compared to api/openapi.yaml.

api/api.gen.go (2)

20398-20410: LGTM: spec payload updated, code shape untouched

The change is confined to the embedded swaggerSpec string literals. No exported APIs or control flow altered. Safe doc-only refresh.


20599-20610: Embedded swaggerSpec contains no “request access” text – After decoding and scanning the gzip/base64 payload, no banned phrases were found.

@hekike hekike added the release-note/ignore Ignore this change when generating release notes label Sep 10, 2025
@hekike hekike requested a review from GAlexIHU September 10, 2025 15:12
@hekike hekike merged commit 6521f6b into main Sep 10, 2025
26 of 27 checks passed
@hekike hekike deleted the docs/api-remove-request-access branch September 10, 2025 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release-note/ignore Ignore this change when generating release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants