Skip to main content
Glama

Get the referral link

well_get_referral_code
Read-only

Return the workspace's referral link and how many people joined Well with it. Use it when the user asks for their referral link, their sponsorship link ("mon lien de parrainage"), or how many people signed up through it.

Reads only. has_link: false means the workspace has no referral link yet: make it with well_create_referral_code, then answer. people_joined counts people, not workspaces, and last_joined_at dates the latest. A demo workspace has no link (refusal: DEMO_WORKSPACE).

The referral link lets someone open their OWN account on Well and counts them for this workspace; it gives no access to the workspace. For a link that lets someone join this workspace, use well_get_workspace_invite_link.

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

Output Schema

NameRequiredDescriptionDefault
errorNo
refusalNoPresent only when the call did nothing. DEMO_WORKSPACE: the workspace holds sample data, so it has no referral link. INSUFFICIENT_PERMISSIONS: only an owner or admin, or the member who made the link, may stop it.
successYes
has_linkNoFalse when the workspace has no referral link yet: make it with well_create_referral_code.
workspace_idNo
people_joinedNoHow many people joined Well with this link: the people in the workspaces it brought in. Derived on each call; 0 when nobody did yet. Null when the count could not be read in time: give the link and say the count is not available right now, never 0.
referral_linkNoThe workspace's referral link. Anyone who opens it and signs up to Well counts for this workspace; it gives no access to the workspace. Give it to the user exactly as returned, alone on its line.
last_joined_atNoWhen the latest person joined with the link (ISO 8601), or null when nobody did yet.
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.
people_joined_cappedNoTrue when the link brought in more workspaces than one count reads, so people_joined is a floor.
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. Changed4 schema fields changed
    • removedOutput schema / properties / last_joined_at / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / last_joined_at / 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"
      +]
  2. Added

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already declare readOnlyHint and non-destructive, and the description still adds real behavior: the DEMO_WORKSPACE refusal, the has_link:false state and what to do about it, the fact that people_joined counts people not workspaces, and that this read will not guess a workspace. That is exactly the beyond-annotation context the score rewards.

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?

Front-loaded with purpose, then behavior, then alternatives, then multi-workspace routing — a sane ordering with each paragraph doing a distinct job. It runs long and repeats the workspace_id rule that the schema already carries, costing a point, but no sentence is pure filler.

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

Completeness4/5

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

Output schema exists, so return values need not be explained, yet the description still clarifies the meaning of people_joined, last_joined_at, has_link, and the refusal code. The only gap is that conversation_id and workspace_scope — which affect multi-turn correctness — are left entirely to the schema.

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

Parameters3/5

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

Schema description coverage is 100%, so both the workspace_id omission/requirement rule and the conversation_id and workspace_scope semantics are already documented in the schema; the description's workspace_id guidance largely restates it. The description adds nothing on conversation_id or the family scope, so it does not exceed the baseline for a fully documented schema.

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?

First sentence names the exact resource (the workspace's referral link) and the secondary figure (how many people joined with it). It also explicitly contrasts with well_get_workspace_invite_link and well_create_referral_code, so an agent can distinguish it from its closest siblings without opening a 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?

States triggering user phrasings (referral link, sponsorship link, "mon lien de parrainage"), the recovery path when has_link is false (call well_create_referral_code), and the redirect to well_get_workspace_invite_link for the adjacent need. It also tells the agent when to pass workspace_id versus calling directly, which is a routing rule, not just a hint.

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