Reference to Non-Existent Client-Side Function for Organization Plugin's addMember() #2266

Closed
opened 2026-03-13 09:39:43 -05:00 by GiteaMirror · 2 comments
Owner

Originally created by @JeffreyLind3 on GitHub (Nov 6, 2025).

In packages/better-auth/src/plugins/organization/organization.ts, there is a reference to a non-existent authClient.organization.addMember in the docstring:

/**
 * ### Endpoint
 *
 * POST `/organization/add-member`
 *
 * ### API Methods
 *
 * **server:**
 * `auth.api.addMember`
 *
 * **client:**
 * `authClient.organization.addMember`
 *
 * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/organization#api-method-organization-add-member)
 */

addMember: addMember<O>(options as O),
Originally created by @JeffreyLind3 on GitHub (Nov 6, 2025). In `packages/better-auth/src/plugins/organization/organization.ts`, there is a reference to a non-existent `authClient.organization.addMember` in the docstring: ```typescript /** * ### Endpoint * * POST `/organization/add-member` * * ### API Methods * * **server:** * `auth.api.addMember` * * **client:** * `authClient.organization.addMember` * * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/organization#api-method-organization-add-member) */ addMember: addMember<O>(options as O), ```
GiteaMirror added the bug label 2026-03-13 09:39:43 -05:00
Author
Owner

@better-auth-agent[bot] commented on GitHub (Nov 6, 2025):

(tag @better-auth-agent if you would like an answer from the Agent)

DiagramDiscordGitHub

Diagram Join Star

@better-auth-agent[bot] commented on GitHub (Nov 6, 2025): (tag @better-auth-agent if you would like an answer from the Agent) <!-- bot:webhook reply v1 --> [Diagram](https://repodiagrams.s3.eu-north-1.amazonaws.com/better-auth_ultra_detailed_interactive.html) • [Discord](https://discord.gg/better-auth) • [GitHub](https://github.com/better-auth/better-auth) [![Diagram](https://img.shields.io/badge/Diagram-2b3137?style=flat-square)](https://repodiagrams.s3.eu-north-1.amazonaws.com/better-auth_ultra_detailed_interactive.html) [![Join](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&style=flat-square)](https://discord.gg/better-auth) [![Star](https://img.shields.io/badge/star-181717?logo=github&logoColor=white&style=flat-square)](https://github.com/better-auth/better-auth)
Author
Owner

@dosubot[bot] commented on GitHub (Nov 6, 2025):

The reference to authClient.organization.addMember in the docstring is incorrect—there is no such client-side function implemented in the codebase, even though the server-side auth.api.addMember exists and is documented. This appears to be a documentation error or a missing feature, as similar issues have been reported for other organization plugin methods that are documented but not actually available on the client side. The intended way to add members currently is via the server-side API only, and there is no direct client-side alternative or wrapper for this operation at this time citation citation.

To reply, just mention @dosu.


How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Chat with Dosu Join Discord Share on X

@dosubot[bot] commented on GitHub (Nov 6, 2025): <!-- Answer --> The reference to `authClient.organization.addMember` in the docstring is incorrect—there is no such client-side function implemented in the codebase, even though the server-side `auth.api.addMember` exists and is documented. This appears to be a documentation error or a missing feature, as similar issues have been reported for other organization plugin methods that are documented but not actually available on the client side. The intended way to add members currently is via the server-side API only, and there is no direct client-side alternative or wrapper for this operation at this time [citation](https://github.com/better-auth/better-auth/issues/3304) [citation](https://github.com/better-auth/better-auth/issues/2309). <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/cc722bf4-c711-40c6-b29c-cc71300b32b4?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/cc722bf4-c711-40c6-b29c-cc71300b32b4?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/cc722bf4-c711-40c6-b29c-cc71300b32b4?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/cc722bf4-c711-40c6-b29c-cc71300b32b4?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/cc722bf4-c711-40c6-b29c-cc71300b32b4?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/cc722bf4-c711-40c6-b29c-cc71300b32b4?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/cc722bf4-c711-40c6-b29c-cc71300b32b4?feedback_type=other)</sup>&nbsp;&nbsp;[![Chat with Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/cdda13d9-dd27-4d31-b09a-5d8bec92de21/ask?utm_source=github)&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/better-auth/better-auth/issues/5790)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#2266