Skip to content

Generate backend docs#3445

Merged
alexisintech merged 34 commits into
mainfrom
aa/DOCS-10984
Jun 30, 2026
Merged

Generate backend docs#3445
alexisintech merged 34 commits into
mainfrom
aa/DOCS-10984

Conversation

@alexisintech

@alexisintech alexisintech commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

⚠️ clerk/javascript#8853 must be shipped first

To test:

  • pull docs(backend,shared): Generate typedoc output for backend docs javascript#8853
  • run pnpm run typedoc:generate:skip-build (as long as you have clerk-docs and clerk/javascript symlinked; see the clerk/clerk README.md)
  • run the docs (in clerk/clerk, run pnpm run dev)
  • preview the docs locally. I like to split screen with the current production docs on one side, and the local preview of these changes on the other side, and then manually compare to ensure all the information in the newly generated docs are accurate.

What does this solve? What changed?

Generates the Backend reference docs from Typedoc. Across every Backend API resource, hand-written ## Properties / ## Parameters / ## Returns tables and ## Example(s) sections were replaced with <Typedoc /> includes, and the sidebar was restructured to group methods by resource.

Sidebar restructure

  • Sidebar entries alphabetized.
  • Backend prefix removed from titles in the Types section.

New pages — Backend methods

  • docs/reference/backend/api-keys/get-secret.mdx
  • docs/reference/backend/domains/{add,delete,list,update}.mdx
  • docs/reference/backend/enterprise-connections/{create,delete,get,get-list,update}-enterprise-connection.mdx
  • docs/reference/backend/organization/create-organization-domain.mdx
  • docs/reference/backend/organization/delete-organization-domain.mdx
  • docs/reference/backend/organization/get-organization-domain-list.mdx
  • docs/reference/backend/organization/update-organization-domain.mdx
  • docs/reference/backend/organization/get-instance-organization-membership-list.mdx
  • docs/reference/backend/organization/replace-organization-metadata.mdx
  • docs/reference/backend/user/replace-user-metadata.mdx
  • docs/reference/backend/user/set-password-compromised.mdx
  • docs/reference/backend/user/unset-password-compromised.mdx

New pages — Backend types

  • docs/reference/backend/types/backend-agent-task.mdx
  • docs/reference/backend/types/backend-m2m-token.mdx
  • docs/reference/backend/types/backend-machine.mdx
  • docs/reference/backend/types/backend-machine-scope.mdx
  • docs/reference/backend/types/backend-organization-domain.mdx
  • docs/reference/backend/types/backend-sign-in-token.mdx
  • docs/reference/backend/types/backend-testing-token.mdx
  • docs/reference/backend/types/deleted-object.mdx
  • docs/reference/backend/types/domain.mdx

Removed sections

  • PublicOrganizationDataJSON properties section removed from docs/reference/backend/types/backend-organization-invitation.mdx.
  • Hand-authored ## Properties tables removed from Backend type pages (e.g. billing-plan, billing-subscription, billing-subscription-item, feature) — now sourced from Typedoc.

Content updates

  • ## Example(s) headings → ## Usage.
  • "Retrieve" → "get" in method copy for consistency.
  • Inline comment links back to the JS source files removed.
  • Backend reference callout moved under the ## Usage heading.
  • deleteDomain signature aligned with the JS source.

Other doc updates outside docs/reference/backend/

  • docs/reference/objects/organization.mdx — added createOrganizationDomainParams section and attemptOwnershipVerification / prepareOwnershipVerification Typedoc method blocks.
  • docs/reference/types/billing-plan-price.mdx — new BillingPlanPrice type page (linked from the manifest under Types).
  • docs/guides/development/testing/overview.mdx — Testing Tokens copy now points at createTestingToken() in addition to the Backend API.
  • docs/_partials/user-object.mdx — small clarification pointing metadata writes at updateUserMetadata().

Deadline

  • No rush.

Other resources

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 16, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
clerk-docs Ready Ready Preview Jun 30, 2026 11:44pm

Request Review

@alexisintech alexisintech changed the title Source backend User reference docs from generated Typedoc Generate backend docs Jun 16, 2026
@SarahSoutoul SarahSoutoul self-assigned this Jun 16, 2026
@alexisintech alexisintech changed the title Generate backend docs Generate backend docs MOTHER PR! Jun 16, 2026
@SarahSoutoul

Copy link
Copy Markdown
Contributor

@alexisintech Left a small docs review - user addressing the following issue.

