get_last_events
Pack: sports · Endpoint: https://gateway.pipeworx.io/sports/mcp
Get the last 15 events/matches played by a team. Returns event name, date, home team, away team, scores, and league.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
team_id | string | yes | TheSportsDB team ID (e.g., “133604” for Arsenal) |
Example call
Arguments
{
"team_id": "133604"
}
curl
curl -X POST https://gateway.pipeworx.io/sports/mcp \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"get_last_events","arguments":{"team_id":"133604"}}}'
TypeScript (@pipeworx/sdk)
import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();
const result = await pipeworx.call('get_last_events', {
"team_id": "133604"
});
More examples
{
"team_id": "133602"
}
Response shape
Always returns: team_id, total, events
| Field | Type | Description |
|---|---|---|
team_id | string | TheSportsDB team ID |
total | integer | Total number of last events |
events | array | Last 15 events/matches played by the team |
Full JSON Schema
{
"type": "object",
"properties": {
"team_id": {
"type": "string",
"description": "TheSportsDB team ID"
},
"total": {
"type": "integer",
"description": "Total number of last events"
},
"events": {
"type": "array",
"description": "Last 15 events/matches played by the team",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Event ID"
},
"name": {
"type": "string",
"description": "Event name"
},
"date": {
"type": [
"string",
"null"
],
"description": "Event date"
},
"home_team": {
"type": [
"string",
"null"
],
"description": "Home team name"
},
"away_team": {
"type": [
"string",
"null"
],
"description": "Away team name"
},
"home_score": {
"type": [
"string",
"integer",
"null"
],
"description": "Home team score"
},
"away_score": {
"type": [
"string",
"integer",
"null"
],
"description": "Away team score"
},
"league": {
"type": [
"string",
"null"
],
"description": "League name"
}
},
"required": [
"id",
"name"
]
}
}
},
"required": [
"team_id",
"total",
"events"
]
}
Connect
Add this to your MCP client config, or use one-click install buttons:
{
"mcpServers": {
"sports": {
"url": "https://gateway.pipeworx.io/sports/mcp"
}
}
}
See Getting Started for client-specific install steps.