post_memberships_invitations_by_orgid_accept

Changes data · you confirm first

Calls POST /api/memberships/invitations/{orgId}/accept as the signed-in person · REST reference

Accept the signed-in user's invitation from an organization

Every membership the invitation names becomes granting, and the caller joins the organization's MEMBER group. Only the invitee can accept — the DAL takes the invitee from the caller's own session. 404 when the caller holds no pending invitation from that organization (none was sent, it was already answered, or it was taken back).

Arguments

ArgumentTypeDescription
orgIdpathstring (uuid)required

Example call

A client sends this over the MCP session; Claude and other agents build it for you. The values are placeholders — the shape is real.

json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "post_memberships_invitations_by_orgid_accept",
    "arguments": {
      "orgId": "11111111-1111-4111-8111-111111111111"
    }
  }
}
Confirmation
The client shows the person the exact request and waits. Nothing runs until they tick Make this change. See Reading and changing.

Result

On success (HTTP 200) the tool returns one text item holding the API's JSON, pretty-printed.

Accepted — the caller is now a member.

json
{
  "data": {
    "groupIds": [
      "11111111-1111-4111-8111-111111111111"
    ],
    "orgId": "11111111-1111-4111-8111-111111111111",
    "status": "INVITED"
  },
  "success": true
}

Fields

FieldTypeDescription
dataobject
data.groupIdsarray of string (uuid)
data.orgIdstring (uuid)
data.status"INVITED" | "REQUESTED" | "ACCEPTED" | "APPROVED" | "ACTIVE" | "DECLINED" | … (8 values)The status the memberships carry now.
successtrue

When it fails

A failed call returns isError: true with the API's message as text. A change the person declines, or lets time out, also comes back this way and nothing changes.

400

The request was malformed or failed a guard.

403

The DAL refused the caller.

404

No such resource — or none this caller may see.

409

The organization is not accepting members.

What the model is shown

This is the tool exactly as the server lists it in tools/list. The description starts with the REST call it makes.

json
{
  "name": "post_memberships_invitations_by_orgid_accept",
  "description": "POST /api/memberships/invitations/{orgId}/accept — Every membership the invitation names becomes granting, and the caller joins the organization's MEMBER group. Only the invitee can accept — the DAL takes the invitee from the caller's own session. 404 when the caller holds no pending invitation from that organization (none was sent, it was already answered, or it was taken back).\n\nThis changes data. The person is asked to confirm it before it runs, and nothing happens if they decline.",
  "inputSchema": {
    "type": "object",
    "properties": {
      "orgId": {
        "type": "string"
      }
    },
    "required": [
      "orgId"
    ]
  },
  "annotations": {
    "readOnlyHint": false,
    "destructiveHint": true,
    "idempotentHint": false,
    "openWorldHint": false
  }
}