The examples for setPasswordCompromised() and unsetPasswordCompromised() use the wrong call shape. In their respective pages in the docs, the examples pass a single object like clerkClient.users.setPasswordCompromised({ userId, ... }). But the generated API signature is setPasswordCompromised(userId: string, params) and unsetPasswordCompromised(userId: string). Fixed the code examples to reflect the generated API signature.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: Sarah Soutoul <sarah@clerk.dev>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: Sarah Soutoul <sarah@clerk.dev>
Comment thread docs/reference/backend/domains/delete-domain.mdx Outdated
@SarahSoutoul

SarahSoutoul commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

@alexisintech Retrieve -> get - keep consistency -> Made a small prose consistency pass across the backend get* reference pages to smooth out the new Typedoc-based docs. Mostly, replacing instances of Retrieves/retrieve with Gets/get to be consistent with the rest + standardized usage blurbs like "filtered by the number of results" to clearer phrasing such as "limited to the specified number of results" / "skipping the specified number of results".

I noticed one more thing consistency wise for the method pages that have a layout with Usage and then a Basic heading. Some have the backend usage partial after the Usage heading and some after the Basic heading. To me, it should be after Usage heading as it applies to all examples, but didn't want to do anything to see which way you'd want to go. Regardless, we should make it consistent:

Screenshot 2026-06-19 at 11 06 13 am Screenshot 2026-06-19 at 11 06 24 am

@SarahSoutoul

Copy link
Copy Markdown
Contributor

@alexisintech One thing I noticed is there is a bit of inconsistency with capitalization in the sidebar. For e.g., the following:

  • Enterprise Connections
  • M2M Tokens
  • Waitlist Entries
  • Agent Tasks
    ...and others have the second word capitalized but their pages don't follow that norm like Testing Tokens for e.g., where the page does follow that norm and therefore it makes sense. But then, things like OAuth applications, Email addresses, Phone numbers, etc. have the second word lowercase.

I think we either go with the consistency of having the second word capitalized for all or we capitalize the second word when that's the norm in the doc, what do you think?

Screenshot 2026-06-29 at 5 38 21 pm

Also should User, Organization, Client and Instance be -> Users, Organizations, Clients and Instances to align with the rest?

@alexisintech

Copy link
Copy Markdown
Contributor Author

@alexisintech One thing I noticed is there is a bit of inconsistency with capitalization in the sidebar. For e.g., the following:

  • Enterprise Connections
  • M2M Tokens
  • Waitlist Entries
  • Agent Tasks
    ...and others have the second word capitalized but their pages don't follow that norm like Testing Tokens for e.g., where the page does follow that norm and therefore it makes sense. But then, things like OAuth applications, Email addresses, Phone numbers, etc. have the second word lowercase.

I think we either go with the consistency of having the second word capitalized for all or we capitalize the second word when that's the norm in the doc, what do you think?

Screenshot 2026-06-29 at 5 38 21 pm Also should User, Organization, Client and Instance be -> Users, Organizations, Clients and Instances to align with the rest?

those are Clerk-specific terms, which always get capitalized in the docs
and yes I can update those to be plural to match their resource names!

@SarahSoutoul

SarahSoutoul commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

those are Clerk-specific terms, which always get capitalized in the docs and yes I can update those to be plural to match their resource names!

I don't know if I follow here sorry. If Enterprise Connections and Agent Tasks are Clerk-specific terms, they don't seem to be capitalized in the docs? And then I can see Waitlist Entries and M2M Tokens were changed so that's all good / makes sense. @alexisintech

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Alexis Aguilar <98043211+alexisintech@users.noreply.github.com>
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ TypeDoc files detected in this PR

This PR modifies files in the 'clerk-typedoc/' folder. These files are auto-generated from the clerk/javascript repository and should not be edited directly.

To make changes to TypeDoc documentation:

  1. 🔄 Make your changes in the appropriate files in the clerk/javascript repository.
  2. 🚀 The TypeDoc documentation will be pulled through to this repository via a CI action.

Thanks for contributing! 🙏

@alexisintech
alexisintech marked this pull request as ready for review June 30, 2026 23:45
@alexisintech
alexisintech requested a review from a team as a code owner June 30, 2026 23:45
@alexisintech
alexisintech merged commit 04acf01 into main Jun 30, 2026
9 checks passed
@alexisintech
alexisintech deleted the aa/DOCS-10984 branch June 30, 2026 23:45
manovotny added a commit that referenced this pull request Jul 3, 2026
The page was added on main by the Typedoc migration (#3445) after this
branch's original change, so it missed the include the other API keys
reference pages received.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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