Skip to main content
Glama

List member candidates

well_list_member_candidates
Read-only

List the teammates a workspace can invite, exactly as the Well app's invite card shows them. Use it before well_invite_members, and for "who can I invite to this workspace?".

Returns candidates, each with person_id, name, email, avatar_url, a state (active already has access, pending was invited and has not accepted, not_member can be invited), a source (detected was computed from the workspace's own people, provided was named in person_ids or resolved from the assigned gap owners), and a reason on a detected row: same_email_domain when they share the owner's corporate email domain, seen_in_two_tools when they appear in two or more of the workspace's connected internal tools and in no other company, which is the signal an owner on a personal address has instead of a shared domain. A provided row carries no reason. Never invite a candidate whose state is active. Alongside them it returns targets — this workspace plus any workspace group you belong to, each an option for where the invite lands — roles (admin or member, with a hint), and me_person_id so you never offer to invite the caller. On a demo workspace, which holds sample data, candidates and targets are empty and refusal_reason is DEMO_WORKSPACE: tell the user to invite the team in their own workspace.

Three ways to source the candidates:

  • Default: the detected teammates who hold no membership, each with its reason.

  • person_ids: resolve specific people you already hold the ids for, with their membership state. Set include_detected false to return only those.

  • from_assigned_gaps: true: resolve the owners of the settled expense transactions still missing a supplier invoice for the period, server-side, with their membership state — the invite step of a close or fetch flow uses this so it never depends on remembering who was assigned on the owner card. It returns only those owners (the detected teammates are omitted). Name the period ONE way — { calendar_year, calendar_month } or { fiscal_year, fiscal_period } — or name no period to use the months selected on the period card this session. Every month must have ended.

⚠️ This tool draws its invite card on EVERY call, the empty one included. When the user asks who they can invite, call it directly: the card, with its contact search, is the answer. But in the invite step of a close or missing-invoice flow, where you read with from_assigned_gaps: true only to find out whether an owner of the period's gaps still needs an invitation, call well_get_worklist_status({ worklist: "gap_owners_to_invite" }) first, with the same period you would pass here or none for this conversation's selected months. It draws nothing, and its count is how many of those owners are pending or not_member. Make the from_assigned_gaps call only when that count is above zero. A solo workspace whose owner assigned the gaps to themselves answers 0: nobody is left to invite, so no card is drawn. An ABSENT count is not a zero: success: false means the probe could not read the owners.

⚠️ WAIT ON THE CARD IN THE TURN THAT DREW IT. Write your one line for the user FIRST, then call well_wait_for_selection({ kind: "invite_ack" }), which this result's next_step also states. The card's own footer sends the invitations and writes the acknowledgement, so never call well_invite_members yourself after a click. The outcome the click carries says which button it was: "done" sent the invitations, "keep_for_later" set the step aside. Both end the step.

When the token authorizes one workspace, call this directly — no workspace call is needed first. When it authorizes several, this read will not guess which one you mean: pass workspace_id on the call.

Input Schema

NameRequiredDescriptionDefault
person_idsNoPerson ids to resolve with their membership state (the `provided` source).
fiscal_yearNoFiscal year (the calendar year the workspace's fiscal year STARTED in). `from_assigned_gaps` only.
workspace_idNoTarget workspace. Omit when the token authorizes one workspace. Required when it authorizes several: this read reports one workspace's own figures and will not choose which.
calendar_yearNoCalendar year, e.g. 2026. `from_assigned_gaps` only.
fiscal_periodNoFiscal period, 1-12. `from_assigned_gaps` only, paired with `fiscal_year`. The adjustment period (13) is refused.
calendar_monthNoCalendar month, 1 = January … 12 = December. `from_assigned_gaps` only, paired with `calendar_year`.
conversation_idNoThe conversation id returned by the previous Well result, in its meta under well/conversation_id, in its structuredContent, or in its JSON text block. Pass it back on every call in the same conversation, including a call a card makes, so the chosen workspace and the earlier answers still apply. It decides the conversation on its own: nothing the host states about the session replaces it. Omit it only on the first call of a conversation.
workspace_scopeNoRestrict this call to the family: the token's primary workspace plus the company workspaces under it that you are a member of. Unrelated authorized workspaces drop out of the read; row reads merge across the family, while a per-workspace figure still reports exactly one workspace.
include_detectedNoOmit the detected same-domain teammates when false. Defaults to true.
from_assigned_gapsNoResolve the candidates from the owners of the period's missing-invoice gaps, server-side, instead of `person_ids`. The detected teammates are omitted, and `include_detected` is treated as false.

Output Schema

NameRequiredDescriptionDefault
errorNo
rolesYesThe assignable roles, `admin` or `member`, each with a one-line hint.
successYes
targetsYesWhere an invite can land: this workspace, plus any workspace group the caller belongs to.
next_stepNoWhat to do with the card this result renders. Added by the dispatcher when the card asks for a click.
candidatesYes
me_person_idYesThe caller's own person id, so the card never offers to invite them.
workspace_idNo
refusal_reasonNoPresent only when the workspace refuses team invites. DEMO_WORKSPACE: the workspace holds sample data, so `candidates` and `targets` are empty on purpose. Tell the user to invite the team in their own workspace.
conversation_idNoThe conversation this result belongs to. Pass it back as the conversation_id argument on every later Well call in the same conversation.
newly_connectedNoTools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. The connected-line rule says when to tell an entry; when it does, one line per entry, in the person's language: "<name> is connected.". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later.
resolved_workspaceNoThe workspace that answered, when the caller named none and the token authorizes several.
conversation_id_noteNoPresent only when the server opened a fresh lane, stating that no choice recorded earlier was read.
conversation_id_sourceNoWhere the conversation id came from: the host's own request meta, the caller's argument, or a fresh lane the server opened.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedOutput schema / properties / candidates / items / properties / reason
      Added value: +{
      +  "anyOf": [
      +    {
      +      "enum": [
      +        "same_email_domain",
      +        "seen_in_two_tools"
      +      ],
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Why this person is offered, as a typed value you word yourself. `same_email_domain`: they share the owner's corporate email domain. `seen_in_two_tools`: they appear in two or more of the workspace's connected internal tools and in no other company, which is the signal an owner on a personal address has. Null on a `provided` row."
      +}
    • changedOutput schema / properties / candidates / items / properties / source / description
      Previous value: -"`detected` shares the workspace owner's email domain; `provided` was named by the caller's person_ids."New value: +"`detected` was computed from the workspace's own people and carries a `reason`; `provided` was named by the caller's person_ids."
    • changedOutput schema / properties / candidates / items / required
      Previous value: -[
      -  "person_id",
      -  "name",
      -  "email",
      -  "avatar_url",
      -  "state",
      -  "source",
      -  "invite_expires_at"
      -]New value: +[
      +  "person_id",
      +  "name",
      +  "email",
      +  "avatar_url",
      +  "state",
      +  "source",
      +  "invite_expires_at",
      +  "reason"
      +]
  2. Changed10 schema fields changed
    • removedOutput schema / properties / candidates / items / properties / avatar_url / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / candidates / items / properties / avatar_url / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / candidates / items / properties / invite_expires_at / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / candidates / items / properties / invite_expires_at / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / me_person_id / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / me_person_id / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / resolved_workspace / properties / name / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / resolved_workspace / properties / name / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / targets / items / properties / workspace_count / anyOf
      Removed value: -[
      -  {
      -    "type": "number"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / targets / items / properties / workspace_count / type
      Added value: +[
      +  "number",
      +  "null"
      +]
  3. Changed1 schema field changed
    • changedOutput schema / properties / newly_connected / description
      Previous value: -"Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. Start the reply with one line per entry, in the person's language: \"<name> is connected.\". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later."New value: +"Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. The connected-line rule says when to tell an entry; when it does, one line per entry, in the person's language: \"<name> is connected.\". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later."
  4. Changed1 schema field changed
    • addedInput schema / properties / workspace_scope
      Added value: +{
      +  "description": "Restrict this call to the family: the token's primary workspace plus the company workspaces under it that you are a member of. Unrelated authorized workspaces drop out of the read; row reads merge across the family, while a per-workspace figure still reports exactly one workspace.",
      +  "enum": [
      +    "family"
      +  ],
      +  "type": "string"
      +}
  5. Changed1 schema field changed
    • addedOutput schema / properties / newly_connected
      Added value: +{
      +  "description": "Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. Start the reply with one line per entry, in the person's language: \"<name> is connected.\". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later.",
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "name": {
      +        "type": "string"
      +      },
      +      "service_id": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "service_id"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  6. Changed1 schema field changed
    • addedOutput schema / properties / refusal_reason
      Added value: +{
      +  "const": "DEMO_WORKSPACE",
      +  "description": "Present only when the workspace refuses team invites. DEMO_WORKSPACE: the workspace holds sample data, so `candidates` and `targets` are empty on purpose. Tell the user to invite the team in their own workspace.",
      +  "type": "string"
      +}
  7. Changed4 schema fields changed
    • addedInput schema / properties / conversation_id
      Added value: +{
      +  "description": "The conversation id returned by the previous Well result, in its meta under well/conversation_id, in its structuredContent, or in its JSON text block. Pass it back on every call in the same conversation, including a call a card makes, so the chosen workspace and the earlier answers still apply. It decides the conversation on its own: nothing the host states about the session replaces it. Omit it only on the first call of a conversation.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / conversation_id
      Added value: +{
      +  "description": "The conversation this result belongs to. Pass it back as the conversation_id argument on every later Well call in the same conversation.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / conversation_id_note
      Added value: +{
      +  "description": "Present only when the server opened a fresh lane, stating that no choice recorded earlier was read.",
      +  "type": "string"
      +}
    • addedOutput schema / properties / conversation_id_source
      Added value: +{
      +  "description": "Where the conversation id came from: the host's own request meta, the caller's argument, or a fresh lane the server opened.",
      +  "enum": [
      +    "host_meta",
      +    "argument",
      +    "minted"
      +  ],
      +  "type": "string"
      +}
  8. Changed1 schema field changed
    • addedOutput schema / properties / next_step
      Added value: +{
      +  "description": "What to do with the card this result renders. Added by the dispatcher when the card asks for a click.",
      +  "type": "string"
      +}
  9. Changed5 schema fields changed
    • addedInput schema / properties / calendar_month
      Added value: +{
      +  "description": "Calendar month, 1 = January … 12 = December. `from_assigned_gaps` only, paired with `calendar_year`.",
      +  "maximum": 12,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / calendar_year
      Added value: +{
      +  "description": "Calendar year, e.g. 2026. `from_assigned_gaps` only.",
      +  "maximum": 2100,
      +  "minimum": 2000,
      +  "type": "integer"
      +}
    • addedInput schema / properties / fiscal_period
      Added value: +{
      +  "description": "Fiscal period, 1-12. `from_assigned_gaps` only, paired with `fiscal_year`. The adjustment period (13) is refused.",
      +  "maximum": 13,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / fiscal_year
      Added value: +{
      +  "description": "Fiscal year (the calendar year the workspace's fiscal year STARTED in). `from_assigned_gaps` only.",
      +  "maximum": 2100,
      +  "minimum": 2000,
      +  "type": "integer"
      +}
    • addedInput schema / properties / from_assigned_gaps
      Added value: +{
      +  "description": "Resolve the candidates from the owners of the period's missing-invoice gaps, server-side, instead of `person_ids`. The detected teammates are omitted, and `include_detected` is treated as false.",
      +  "type": "boolean"
      +}
  10. Added

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Despite readOnly/non-destructive annotations, the description adds rich behavior beyond them: the tool draws an invite card on every call including empties, the demo-workspace refusal with DEMO_WORKSPACE reason, the requirement to wait on well_wait_for_selection and never call well_invite_members after a click, and the multi-workspace workspace_id constraint. This is substantive, non-obvious operational context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose and return shape are front-loaded, then sourcing options, then warnings, so it reads in priority order. It is long and dense, but nearly every sentence adds decision-relevant detail; only minor tightening seems possible.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers everything an agent needs for a 10-param, complex tool: return fields with state/source/reason semantics, demo refusal, multi-workspace disambiguation, the card/selection handshake, and the empty-card case. Any residual return detail is backed by the output schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 100% schema coverage the baseline is 3, but the description adds real meaning: it explains the three sourcing paths that map to person_ids vs from_assigned_gaps vs default, that include_detected is forced false under from_assigned_gaps, and the 'name the period ONE way' rule for calendar/fiscal params. This meaningfully exceeds what the schema properties convey.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('List the teammates a workspace can invite') and anchors it to the invite card the app renders. It distinguishes itself from well_invite_members and clarifies the exact user question it answers, so an agent can select it without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly says to use it before well_invite_members and for 'who can I invite to this workspace?', enumerates three sourcing modes with when-to-use conditions, and routes the gap-owner case through well_get_worklist_status first with a count>0 gate. Exclusions and alternatives are fully spelled out.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources