[GH-ISSUE #2593] Organizations: getFullOrganization() has incorrect example in docs. #9268

Closed
opened 2026-04-13 04:41:35 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @elansx on GitHub (May 9, 2025).
Original GitHub issue: https://github.com/better-auth/better-auth/issues/2593

Currently in docs we have this:

const organization = await authClient.organization.getFullOrganization({
    organizationId: "organization-id" // optional, by default it will use the active organization
})
//you can also use organizationSlug instead of organizationId
const organization = await authClient.organization.getFullOrganization({
    organizationSlug: "organization-slug"
})

This doesn't work, but this works:

const organization = await authClient.organization.getFullOrganization({
    query: { organizationId: "organization-id" } // optional, by default it will use the active organization
})
//you can also use organizationSlug instead of organizationId
const organization = await authClient.organization.getFullOrganization({
    query: { organizationSlug: "organization-slug" }
})
Originally created by @elansx on GitHub (May 9, 2025). Original GitHub issue: https://github.com/better-auth/better-auth/issues/2593 Currently in [docs ](https://www.better-auth.com/docs/plugins/organization) we have this: ``` const organization = await authClient.organization.getFullOrganization({ organizationId: "organization-id" // optional, by default it will use the active organization }) //you can also use organizationSlug instead of organizationId const organization = await authClient.organization.getFullOrganization({ organizationSlug: "organization-slug" }) ``` This doesn't work, **but this works**: ``` const organization = await authClient.organization.getFullOrganization({ query: { organizationId: "organization-id" } // optional, by default it will use the active organization }) //you can also use organizationSlug instead of organizationId const organization = await authClient.organization.getFullOrganization({ query: { organizationSlug: "organization-slug" } }) ```
GiteaMirror added the locked label 2026-04-13 04:41:35 -05:00
Author
Owner

@leebenson commented on GitHub (Sep 5, 2025):

This was closed and merged in #2626 as completed, but docs are still displaying the old example:

https://www.better-auth.com/docs/plugins/organization#get-full-organization

<!-- gh-comment-id:3258443017 --> @leebenson commented on GitHub (Sep 5, 2025): This was closed and merged in #2626 as completed, but docs are still displaying the old example: https://www.better-auth.com/docs/plugins/organization#get-full-organization
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#9268