Skip to content

Docs: fix whitelabel field type in get-project API schema#18

Open
novavolcanic wants to merge 1 commit intomainfrom
docs/fix-whitelabel-type
Open

Docs: fix whitelabel field type in get-project API schema#18
novavolcanic wants to merge 1 commit intomainfrom
docs/fix-whitelabel-type

Conversation

@novavolcanic
Copy link
Copy Markdown
Contributor

@novavolcanic novavolcanic commented Apr 10, 2026

Closes #16

What changed

Changed the whitelabel field type in docs/api/get-project.StatusCodes.json from "string" to "boolean". Updated the description from the vague "Whitelabel settings." to explain what the field actually means.

Source of truth

  • biel/apps/teams/models.py:35whitelabel = models.BooleanField(default=False)
  • biel/apps/projects/serializers.py:44–45get_whitelabel returns the BooleanField value directly
  • biel-search/src/components/biel-bot/biel-bot.tsx:588 — widget treats it as boolean: this.showPoweredBy = !result.whitelabel

Verification

  • Code examples match actual API/props
  • Internal links verified
  • Follows Google developer documentation style guide

Summary by CodeRabbit

  • Documentation
    • Updated OpenAPI schema for the get-project API endpoint's whitelabel property in the 200 response. Changed type from string to boolean with clarified description indicating it controls "Powered by Biel.ai" branding visibility.

Change whitelabel from "string" to "boolean" to match the Django
BooleanField in teams/models.py and the serializer return value.
Update the description to explain what true/false means for this field.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 10, 2026

📝 Walkthrough

Walkthrough

Updated the OpenAPI schema documentation for the whitelabel field in the get-project API response, correcting its type from string to boolean and providing a more descriptive explanation of its functionality.

Changes

Cohort / File(s) Summary
API Schema Documentation
docs/api/get-project.StatusCodes.json
Changed whitelabel property type from string to boolean in the 200 response schema and updated description to clarify it controls hiding "Powered by Biel.ai" branding with plan requirements.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Poem

🐰 A boolean was hiding in plain sight,
Wearing string clothes, oh what a fright!
Now the docs reveal what's true,
No more confusion—the type shines through! ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: fixing the whitelabel field type in the get-project API schema from string to boolean.
Linked Issues check ✅ Passed The PR fully implements all coding requirements from issue #16: type changed to boolean, description updated with plain language explanation, and readOnly status maintained.
Out of Scope Changes check ✅ Passed All changes are directly scoped to issue #16 requirements. Only the whitelabel property definition in the schema file was modified; no extraneous changes detected.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/fix-whitelabel-type

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
Copy Markdown

