Skip to content

update openapi docs#2072

Merged
lightwalker-eth merged 6 commits intomainfrom
ll/openapi-small-fixes
May 8, 2026
Merged

update openapi docs#2072
lightwalker-eth merged 6 commits intomainfrom
ll/openapi-small-fixes

Conversation

@sevenzing
Copy link
Copy Markdown
Member

Small openapi docs update according to slack message https://namehash.slack.com/archives/C086Z6FNBHN/p1778180028015519

image image

Pre-Review Checklist (Blocking)

  • This PR does not introduce significant changes and is low-risk to review quickly.
  • Relevant changesets are included (or are not required)

@sevenzing sevenzing requested a review from a team as a code owner May 8, 2026 10:55
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented May 8, 2026

⚠️ No Changeset found

Latest commit: c64f919

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented May 8, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
admin.ensnode.io Ready Ready Preview, Comment May 8, 2026 5:58pm
ensnode-enskit-react-example Ready Ready Preview, Comment May 8, 2026 5:58pm
ensnode.io Ready Ready Preview, Comment May 8, 2026 5:58pm
ensrainbow.io Ready Ready Preview, Comment May 8, 2026 5:58pm

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 8, 2026

Greptile Summary

This PR updates the ENSApi OpenAPI documentation by hiding deprecated/legacy endpoints, reorganizing tag groups, and improving descriptions to better reflect the current API surface.

  • Six legacy endpoints (/api/name-tokens, /api/registrar-actions, /api/registrar-actions/{parentNode}, and ENSAwards endpoints) are added to HIDE_OPENAPI_ENDPOINTS and removed from the generated spec; the Explore and ENSAwards tag groups are dropped from openapi-meta.ts accordingly.
  • The health and readiness probe routes are moved from the now-removed implicit Probes tag to the explicitly-defined Meta tag, and their entries in the static ensapi-openapi.json are updated to match.
  • Summaries and descriptions for the indexing status and realtime check endpoints are expanded to clarify worst-case distance semantics and the inclusion of stack info.

Confidence Score: 5/5

Safe to merge — all changes are OpenAPI metadata and description text with no runtime logic touched.

Every changed line is either a string description, a tag name, or an entry in the list of endpoints to suppress from the generated spec. The static JSON file is consistent with the source changes. No business logic, request handling, or data paths are modified.

No files require special attention.

Important Files Changed

Filename Overview
apps/ensapi/src/openapi-document.ts Adds six legacy endpoints to HIDE_OPENAPI_ENDPOINTS, hiding them from the generated OpenAPI document; comment updated to reflect deprecation intent
apps/ensapi/src/openapi-meta.ts Removes the Explore and ENSAwards tag groups and updates the Meta tag description; no functional impact
apps/ensapi/src/handlers/ensapi-probes/ensapi-probes-api.routes.ts Health and readiness check routes moved from implicit Probes tag group to the explicitly-defined Meta tag group
apps/ensapi/src/handlers/api/meta/realtime-api.routes.ts Summary and description for the realtime check endpoint updated to clarify worst-case distance semantics and caching behavior
apps/ensapi/src/handlers/api/meta/status-api.routes.ts Summary and description for the indexing status endpoint updated to mention stack info alongside indexing status
apps/ensapi/src/handlers/api/explore/name-tokens-api.routes.ts domainId parameter description improved with namehash context; endpoint is now hidden from OpenAPI docs via HIDE_OPENAPI_ENDPOINTS so only visible in source
docs/ensnode.io/ensapi-openapi.json Pre-generated OpenAPI JSON updated to match all source changes: deprecated endpoints removed, Probes tag replaced by Meta, descriptions updated

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    subgraph After["After (this PR)"]
        T1["Resolution tag"]
        T2["Meta tag"]
        T1 --> E1["/api/ensip10-resolve"]
        T1 --> E2["/api/...other resolution routes"]
        T2 --> E3["/api/indexing-status"]
        T2 --> E4["/api/realtime"]
        T2 --> E5["/health (was: Probes)"]
        T2 --> E6["/ready (was: Probes)"]
        HIDDEN["Hidden from docs\n(HIDE_OPENAPI_ENDPOINTS)"]
        HIDDEN -.-> H1["/api/name-tokens"]
        HIDDEN -.-> H2["/api/registrar-actions"]
        HIDDEN -.-> H3["/v1/ensanalytics/..."]
        HIDDEN -.-> H4["/amirealtime"]
    end

    subgraph Before["Before"]
        OT1["Resolution tag"]
        OT2["Meta tag"]
        OT3["Explore tag"]
        OT4["ENSAwards tag"]
        OT5["Probes tag (implicit)"]
        OT3 --> OE1["/api/name-tokens"]
        OT3 --> OE2["/api/registrar-actions"]
        OT4 --> OE3["/v1/ensanalytics/..."]
        OT5 --> OE4["/health"]
        OT5 --> OE5["/ready"]
    end
