[2026-04-16] C-247: Add S2S analytics events API documentation#6
Open
[2026-04-16] C-247: Add S2S analytics events API documentation#6
Conversation
Document the new POST /v2/analytics_events and /v2/analytics_events/batch endpoints for server-to-server custom analytics event ingestion. - Single and batch endpoint docs with full parameter descriptions - Geo resolution priority documented: ip_address > country_code > last SDK session - Success, error (400/404/429) response examples - Added to nav.adoc ## Human-Claude Interaction Log ### Human prompts (VERBATIM): 1. "I've already updated the Linear issue's status. I've cut a branch in ../server-api-docs, so you can update the docs there." → Claude: Explored server-api-docs repo structure, read existing endpoint docs (player_properties) for conventions, created matching AsciiDoc page and nav entry. ### Key decisions made: - Human guided: docs go in server-api-docs repo on pre-cut branch - Claude discovered: repo uses Antora with AsciiDoc, followed player_properties doc conventions exactly 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Adds Antora/AsciiDoc documentation for new server-to-server analytics event ingestion endpoints so integrators can send custom events from game servers and understand request/response formats and geo resolution behavior.
Changes:
- Added a new
v2_analytics_eventsdocs page covering single-event and batch ingestion endpoints. - Documented required/optional parameters, geo resolution priority, and success/error response examples.
- Added the new page to the ROOT navigation.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| modules/ROOT/pages/other/v2_analytics_events.adoc | New documentation page for /v2/analytics_events and /v2/analytics_events/batch endpoints. |
| modules/ROOT/nav.adoc | Adds “Analytics Events” to the documentation navigation. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
AlexSc
requested changes
Apr 10, 2026
Member
AlexSc
left a comment
There was a problem hiding this comment.
I put all the review comments on the batch endpoint, but they apply to the non batch endpoint too. Just happened to be where I was when I started taking notes.
…C-247) - Rename ip_address → client_ip for consistency with v2/identify - Rename duration → value with corrected description (arbitrary numeric value, not time duration — OLAP column reuse) - Move object_type from required to optional (both endpoints) - Add "Defaults to 1 if omitted" for event_count, value, sum_of_squares - Replace batch example with coin sink use case demonstrating value and sum_of_squares fields ## Human-Claude Interaction Log ### Human prompts (VERBATIM): 1. "We're going to make some fixes to both this branch of the carrot repo, and a corresponding branch of the server-api-docs repo (feat/c-247-server-to-server-api-for-custom-analytics-events)." → Claude: Explored both repos to understand current state 2. "Take a look at PR #6 on the server-api-docs repo. The discussion there outlines what we need to do." → Claude: Read PR comments from AlexSc, identified 6 action items 3. "Mostly. I'd also like to rename the `duration` parameter to `value` in order to keep the public-facing API from becoming confusing." → Claude: Added duration→value rename to the plan, implemented all changes 4. "Looks good! Please commit your work on both branches. It looks like for the carrot repo you've made a new branch called claude/epic-ride. Please merge that into the feat/c-247-server-to-server-api-for-custom-analytics-events branch." → Claude: Committing and merging ### Key decisions made: - Human guided: rename duration→value for public API clarity - Human guided: merge worktree branch into feature branch - Claude discovered: object_type had no required validation in controller already 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Document the new POST /v2/analytics_events and /v2/analytics_events/batch endpoints for server-to-server custom analytics event ingestion.
Human-Claude Interaction Log
Human prompts (VERBATIM):
Key decisions made:
🤖 Generated with Claude Code