Skip to main content
Glama

Swap a person on a shift

swap_shift_recipient
Destructive

Replace one live person on a shift with another in one request. The replacement is added first and gets the offer email with the outgoing person's days; then the outgoing person is removed and gets a cancellation. Give remove_user_id and exactly one of add_user_id (an org member) or add_person (first_name, email, and optional phone, consent and company). A PENDING or STANDBY person needs gig-operations access; removing an accepted person needs finance access. If the add lands but the removal fails the response is SWAP_PARTIAL with both ids, so no seat is lost. Refused with 409 GIG_ROSTER_LOCKED on a completed and settled gig: reopen_event first. Confirmation-gated: it messages two people.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "offer_id": "<offer_id>",
      "remove_user_id": "<remove_user_id>"
    },
    "name": "swap_shift_recipient"
  }
}

Input Schema

NameRequiredDescriptionDefault
feeNothe replacement pay, in dollars
offer_idYescrew offer id from list_crew_offers
copy_daysNodefault true: the replacement takes the outgoing person's days
add_personNoa person without an account taking the seat
add_user_idNouser_id (from list_org_members) of the org member taking the seat
remove_user_idYesthe person coming off the shift
organization_idNoorganization to act in, an id from get_me; omit to use your active organization
confirmation_tokenNoleave empty on the first call; the server returns confirmation_required + a token, then resend the SAME args with that token to proceed

Output Schema

NameRequiredDescriptionDefault
okYestrue on success (including confirmation_required prompts)
dataNowhen the tool asks first: { status: "confirmation_required", confirmation_token, summary, expires_in_seconds, instructions } and nothing is changed; once confirmed, the API response { status (HTTP status), data: { recipient_drafts [{ user_id, fee, username, email, shift_overlaps }], calllist_id, created_by_id, currency, date, days [{ accepted_count, capacity, date, effective_end_time, effective_fee, effective_start_time, end_time, fee, and 4 more fields }], description, end_time, event_id, event_status, event_title, event_type, event_timezone, expires_at, fee, fee_type, id, kind, and 11 more fields } }
errorNowhen ok is false

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already flag destructive and non-idempotent, yet the description adds substantial behavior the annotations cannot: the add-before-remove ordering, the two notification emails each party receives, the SWAP_PARTIAL failure mode that preserves the seat, and the access-level requirements per person state. It also discloses the confirmation gate that messages two people, which is exactly the pre-call warning an agent needs.

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

Conciseness5/5

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

Front-loaded with the operation, then parameter rules, then access requirements, then failure modes, then the confirmation gate — a logical call-preparation order. Sentences are dense but every one carries information not available in the schema or annotations.

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?

Despite 8 parameters, a nested object, and a mutation with side effects, an agent has what it needs: required inputs, the exclusivity rule, permission gates, partial-failure semantics, and the confirmation-token flow. With an output schema present, no return-value explanation is owed.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds a constraint the schema does not encode: exactly one of add_user_id or add_person must be supplied (the schema enforces neither). It also clarifies that add_user_id must be an org member, that add_person carries first_name/email plus optional phone, consent and company, and that copy_days defaults to true.

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 — replacing one live person on a shift with another — plus the atomic framing ('in one request') and the ordered add-then-remove semantics. That ordering is what separates it from a plain removal or an update tool, so an agent can identify the operation without consulting siblings.

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

Usage Guidelines4/5

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

Gives clear preconditions (exactly one of add_user_id or add_person; org membership for the replacement) and an explicit escape hatch when blocked: 'reopen_event first' on 409 GIG_ROSTER_LOCKED. It stops short of naming sibling alternatives for the non-atomic path, so it is strong rather than exhaustive.

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.