Loading

Reviews (4): Last reviewed commit: "Merge branch 'main' into ll/openapi-smal..." | Re-trigger Greptile

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 8, 2026

Review Change Stack

Warning

Rate limit exceeded

@lightwalker-eth has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 51 minutes and 3 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 63bf65ff-a96e-4aea-bf9a-49874a7302c8

📥 Commits

Reviewing files that changed from the base of the PR and between 2b03eb8 and c64f919.

📒 Files selected for processing (2)
  • apps/ensapi/src/openapi-document.ts
  • docs/ensnode.io/ensapi-openapi.json
📝 Walkthrough

Walkthrough

OpenAPI metadata and configuration updated to clarify indexing status semantics, reorganize health/readiness probe endpoints under the Meta tag, hide legacy analytics endpoints from the generated spec, and remove unused Explore and ENSAwards tag definitions.

Changes

OpenAPI Documentation Reorganization

Layer / File(s) Summary
Route Endpoint Metadata
apps/ensapi/src/handlers/api/meta/realtime-api.routes.ts, apps/ensapi/src/handlers/api/meta/status-api.routes.ts, apps/ensapi/src/handlers/ensapi-probes/ensapi-probes-api.routes.ts, apps/ensapi/src/handlers/api/explore/name-tokens-api.routes.ts
Individual route handlers updated: realtime and indexing status endpoints now clarify their reliance on cached snapshots; health and readiness probes moved from "Probes" to "Meta" tag; schema formatting adjusted.
OpenAPI Generation Configuration
apps/ensapi/src/openapi-document.ts, apps/ensapi/src/openapi-meta.ts
Global OpenAPI metadata simplified with shorter info description; Explore and ENSAwards tags removed from tag definitions; hidden endpoints list expanded to filter legacy analytics routes including parameterized paths.
Generated Specification
docs/ensnode.io/ensapi-openapi.json
Generated OpenAPI spec updated with consolidated endpoint documentation, reorganized tags for health and readiness endpoints, and expanded list of excluded legacy paths reflected in the output.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

  • namehash/ensnode#1940: OpenAPI spec generation and committed spec path management changes overlap with the generated spec updates.
  • namehash/ensnode#1700: OpenAPI route metadata and generation pipeline modifications are shared changes.
  • namehash/ensnode#1721: CI verification job that validates generated OpenAPI spec synchronization.

Poem

🐰 I hopped through schemas, tidy and spry,