@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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs/api/get-project.StatusCodes.json`:
- Line 1: Update the response schema descriptions to use present-tense,
second-person phrasing: change property descriptions like "Whether the 'Powered
by Biel.ai' branding is hidden." to "Whether you hide the 'Powered by Biel.ai'
branding.", "Pre-configured suggested questions." to "Pre-configured suggested
questions for you.", "Greeting message shown when users open the chat." to
"Greeting message shown to users when they open the chat.", and similarly
convert "Search filters configured for the project.", "Whether reasoning mode is
enabled.", "Whether the project requires authentication.", "Whether MCP server
integration is enabled.", "Display name of the MCP server.", and "Tag to
identify MCP-originated conversations." into second-person present-tense
variants; also ensure the top-level response description ("Project details
retrieved successfully") follows the same voice if needed.
- Line 1: The OpenAPI canonical schema still types Project.whitelabel as string
while docs/api/get-project.StatusCodes.json uses boolean; update the canonical
OpenAPI Project schema to set the whitelabel property to type: boolean (and keep
readOnly/description intact) so generators won't regress; locate the Project
object in the OpenAPI schema (schema.yaml) and change Project.whitelabel from
"type: string" to "type: boolean", run any schema validation/regen scripts
afterward to ensure consistency.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: c181c2d7-89f6-4680-99bd-e5d653403d58

📥 Commits

Reviewing files that changed from the base of the PR and between 39a5251 and c1164ef.

📒 Files selected for processing (1)
  • docs/api/get-project.StatusCodes.json

@@ -1 +1 @@
{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object","properties":{"whitelabel":{"type":"string","readOnly":true,"description":"Whitelabel settings."},"suggested_questions":{"type":"string","readOnly":true,"description":"Pre-configured suggested questions."},"initial_message":{"type":"string","description":"Greeting message shown when users open the chat."},"filters":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","description":"Display title of the filter."}},"required":["title"],"title":"Filter"},"readOnly":true,"description":"Search filters configured for the project."},"think_mode":{"type":"boolean","readOnly":true,"description":"Whether reasoning mode is enabled."},"is_private":{"type":"boolean","readOnly":true,"description":"Whether the project requires authentication."},"mcp_enabled":{"type":"boolean","description":"Whether MCP server integration is enabled."},"mcp_server_name":{"type":"string","description":"Display name of the MCP server."},"mcp_metadata_tag":{"type":"string","description":"Tag to identify MCP-originated conversations."}},"required":["filters","initial_message","suggested_questions","whitelabel","think_mode","is_private","mcp_enabled","mcp_server_name","mcp_metadata_tag"],"title":"Project"}}},"description":"Project details retrieved successfully"},"403":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Forbidden - missing permissions"},"404":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Project not found"}}} No newline at end of file
{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object","properties":{"whitelabel":{"type":"boolean","readOnly":true,"description":"Whether the 'Powered by Biel.ai' branding is hidden. Requires a Professional plan or above."},"suggested_questions":{"type":"string","readOnly":true,"description":"Pre-configured suggested questions."},"initial_message":{"type":"string","description":"Greeting message shown when users open the chat."},"filters":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","description":"Display title of the filter."}},"required":["title"],"title":"Filter"},"readOnly":true,"description":"Search filters configured for the project."},"think_mode":{"type":"boolean","readOnly":true,"description":"Whether reasoning mode is enabled."},"is_private":{"type":"boolean","readOnly":true,"description":"Whether the project requires authentication."},"mcp_enabled":{"type":"boolean","description":"Whether MCP server integration is enabled."},"mcp_server_name":{"type":"string","description":"Display name of the MCP server."},"mcp_metadata_tag":{"type":"string","description":"Tag to identify MCP-originated conversations."}},"required":["filters","initial_message","suggested_questions","whitelabel","think_mode","is_private","mcp_enabled","mcp_server_name","mcp_metadata_tag"],"title":"Project"}}},"description":"Project details retrieved successfully"},"403":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Forbidden - missing permissions"},"404":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Project not found"}}} No newline at end of file
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Line 1: Description is clearer, but it doesn’t fully match the requested second-person style.

The issue objective asked for present tense + second person. Current text starts with “Whether the … is hidden.” Consider switching to “Whether you hide …” for strict style alignment.

Suggested wording tweak
-"description":"Whether the 'Powered by Biel.ai' branding is hidden. Requires a Professional plan or above."
+"description":"Whether you hide the 'Powered by Biel.ai' branding. Requires a Professional plan or above."
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object","properties":{"whitelabel":{"type":"boolean","readOnly":true,"description":"Whether the 'Powered by Biel.ai' branding is hidden. Requires a Professional plan or above."},"suggested_questions":{"type":"string","readOnly":true,"description":"Pre-configured suggested questions."},"initial_message":{"type":"string","description":"Greeting message shown when users open the chat."},"filters":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","description":"Display title of the filter."}},"required":["title"],"title":"Filter"},"readOnly":true,"description":"Search filters configured for the project."},"think_mode":{"type":"boolean","readOnly":true,"description":"Whether reasoning mode is enabled."},"is_private":{"type":"boolean","readOnly":true,"description":"Whether the project requires authentication."},"mcp_enabled":{"type":"boolean","description":"Whether MCP server integration is enabled."},"mcp_server_name":{"type":"string","description":"Display name of the MCP server."},"mcp_metadata_tag":{"type":"string","description":"Tag to identify MCP-originated conversations."}},"required":["filters","initial_message","suggested_questions","whitelabel","think_mode","is_private","mcp_enabled","mcp_server_name","mcp_metadata_tag"],"title":"Project"}}},"description":"Project details retrieved successfully"},"403":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Forbidden - missing permissions"},"404":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Project not found"}}}
{"responses":{"200":{"content":{"application/json":{"schema":{"type":"object","properties":{"whitelabel":{"type":"boolean","readOnly":true,"description":"Whether you hide the 'Powered by Biel.ai' branding. Requires a Professional plan or above."},"suggested_questions":{"type":"string","readOnly":true,"description":"Pre-configured suggested questions."},"initial_message":{"type":"string","description":"Greeting message shown when users open the chat."},"filters":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","description":"Display title of the filter."}},"required":["title"],"title":"Filter"},"readOnly":true,"description":"Search filters configured for the project."},"think_mode":{"type":"boolean","readOnly":true,"description":"Whether reasoning mode is enabled."},"is_private":{"type":"boolean","readOnly":true,"description":"Whether the project requires authentication."},"mcp_enabled":{"type":"boolean","description":"Whether MCP server integration is enabled."},"mcp_server_name":{"type":"string","description":"Display name of the MCP server."},"mcp_metadata_tag":{"type":"string","description":"Tag to identify MCP-originated conversations."}},"required":["filters","initial_message","suggested_questions","whitelabel","think_mode","is_private","mcp_enabled","mcp_server_name","mcp_metadata_tag"],"title":"Project"}}},"description":"Project details retrieved successfully"},"403":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Forbidden - missing permissions"},"404":{"content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}},"description":"Project not found"}}}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/api/get-project.StatusCodes.json` at line 1, Update the response schema
descriptions to use present-tense, second-person phrasing: change property
descriptions like "Whether the 'Powered by Biel.ai' branding is hidden." to
"Whether you hide the 'Powered by Biel.ai' branding.", "Pre-configured suggested
questions." to "Pre-configured suggested questions for you.", "Greeting message
shown when users open the chat." to "Greeting message shown to users when they
open the chat.", and similarly convert "Search filters configured for the
project.", "Whether reasoning mode is enabled.", "Whether the project requires
authentication.", "Whether MCP server integration is enabled.", "Display name of
the MCP server.", and "Tag to identify MCP-originated conversations." into
second-person present-tense variants; also ensure the top-level response
description ("Project details retrieved successfully") follows the same voice if
needed.

⚠️ Potential issue | 🟠 Major

Line 1: Update the canonical OpenAPI schema too to avoid drift/regression.

docs/api/get-project.StatusCodes.json is now correct, but openapi/schema.yaml:570-616 still defines Project.whitelabel as type: string. If that file is the source of truth, generators and future doc refreshes can revert this fix and keep emitting wrong client types.

Suggested source-of-truth fix
# openapi/schema.yaml
 Project:
   type: object
   properties:
     whitelabel:
-      type: string
+      type: boolean
       readOnly: true
-      description: Whitelabel settings.
+      description: Whether you hide the "Powered by Biel.ai" branding. Requires a Professional plan or above.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/api/get-project.StatusCodes.json` at line 1, The OpenAPI canonical
schema still types Project.whitelabel as string while
docs/api/get-project.StatusCodes.json uses boolean; update the canonical OpenAPI
Project schema to set the whitelabel property to type: boolean (and keep
readOnly/description intact) so generators won't regress; locate the Project
object in the OpenAPI schema (schema.yaml) and change Project.whitelabel from
"type: string" to "type: boolean", run any schema validation/regen scripts
afterward to ensure consistency.

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.

Docs: whitelabel field documented as string type in get-project API response, but it returns boolean

1 participant