Naglalathala ang TownSpot ng mga machine-readable discovery documents para sa pampublikong pagtuklas, authenticated event-write workflows, scrape-to-submit MCP tools, at action receipts.
Ang mga kilalang URL na ito ay tumutulong sa mga ahente at integration clients na matuklasan ang mga serbisyo ng TownSpot nang walang hardcoded assumptions.
/.well-known/api-catalog - https://www.townspot.co/.well-known/api-catalog/.well-known/openid-configuration - https://www.townspot.co/.well-known/openid-configuration/.well-known/oauth-protected-resource - https://www.townspot.co/.well-known/oauth-protected-resource/.well-known/mcp/server-card.json - https://www.townspot.co/.well-known/mcp/server-card.jsonKaramihan sa mga ahente ay nangangailangan ng tatlong gawain: maghanap ng mga kaganapan, magsumite ng isang kaganapan mula sa source URL, pagkatapos ay suriin o i-update ang nilikhang kaganapan.
Ipinapakita ng mga endpoint na ito ang pangunahing discovery at event-write surface para sa mga bayan, kaganapan, lugar, MCP scrape-to-submit flows, at action receipts.
https://api.townspot.co/api/locations/listhttps://api.townspot.co/api/locations/get-by-slughttps://api.townspot.co/api/events/listhttps://api.townspot.co/api/submit/eventhttps://api.townspot.co/api/mcp — MCP tools now include submit_event_from_url plus action receipts and idempotency support for write flows.https://api.townspot.co/api/submit/event/{uuid}https://api.townspot.co/api/events/{uuid}/reviewhttps://api.townspot.co/api/p/venues/{slug}https://api.townspot.co/api/openapi.jsonhttps://api.townspot.co/api/healthzhttps://api.townspot.co/api/venue-admin/{slug}/events/{eventUuid}Maghanap ng mga pampublikong kaganapan para sa isang bayan.
GET https://api.townspot.co/api/events/list?zone_id=1&date=2026-05-09
{
"results": [
{
"uuid": "event-uuid",
"title": "Community market",
"startTime": "2026-05-09T10:00:00.000Z",
"venueName": "Town Hall",
"zoneId": 1
}
]
}Magsumite ng kaganapan mula sa source URL sa pamamagitan ng MCP.
POST https://api.townspot.co/api/mcp
Content-Type: application/json
{
"jsonrpc": "2.0",
"id": "submit-1",
"method": "tools/call",
"params": {
"name": "submit_event_from_url",
"arguments": {
"url": "https://example.com/events/community-market",
"idempotencyKey": "community-market-2026-05-09"
}
}
}Suriin ang isang kaganapan gamit ang authenticated request.
GET https://api.townspot.co/api/events/{uuid}/review
Authorization: Bearer {supabaseJwt}
{
"event": {
"uuid": "event-uuid",
"title": "Community market",
"status": "ready_for_review"
},
"actions": ["approve", "edit", "request_more_info"]
}Ang mga protektadong TownSpot admin at venue-manager APIs ay gumagamit ng bearer tokens na inilalabas ng Supabase Auth.
Gamitin ang OpenID Connect at OAuth metadata documents upang programmatically matuklasan ang authorization, token, JWKS, at protected-resource na mga detalye. Maaari ring gamitin ng mga pampublikong submission tools ang event edit tokens, submitter email links, o venue-manage tokens kung saan umiiral na ang daloy na iyon. Maaaring isama ng MCP write tools ang idempotency keys at magbalik ng action receipts upang makapag-retry nang maayos ang mga ahente.
https://www.townspot.co/{countryCode}/{townSlug}https://www.townspot.co/event/{eventSlug}-{eventUuid}https://www.townspot.co/venue/{venueSlug}Upang magamit ang website na ito, pakisang-ayunan ang cookies. Walang masama dito, nakakatulong lang sila sa maayos na pag-andar ng TownSpot.
Para sa mas magandang karanasan, gamitin ang aming app.