Townbase API

The local content API that turns city guides into city infrastructure; From one content source to every screen in the city

Townbase API for Developers

Everything you need to build a local discovery experience — in one API

  • Skip scraping and data cleanup. Get structured, curated listings for events, venues and activities ready to plug into your product.

  • Use categories, tags, areas and audiences from our site endpoints so your interface updates itself as content grows.

  • Pull event catalogs from leading platforms, pick the feeds you want and keep your guide packed with things to do.

  • Match your own design, domain and tone while Townbase handles the content layer and infrastructure behind the scenes.

  • Reach the right audiences with rich filters, then track engagement trends with dashboards and weekly snapshots.

  • Multilingual out of the box

  • Scoped by host — one integration works across all Townbase cities

  • Use the same integration to power apps, kiosks, digital signage, AI assistants, hotel tools and calendar widgets.

Close-up of hands typing on a laptop displaying code, with a coffee mug in the background.
Three business professionals discussing on a laptop during a meeting in a modern office setting.

Townbase API for cities, DMOs, media

Your content becomes infrastructure. Publish once, power everything

  • 1

    Partners and developers can build on your data without any extra work from you

  • 2

    Your taxonomy — areas, categories, audiences — is exposed as a live API, not a static export

  • 3

    Audience targeting built in (/targets) — developers can build truly personalised experiences

  • 4

    Multilingual support means international tourism apps can consume your content directly

  • 5

    Your content creators and copy writers work shines and can be re-used by you and your partners on 3rd party websites, apps, kiosks, digital signage, AI assistants, hotel tools etc.

Townbase Cities and Destinations

We bring a host of event platforms and ticketing companies content catalogues to your fingertips. Just pick and choose - or ask us to integrate your favorite one

With our API you have access to our cities and many partner channels:

Frequently Asked Questions

GETTING STARTED

Who is Townbase API?

The Townbase API is a REST API that gives developers and organisations programmatic access to structured, curated local event and content data. It lets you embed live local event feeds, search, and discovery features into any app, website, or digital service.

Who is the API designed for?

The API is designed for two audiences: developers who want to build local discovery features into their products, and organisations such as municipalities, tourism boards, DMOs, and media groups who want to distribute their content beyond their own websites, services and platform.

How do I get access to the API?

Contact Townbase to request an API key. Once you have your key, you can start making requests to any public endpoint. You need to sign a contract before getting the key.

Is there a sandbox or test environment?

Yes — a test API key is available for development and testing purposes. Contact us to request one.

How long does integration typically take?

A basic integration — such as embedding an event feed into an existing website — can be up and running in a few hours. A full custom-built discovery experience typically takes a few days to a few weeks depending on scope.

Frequently Asked Questions

FOR CITIES AND OTHER ORGANISATIONS

Do I need a developer to use the API?

The API itself is developer-facing, but your organisation does not need an in-house developer to benefit from it. Townbase works with a network of integration partners, and many common use cases have ready-made solutions. Partners we work can also suggest great new use cases.

Who controls what content is exposed through the API?

You do. The API exposes only the content that is published and approved on your Townbase deployment. You retain full editorial control at all times.

What happens to the API feed if I update content on the platform?

Changes are reflected in the API in real time. When you publish, edit, or remove content on your Townbase platform, the API feed updates automatically — no manual sync required.

Can third-party developers build commercial products using my city's data?

This depends on the licence agreement. Townbase provides the technical infrastructure and commercial use terms for your content, but you decide always what is published.

Is the API included in my Townbase licence or a separate add-on?

API access is available as part of select Townbase plans. Contact us to confirm what is included in your current agreement.

How do I know who is using my API and what they are building?

API keys are issued per integration, giving you visibility into who is accessing your content feed. Usage reporting is available through your Townbase dashboard.

Can the API help my content reach audiences I am not currently serving?

Yes. The API allows developers to embed your content into apps, platforms, and services that already have established audiences — hotel concierge apps, news sites, regional tourism portals, digital signage, and more — without any additional work on your part.

What cities and organisations are already using this?

Townbase powers city guide, local guide, event and activity guide platforms for municipalities, media and other organisations like universities across Finland, Sweden and the UK. Currently more than 50 000 organisations have signed up to create content. The City of Tampere (tapahtumat.tampere.fi) is one publicly available example of a Townbase-powered deployment.

Frequently Asked Questions

FOR DEVELOPERS

What format does the API return data in?

All API responses are in JSON format.

How do I authenticate my requests?

Authentication is handled via an API key. Include your key in the request header or as a query parameter as specified in the API documentation.

Is there a rate limit?

Yes, rate limits apply to prevent abuse and ensure reliability for all users. Details are provided with your API licensing terms and are always negotiable. If your use case requires higher limits, contact us to discuss options.

How often is content updated — is it real-time?

Yes, content is updated in real time. As soon as a publisher updates an event on the platform, the change is immediately reflected in the API response.

What does a typical item response include?

A typical item includes title, description, dates and times, location (long/lat), address, categories, tags, target audiences, images, organiser information, and language variants where available.

How do I fetch only upcoming events?

The /api/public/search endpoint supports date range filtering, allowing you to query only future events. Refer to the API documentation for the full list of supported parameters.

Can I combine multiple filters in a search query?

Yes. The search endpoint supports combining filters such as category, area, tag, target audience, and date range in a single request.

What are the site/* endpoints for?

The site/* endpoints — covering areas, categories, tags, languages, target audiences, and organiser collections — expose the full taxonomy of a deployment. This allows you to build fully dynamic UIs that require no hardcoded values and adapt automatically as the platform content evolves.

Is there an SDK available?

Currently the API is REST-only with no official SDK. It is compatible with any language or framework that can make HTTP requests.

Does the API support webhooks?

Webhooks are not currently available. For real-time updates, we recommend polling the relevant endpoints at a suitable interval for your use case.

What does a typical error response look like?

Errors are returned as JSON with an error_type and error_message field, making them straightforward to handle programmatically.

Is the API versioned?

Yes. Breaking changes will always be introduced under a new version, and existing versions are supported with advance notice of deprecation.

Where can I find the full API documentation?

Full documentation including endpoint references, parameters, and example responses is available at /api/docs/.

Frequently Asked Questions

DATA AND CONTENT

What types of content does the API expose?

The API exposes events, activities, and local content items — including cultural events, sports, community activities, exhibitions, concerts and more, and places like venues, restaurants, hotels etc — depending on what is published on each deployment.

Does the API support multiple languages?

Yes. The /api/public/site/languages endpoint returns the languages available for a given deployment, and content items include language variants where they have been provided by the publisher. For more advanced use cases Townbase offers dynamic translations.

Can I filter content by audience — for example, events for families or seniors?

Yes. The /api/public/site/targets endpoint returns all available audience segments for a deployment, and these can be used as filters in search and content queries.

Can I filter content by geographic area or neighborhood?

Yes. The /api/public/site/areas endpoint returns all defined geographic areas (geoJSON polygon boxes) for a deployment, which can be used to filter content by location.

Is historical content available, or only upcoming events?

Both past and upcoming content is accessible via the API. Date range parameters in the search endpoint give you full control over the time window you query. Past events API access requires additional parameters to be enabled. To enable past events queries please mention this in your request.

Frequently Asked Questions

USE CASES

What can developers build with the Townbase API?

Common integrations include city and municipal apps, tourism and destination portals, hotel concierge and hospitality apps, regional news and media sites with automated event listings, digital signage and public screens, AI assistants and chatbots with local event awareness, and calendar apps enriched with local content like activity and hobby guides and other recreational experiences. If you want people to find what is happening in your city, you can power that view with Townbase instead of writing lots of feeds by hand or trying to integrate many touchpoints into your own set-up. If we are missing an important touch point we are happy to review adding it to our partner list.

Can I embed a live event feed directly into my website?

Yes. The /api/public/content-by-host endpoint returns a structured list of all published content for a given deployment, making it straightforward to render a live event feed on any website or app.

Can I build a fully branded custom event guide using the API?

Yes. The API is designed to support fully custom front-end experiences. All taxonomy data — categories, areas, tags, audiences — is available dynamically via the site/* endpoints, so your UI can reflect the platform's content without any hard coding.

Is the API suitable for AI and chatbot integrations?

Yes. The structured JSON responses and search capabilities make the Townbase API well suited for powering AI assistants, voice interfaces, and chatbots that need to answer questions about local events and activities. Some clients use it to power voice assistants for accessibility reasons, some want to provide a local guide via agentic interface. Ask for examples.