MetaRadio WordPress is a WordPress plugin which allows displaying now-playing song data on your WordPress website. This page explains some API details for advanced users.
API: Track Input
This API endpoint allows you to send live now-playing data to WordPress for storage and display. This endpoint is designed to be used by MetaRadio Standalone (the Windows app which connects your automation system to WordPress).
This API isn’t needed by most users, as MetaRadio Standalone is the preferred integration method. However, in some limited cases you may find it useful – especially when creating custom integrations.
This endpoint accepts these POST fields:
- station (the station slug as configured in WordPress)
- stationkey (the station key as configured in WordPress)
- title (the title of the track)
- artist (the artist of the track)
- playoutid (a unique ID for each track)
- duration (the duration in seconds of the track)
- starttime (format: YYYY-MM-DD HH:MM:SS)
The start time must be in the same timezone as your WordPress site, or else it will not display correctly.
API: Station Now
This endpoint returns data in JSON format. These are the main details available:
- streams (list)
- recent (list)
Here is an example payload:
API: Program Guide
This endpoint allows you to request the Program Guide for a station as a JSON feed. This will allow you to consume it in other systems, such a mobile apps.
API: Program Guide (RSS Feed)
This endpoint allows you to request your Program Guide as an RSS Feed. This can be useful for integrating with systems that support a generic RSS feed as a data source.
API: Program Guide (AIM Format)
API: Simple Output Feeds
While the JSON feed is the preferred way to get data out of MetaRadio WordPress, some simple text feeds also exist. These may be useful in some limited scenarios.
- /metaradiofeed/test-station/ (ARITST – TITLE)
- /metaradiofeed/test-station/?mode=track_now_titleartist (TITLE – ARTIST)
- /metaradiofeed/test-station/?mode=program_next (TITLE – PRESENTER)
- /metaradiofeed/test-station/?mode=program_now(TITLE – PRESENTER)