Examples

End-to-end examples for connecting to the MCP server and invoking tools.

1. Initialize an MCP session

New MCP sessions must send an initialize request first. Most AI clients handle this automatically.

{
  "jsonrpc": "2.0",
  "id": "init-1",
  "method": "initialize",
  "params": {
    "protocolVersion": "2025-03-26",
    "capabilities": {},
    "clientInfo": {
      "name": "curl",
      "version": "1.0.0"
    }
  }
}
curl -s -X POST https://mcp.unduit.com/mcp \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{  "jsonrpc": "2.0",  "id": "init-1",  "method": "initialize",  "params": {    "protocolVersion": "2025-03-26",    "capabilities": {},    "clientInfo": {      "name": "curl",      "version": "1.0.0"    }  }}'

2. Call a tool

After initialization, invoke a tool by name. No Unduit credentials are passed in arguments.

{
  "jsonrpc": "2.0",
  "id": "tool-1",
  "method": "tools/call",
  "params": {
    "name": "unduit_employees_list",
    "arguments": {
      "page": 1
    }
  }
}

3. Tool response shape

Tool results include the upstream HTTP status and response body from the Unduit API:

{
  "status": 200,
  "data": {
    "employees": [],
    "pagination": {
      "currentPage": 1,
      "totalPages": 1
    }
  }
}

Workflow: deployment order

  1. List warehouses — invoke unduit_asset_deployment_warehouses
  2. Check inventory — invoke unduit_asset_deployment_inventory with warehouse_id in query
  3. Place order — invoke unduit_asset_deployment_place_order with order body

In natural language: "List deployment warehouses, show inventory for warehouse QebLm2p7, then place an order for a MacBook Pro."

Workflow: recovery campaign

  1. unduit_recovery_campaign_list — list campaigns
  2. unduit_recovery_campaign_detail — get campaign by number
  3. unduit_recovery_initiate — add employee to campaign
  4. unduit_recovery_detail — track recovery status

Using endpoint_override

Call any documented endpoint by passing an explicit path override:

{
  "name": "unduit_employees_list",
  "arguments": {
    "endpoint_override": "/api/v1/employees/1234567-42"
  }
}

Note: for GET-by-ID endpoints, prefer the dedicated tool (e.g. unduit_employees_get) when available.