I nudged old tags where new mettle lies,
Hid ancient paths beneath a log so neat,
Updated summaries — now docs are complete,
🌿 A carrot-cheer for the API beat.

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The title 'update openapi docs' is vague and generic, lacking specific details about what aspects of the OpenAPI documentation were updated. Consider a more descriptive title that specifies the key changes, such as 'Update API metadata and endpoint tags for realtime and indexing status endpoints' or 'Reorganize OpenAPI tags and update endpoint descriptions'.
Description check ❓ Inconclusive The description references an internal Slack link and includes images, but lacks explicit detail about what changes were made and their rationale, though it does complete the blocking checklist items. Expand the description with bullet points summarizing the main changes (metadata updates, tag reorganization, endpoint documentation refinements) to make the PR more understandable without external context.
✅ Passed checks (3 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ 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 ll/openapi-small-fixes

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


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

Caution

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

⚠️ Outside diff range comments (1)
apps/ensapi/src/handlers/api/explore/name-tokens-api.routes.ts (1)

43-43: ⚠️ Potential issue | 🟠 Major

Remove "Explore" tag references from routes or restore tag definition in openapi-meta.ts.

The "Explore" tag is referenced in this route (and others) but is no longer defined in apps/ensapi/src/openapi-meta.ts. The tag definitions were removed from the OpenAPI metadata (only "Resolution" and "Meta" tags remain), but the routes still reference undefined tags. This will cause OpenAPI spec generation to fail or produce invalid references.

Either:

  1. Restore the tag definitions for "Explore" and "ENSAwards" in openapi-meta.ts, or
  2. Remove these tag references from:
    • apps/ensapi/src/handlers/api/explore/name-tokens-api.routes.ts (line 43)
    • apps/ensapi/src/handlers/api/explore/registrar-actions-api.routes.ts (lines 97, 137)
    • apps/ensapi/src/handlers/ensanalytics/ensanalytics-api.routes.ts (lines 58, 87, 117, 145)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@apps/ensapi/src/handlers/api/explore/name-tokens-api.routes.ts` at line 43,
The OpenAPI tag "Explore" referenced by the route metadata (e.g., the tags:
["Explore"] entry in name-tokens-api.routes.ts) is missing from openapi-meta.ts
and causes invalid spec generation; fix this by either restoring the missing tag
definitions ("Explore" and "ENSAwards") in apps/ensapi/src/openapi-meta.ts with
the same shape as the existing "Resolution"/"Meta" tags, or remove the tag
references from the affected route metadata (remove "Explore" / "ENSAwards"
entries in the tags arrays found in name-tokens-api.routes.ts,
registrar-actions-api.routes.ts, and ensanalytics-api.routes.ts as noted in the
review) so every route only references tags defined in openapi-meta.ts.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@apps/ensapi/src/handlers/api/explore/name-tokens-api.routes.ts`:
- Line 43: The OpenAPI tag "Explore" referenced by the route metadata (e.g., the
tags: ["Explore"] entry in name-tokens-api.routes.ts) is missing from
openapi-meta.ts and causes invalid spec generation; fix this by either restoring
the missing tag definitions ("Explore" and "ENSAwards") in
apps/ensapi/src/openapi-meta.ts with the same shape as the existing
"Resolution"/"Meta" tags, or remove the tag references from the affected route
metadata (remove "Explore" / "ENSAwards" entries in the tags arrays found in
name-tokens-api.routes.ts, registrar-actions-api.routes.ts, and
ensanalytics-api.routes.ts as noted in the review) so every route only
references tags defined in openapi-meta.ts.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: dd3392ad-374f-4ae8-933c-9cdcf874ca0c

📥 Commits

Reviewing files that changed from the base of the PR and between dd1e72f and eaf9e07.

📒 Files selected for processing (7)
  • apps/ensapi/src/handlers/api/explore/name-tokens-api.routes.ts
  • apps/ensapi/src/handlers/api/meta/realtime-api.routes.ts
  • apps/ensapi/src/handlers/api/meta/status-api.routes.ts
  • apps/ensapi/src/handlers/ensapi-probes/ensapi-probes-api.routes.ts
  • apps/ensapi/src/openapi-document.ts
  • apps/ensapi/src/openapi-meta.ts
  • docs/ensnode.io/ensapi-openapi.json

Copy link
Copy Markdown
Member

@lightwalker-eth lightwalker-eth left a comment

Choose a reason for hiding this comment

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

@sevenzing Looks good, thanks!

Comment thread apps/ensapi/src/openapi-meta.ts Outdated
Comment thread apps/ensapi/src/openapi-meta.ts Outdated
Comment thread apps/ensapi/src/openapi-document.ts
@vercel vercel Bot temporarily deployed to Preview – ensnode.io May 8, 2026 17:47 Inactive
@vercel vercel Bot temporarily deployed to Preview – ensrainbow.io May 8, 2026 17:47 Inactive
@vercel vercel Bot temporarily deployed to Preview – admin.ensnode.io May 8, 2026 17:47 Inactive
@vercel vercel Bot temporarily deployed to Preview – ensnode.io May 8, 2026 17:47 Inactive
@vercel vercel Bot temporarily deployed to Preview – ensrainbow.io May 8, 2026 17:47 Inactive
@vercel vercel Bot temporarily deployed to Preview – admin.ensnode.io May 8, 2026 17:47 Inactive
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