Skip to content

Turn realtime page into a section#2772

Merged
atharvadeosthale merged 5 commits intomainfrom
realtime-section
Mar 12, 2026
Merged

Turn realtime page into a section#2772
atharvadeosthale merged 5 commits intomainfrom
realtime-section

Conversation

@atharvadeosthale
Copy link
Member

@atharvadeosthale atharvadeosthale commented Feb 26, 2026

Summary by CodeRabbit

  • Documentation

    • Added comprehensive Realtime API documentation covering authentication, channels, custom endpoints, payload structures, queries, and subscriptions
    • Simplified and reorganized Realtime documentation for improved clarity
  • New Features

    • Introduced structured navigation for REST and Realtime API documentation sections

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 12, 2026

Walkthrough

This pull request restructures the Realtime API documentation by introducing a nested navigation hierarchy. It adds a new parent navigation item for Realtime with multiple child documentation pages covering authentication, channels, custom endpoints, payload structure, queries, and subscription methods. The main realtime documentation page is simplified to focus on basic examples. Additionally, the sidebar navigation logic is updated to support parent items, import paths for sidebar components are corrected, and a new REST documentation layout is introduced.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~22 minutes

🚥 Pre-merge checks | ✅ 3
✅ 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 accurately describes the main change: converting the realtime documentation page into a multi-page section with new layout, sub-pages (subscribe, channels, authentication, queries, payload, custom-endpoint), and navigation updates.
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
  • Post copyable unit tests in a comment
  • Commit unit tests in branch realtime-section
📝 Coding Plan for PR comments
  • Generate coding plan

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: 7

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

Inline comments:
In `@src/routes/docs/apis/realtime/`+layout.svelte:
- Around line 10-54: Add the missing "Limitations" nav entry to the navigation
tree by updating the navigation constant (NavTree) in +layout.svelte: add an
item with label "Limitations" and href "/docs/apis/realtime/limitations" into
the appropriate section (e.g., under Concepts or wherever similar pages live) so
the newly created limitations/+page.markdoc is discoverable in the sidebar;
modify the navigation array defined as navigation: NavTree to include this new
object in the items list.

In `@src/routes/docs/apis/realtime/channels/`+page.markdoc:
- Around line 165-167: Replace the inconsistent placeholder in the
documentation: change the example using Channel.execution(ID) to the same quoted
placeholder style used elsewhere (e.g., Channel.execution('<EXECUTION_ID>') or
Channel.execution('<ID>')) so it matches entries like `executions.<ID>` and
`'<FUNCTION_ID>'`/`'<EXECUTION_ID>'`; update the `Channel.execution(ID)`
occurrence to use the quoted placeholder format to maintain consistency across
examples.

In `@src/routes/docs/apis/realtime/payload/`+page.markdoc:
- Around line 26-28: The example timestamp for the "timestamp" field uses a
space-separated datetime ("2023-01-19 18:30:04.051") but the description claims
ISO 8601; either update the example to a valid ISO 8601 UTC string (e.g.
"2023-01-19T18:30:04.051Z") so it matches the description, or change the
description for the timestamp field to explicitly state the server returns a
space-separated format (e.g. "YYYY-MM-DD HH:mm:ss.SSS in UTC") and keep the
example as-is; edit the "timestamp" entry and the example value accordingly.
- Line 11: Update the sentence "The payload from the subscription will contain
following properties:" by inserting the missing article "the" so it reads "The
payload from the subscription will contain the following properties:"; locate
this exact string in the +page.markdoc content and make the one-word addition.

In `@src/routes/docs/apis/realtime/subscribe/`+page.markdoc:
- Around line 120-124: The Dart example is missing a terminating semicolon after
the subscription.stream.listen(...) statement; update the snippet where
subscription.stream.listen((response) { print(response); }) is shown to include
a trailing semicolon so the call becomes a complete statement (i.e., add ";"
after the closing parenthesis of subscription.stream.listen). Ensure you modify
the block containing subscription.stream.listen to reflect this change.
- Around line 200-204: The Dart example is missing a terminating semicolon after
the subscription.stream.listen(...) call; update the code snippet that uses
subscription.stream.listen((response) { ... }) to add a semicolon immediately
after the closing parenthesis so the statement becomes a valid Dart expression
(i.e., place a semicolon after the listen(...) call).
- Around line 40-44: The Dart example is missing a terminating semicolon on the
subscription.stream.listen call; update the example so the listener invocation
ends with "});" instead of "})" (i.e., add the semicolon after the closing brace
of subscription.stream.listen callback) to produce a valid Dart statement for
the subscription.stream.listen((response) { ... }); invocation.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 1ccf4bc9-fe11-4169-b577-e568b74964bc

📥 Commits

Reviewing files that changed from the base of the PR and between 84d2d20 and f7b9252.

📒 Files selected for processing (12)
  • src/routes/docs/Sidebar.svelte
  • src/routes/docs/apis/graphql/+layout.svelte
  • src/routes/docs/apis/realtime/+layout.svelte
  • src/routes/docs/apis/realtime/+page.markdoc
  • src/routes/docs/apis/realtime/authentication/+page.markdoc
  • src/routes/docs/apis/realtime/channels/+page.markdoc
  • src/routes/docs/apis/realtime/custom-endpoint/+page.markdoc
  • src/routes/docs/apis/realtime/limitations/+page.markdoc
  • src/routes/docs/apis/realtime/payload/+page.markdoc
  • src/routes/docs/apis/realtime/queries/+page.markdoc
  • src/routes/docs/apis/realtime/subscribe/+page.markdoc
  • src/routes/docs/apis/rest/+layout.svelte

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: 1

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

Inline comments:
In `@src/routes/docs/apis/realtime/subscribe/`+page.markdoc:
- Around line 259-271: The Apple Realtime snippet creates a Realtime from an
unconfigured Client and uses a non‑idiomatic response.toString(), making it
non‑runnable and inconsistent; update the example to import AppwriteModels,
configure the Client with setEndpoint(...) and setProject(...), keep
Realtime(client) and the subscribe call using Channel.files(), and replace
response.toString() with print(String(describing: response)) so the snippet is
copy‑paste runnable and matches other Apple examples.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 300dc2f1-b3fb-4f21-9830-5282cff85c11

📥 Commits

Reviewing files that changed from the base of the PR and between f7b9252 and 21deb03.

📒 Files selected for processing (6)
  • src/routes/docs/apis/realtime/+page.markdoc
  • src/routes/docs/apis/realtime/channels/+page.markdoc
  • src/routes/docs/apis/realtime/custom-endpoint/+page.markdoc
  • src/routes/docs/apis/realtime/payload/+page.markdoc
  • src/routes/docs/apis/realtime/queries/+page.markdoc
  • src/routes/docs/apis/realtime/subscribe/+page.markdoc
🚧 Files skipped from review as they are similar to previous changes (4)
  • src/routes/docs/apis/realtime/payload/+page.markdoc
  • src/routes/docs/apis/realtime/queries/+page.markdoc
  • src/routes/docs/apis/realtime/channels/+page.markdoc
  • src/routes/docs/apis/realtime/custom-endpoint/+page.markdoc

@atharvadeosthale atharvadeosthale merged commit e94e148 into main Mar 12, 2026
6 checks passed
@atharvadeosthale atharvadeosthale deleted the realtime-section branch March 12, 2026 15:03
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.

2 participants