This website uses cookies.

How does RadioManager work

RadioManager is all about your station. At the station settings, see menu, you can alter all the information about your station. This information could be used for providing radio directories with the correct and updated information. RadioManager does not distribute any information by default, only on request by enabling a feature or submitting for registration.

Users

Users can be added or invited to your station. Invited users can create an account for your station within 30 days after the invitation is send. Invited users can then create their account by entering a password or with their Google, Facebook or Twitter account. You can control the permission to your user by assiging him or her to a specific role. In the roles panel you can control the permissions of the roles. During the trial period you can add as much users as you want to your station.

Programs

At the programs section you can add or edit information and metadata about your shows. This metadata could be used for generating an EPG for services like RadioDNS or your website. The programs are needed as templates for your broadcasts.

EPG

The EPG, or electronic program guide, is the place to setup which broadcasts occur on which day and time. For a normal station your guide should be filled in advanced for the next months. The broadcasts copy the data from the program as a template, they could be altered for a single broadcast or the whole
In the EPG you can schedule your broadcasts as repetitions or as a single broadcast. Broadcasts are for more detailed information about your show and the frame for the items in your show. All hours should be filled with shows, you can add one recurring show for the whole day if your station is a non-stop station. The EPG will be available as DAB and RadioDNS EPG XML and distributed to indexes if needed.

Presenters

Here you manage your presenters, or hosts/disc jockeys, of your station. You can enter information for internal or external use. With the API and the data model builder you can use the presenter information for your CMS.

Rundown

In the rundown the items of your show can be planned. Items are sections of your show, they are always put in blocks of an hour in the broadcast. Items could be imported automatically through the API's or made manually in RadioManager by the user. Items could be setup in different types like songs and spoken items or more complex setups differentiations be made in the data structure builder. Items only have a duration and an order, the can be rearranged or added or edited. The time left is a calculation if you have planned enough items in your show.

Live Rundown

The live rundown is the view of the current block. You can keep track with your current item You can edit all items in that block with your colleagues at the same time. On top of the live rundown there is a widget that helps you to keep track with your time.

Templates

Templates are used to manage recurring items, or type of items, for broadcasts hours. In the radio it happens often a show had a certain set structure of their show. Templates are bound to programs and should be applied on every time box. Items could be added to the template as type with a estimated duration or with predefined information like a title. When a template is applied to a time box it rearrange the existing items to the order of types or create new item containers if only a type is set. Templates could be switched or unset from a time box. Existing items or edited template items will be saved while the others will be removed from the time box.

Items

Items are the smallest segments of your shows. The are bound to a start and have a duration. They are containers for information about the parts that are in your broadcasts. Items could be songs, jingles, spoken items or whatever your station things is relevant for your information model.

Items have a play state that could be scheduled, playing or played. The state could be changed by a remote API call, started manually through the live rundown or through the autoplay functionality. The autoplay functionality start the item automatically after a song with a fixed duration. The item should have autoplay enabled in the data builder if you want them to automatically start.

If you use the API to provide RadioManager with your current items from your playout you can hide certain items for creation by users. You can do this by enabling "hide" in your data builder.

Custom metadata

In RadioManager it is possible to define your own data model for database. Each object can defined by types with custom data.

yhe information of the objects can be altered with specialized fields to make it easier to map to your current workflow or systems. With this feature it is possible to add extra data to objects. With RadioManager you can also define types for your objects. It is common to define your items in different types like song, spoken item, jingle. Or program and broadcasts to live, automated or recorded. Each type can contain different data. So you can add your song details to the songs and completely different information about e.g. the news recording. You can add different types of data to your models.

API Authentication

RadioManager try to have an open structure to communicate with. You can connect different inputs like music scheduling, your playout or commercial/news planning software. Also retrieving all your information is possible to broadcast your metadata to your website, phone application, visual radio, RDS, DAB etc

Authentication of all the API's is done by HMAC authentication with sha256 as hashing algorithm. At your station settings you can generate a new API key and set its permissions. With the API key and secret provided by the system you can communicate with HTTP calls with RadioManager.

PHP Code Example

Example in PHP (5.6/7.0) with Guzzle:

<?php
$client = new \GuzzleHttp\Client();
 
$url = 'https://radiomanager.pluxbox.com/api/v1/';
 
//Set your credentials 
$api_key = 'YOUR_API_KEY';
$api_secret = 'YOUR_API_SECRET';
 
//Create random string 
$chars = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
for ($nonce = ''$cl = strlen($chars)-1$i = 0; $i < 32; $nonce .= $chars[mt_rand(0$cl)]++$i);
 
//Save timestamp in a variable to be sure it fixed through the process 
$time = time();
 
//For GET and DELETE requests the body should be NULL 
$auth_string = sprintf("%s:%s:%s:%s"$time$nonce$api_keyNULL);
 
//Hash the string with hmac algoritm and sha256 bit encryption 
$auth_string = hash_hmac('sha256'$auth_string$api_secret);
 
//Base64 encode the string to shorten and have ASCII for sending 
$auth_string = base64_encode($auth_string);
 
//Do a GET request 
$client->get($url.'items/1'[
    'headers' => [
        'nonce' => $nonce,
        'timestamp' => $time,
        'api-key' => $api_key,
        'hash' => $auth_string
    ]
]);
 
//CREATE AND UPDATE REQUESTS 
$data = ['id' => 1'title' => 'foobar'];
 
//For POST and PUT request the last value should be the body 
$auth_string = sprintf("%s:%s:%s:%s"$time$nonce$api_keyjson_encode($data));
 
//Hash the string with hmac algoritm and sha256 bit encryption 
$auth_string = hash_hmac('sha256'$auth_string$api_secret);
 
//Base64 encode the string to shorten and have ASCII for sending 
$auth_string = base64_encode($auth_string);
 
//Do a PUT request 
$client->put($url.'items/1'[
    'headers' => [
            'nonce' => $nonce,
            'timestamp' => $time,
            'api-key' => $api_key,
            'hash' => $auth_string,
            'content-type' => 'application/json',
            'charset' => 'utf8'
    ],
    'body' => json_encode($data)
]);
?> 

Python Code Example

from hashlib import sha256
import hmac
import time
import urllib2
 
api_key = "YOUR_API_KEY"
api_secret = "YOUR_API_SECRET"
 
# Create random string 
def nonce_generator(size=32, chars=string.ascii_uppercase + string.digits + string.ascii_lowercase):
    return ''.join(random.choice(chars) for _ in range(size))
 
# HMAC sign and base64 encode the string 
def sign_request(auth_str, api_secret):
    hashed = hmac.new(api_secretauth_strsha256)
    doc = hashed.hexdigest().encode("base64")
    doclines = doc.splitlines()
    return ''.join(doclines)
 
# Save timestamp to keep it same during the process 
timestamp = time.time()
 
# Generate random nonce 
nonce = nonce_generator()
 
# For GET and DELETE request set the last atribute to null, otherwise json encode data would be there. 
auth_str = "%s:%s:%s:%s" % (timestampnonceapi_keyNone)
 
# Generate the authentication hash 
hash = sign_request(auth_str)
 
# Do the request 
req = urllib2.Request(
    "https://radiomanager.pluxbox.com/api/v1/items/1.json"
    None
    {'nonce' : nonce, 'timestamp' : timestamp, 'api-key' : api_key, 'hash' : hash }
)
response = urllib2.urlopen(req).read()

Node.js Code Example

const crypto = require('crypto');
const querystring = require('querystring');
const util = require('util');
const entities = require('entities');
 
crypto.randomBytes(32, function(ex, buf) {
 
    var postData = querystring.stringify( [ 'id' : 1, 'title' : 'foobar' ] );
 
    let nonce =  buf.toString('hex');
 
    // Save timestamp for consistency  
    let ts = Math.round((new Date()).getTime() / 1000);
 
    // Generate auth string 
    let auth_string = util.format('%s:%s:%s:%s', ts, nonce, watcher[key].key, postData);
 
    // generate the signed authentication string 
    let hmac = crypto.createHmac('sha256', watcher[key].secret);
 
    // base64 encode the string 
    let hash = new Buffer(hmac.update(new Buffer(auth_string, 'utf-8')).digest('hex')).toString('base64');
 
    // set all the request options 
    var options = {
        hostname: hostname,
        port: 443,
        path: 'https://radiomanager.pluxbox.com/api/v1/items/',
        method: 'GET',
        headers: {
            'nonce'         : nonce,
            'timestamp'     : ts,
            'api-key'       : watcher[key].key,
            'hash'          : hash,
            'Content-Type'  : 'application/x-www-form-urlencoded',
            'Content-Length': postData.length
        }
    };
 
    // Do the request 
    var req = http.request(options, function(res) {
        console.log('STATUS: ' + res.statusCode);
        console.log('HEADERS: ' + JSON.stringify(res.headers));
        res.setEncoding('utf8');
        res.on('data', function (chunk) {
            console.log('BODY: ' + chunk);
        });
        res.on('end', function() {
            console.log('No more data in response.')
        })
    });
 
    req.on('error', function(e) {
        console.log('problem with request: ' + e.message);
    });
 
    req.write(postData);
    req.end();
});

Testing with Postman

Postman is a nice application to test the API functionality or even use it to assist in your production. Postman is downloadable as extension for Chrome (any OS) or Mac OSX standalone: https://www.getpostman.com/
You can use the "Pre-request script" functionality to authenticate with HMAC on our API.
Make sure you select an environment and that the option "Trim keys and values in request body" is disabled in your settings.

This is the pre-request script:

var apiKey = 'Your Key Here';
var secret = 'Your Secret Here';
 
function newGuid() {
    return 'xxxxxxxxxxxxxxxxyxxxyxxxxxxxxxxx'.replace(/[xy]/g, function (c) { var r = Math.random() * 16 | 0, v = c == 'x' ? r : r & 0x3 | 0x8; return v.toString(16); });
}
 
function epochTime() {
    var d = new Date();
    var t = d.getTime();
    return Math.round(t/1000);
}
 
var time = epochTime();
var nonce = newGuid();
 
var requestBody = request.data.toString();
 
if (request.method == 'GET') {
    var rawSignature = time +':'+ nonce +':'+ apiKey +':' ;
} else {
    var rawSignature = time +':'+ nonce +':'+ apiKey +':' + requestBody;
}
 
var hmac = CryptoJS.algo.HMAC.create(CryptoJS.algo.SHA256, secret); 
hmac.update(rawSignature); 
var hmacSig = hmac.finalize();
wordArray = CryptoJS.enc.Utf8.parse(hmacSig);
signature = CryptoJS.enc.Base64.stringify(wordArray);
 
 
postman.setEnvironmentVariable('api-key', apiKey);
postman.setEnvironmentVariable('timestamp', time);
postman.setEnvironmentVariable('nonce', nonce);
postman.setEnvironmentVariable('hash', signature);

Do not forget to adapt the script with your API Key and Secret. You will also need to add the variables of the script to the Headers of the request:

Postman Headers

Make sure you set an Environment in Postman, as the variables are environment variables and won't be picked up otherwise. And don't forget to set your request MIME type, which should be "Json/Application".

Rest API's

RadioManager has an REST API interface for fetching the information. You can point direct to the models of the system or use predefined endpoints for common usecases. The following models are available:

  • Broadcast /api/v1/broadcasts/
  • Item /api/v1/items/
  • Presenter /api/v1/presenters/
  • Program /api/v1/programs/
  • Action /api/v1/campaigns/

With extra parameters you can use extra features. Currently the API supports:

  • Filtering and sorting of the results
  • Set a results limit and offset
  • Append related models to the result

You can fetch a single object or a collection. The results will be presented in JSON.

In general the API accepts POST, GET, DELETE, PUT and PATCH. Input data should be provided as JSON, and the request mime-type should be "Json/Application". Note that PUT works the same as PATCH and if any fields aren't provided in the request than they won't override existing values. However if a field is explicitly set on "null" (without the quotes, ofcourse) in the request, it WILL be overwritten (without any value, being NULL).

Our API is partly based on the Laravel Api Handler by marcelgwerder. A summary of it's workings can be found below, but the whole documentation can be found here. Note that the _limit and _offset parameters will not work and are replaced by the Laravel Paginator.

Retrieve single object

If you handle a GET request on a resource representing a single object like for example /api/v1/programs/1. This will load the program with id 1.

Retrieve collection of objects

If you handle a GET request on a resource representing multiple objects like for example /api/v1/programs you will get an array of all the programs.

Filtering

Requests could be fetched by knowing their data, e.g. an id from your playout.

/api/v1/items?external_id=00012343

Multiple filters are combined and fetched with an AND operator. /api/v1/items?external_id=0001234&start-min=2015-02-23 00:00:00

The above example would result the item in json with the external_id of 0001234 and only after or at the same time as the given date.

Its also possible to use multiple values for one filter. Multiple values are separated by a pipe |. Multiple values are combined with OR except when there is a -not suffix, then they are combined with AND. For example all the items with the id 5 or 6:

/api/v1/items?id=5|6

Or all the items except the ones with id 5 or 6:

/api/v1/items?id-not=5|6

The same could be achieved using the -in suffix:

/api/v1/programs?id-in=5,6

Respectively the not-in suffix:

/api/v1/programs?id-not-in=5,6

Operators

Suffix Operator Meaning
(none) = Equal to
-not != Not equal to
-st < Smaller than
-max <= Smaller than or equal to
-gt > Greater than
-min >= Greater than or equal to

Ordering

There are two ways of ordering, ascending and descending. Every column which should be sorted descending always starts with a -.

/api/v1/items?block_id=1&_sort=start

Multiple ordering is also supported by adding comma separated arguments.

/api/v1/items?_sort=-duration,-start

The api handler also supports model relationships. So if you want to get all the items including the contacts, just add the contacts to the _with parameter.

/api/v1/items?_with=contacts

Relationships can also be nested, this will expand the ModelType of the Contacts:

/api/v1/items?_with=contacts.modeltype

Not all models are allowed to query as an relationship. This is to prevent extreme large queries and output.
The following models are always allowed as relationship:

  • Genre
  • ModelType
  • Tag

The following models are allowed if the API account has permission to view them:

  • Campaign
  • Contact
  • Presenter
  • Program
  • User
  • Role

Paginating

The REST List endpoints are enriched with a paginator. By default the results are chunked in pages of 50 items, however a lower limit can be set. The response will contain the results as wel as information about the result count an pages, including links to the next and previous page.

To define the number of items per page, use _page-length /api/v1/broadcasts?_page-length=10

To browse trough the pages use the _page parameter

/api/v1/broadcasts?_page=2

Rate Limiting

All our endpoints are rate-limited, meaning they'll only accept a certain amount of request per minute. You can find the limit and the number of requests left in the headers of the response:

X-RateLimit-Limit:60 X-RateLimit-Remaining:59

Datetime parsing

The API accepts any format of date that is accepted by the PHP DateTime Class. Recommended is the ISO-8601 standard, but without the timezone(example: 2016-01-31T11:59:59). If no timezone is provided, the timezone from the Stationsettings will be used.

Models

Enpoint arguments surrounded by {curly brackets} are required. Arguments within [block brackets] are optional.

Block

The Blocks endpoint is read only. Blocks are hourly segments of Broadcasts and are automatically created/destroyed with their Broadcasts. This endpoint is mainly meant to find a certain block id, which might be needed for creating an Item. For example, to find the block of a certain date:

/api/v1/blocks?start=2016-07-04 12:00

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/blocks/
Read GET /api/v1/blocks/{id}
Get current Block GET /api/v1/blocks/current
Get next Block GET /api/v1/blocks/next

Broadcast

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/broadcasts/
Create POST /api/v1/broadcasts/
Read GET /api/v1/broadcasts/{id}
Update PATCH /api/v1/broadcasts/{id}
Delete DELETE /api/v1/broadcasts/{id}
Get current Broadcast GET /api/v1/broadcasts/current
Get next Broadcast GET /api/v1/broadcasts/next
Get epg by week GET /api/v1/broadcasts/epg/[startdate]
Get epg by day GET /api/v1/broadcasts/epg/daily/[date]

Note: Read here about parsing dates. In this case it's recommended to just parse a date without time in YYYY-MM-DD format. Example: api/v1/broadcasts/epg/daily/2016-01-03

Structure

Name Type Example Required Explanation
model_type_id Integer 1 Yes ID of ModelType, must be for "broadcast"
program_id Integer 2 Yes ID relation to Program
title String "FooBar Show" Yes Title (full name) of the Broadcast
start ISO8601 "2016-01-11T22:01:11" Yes Start of Broadcast
stop ISO8601 "2016-01-11T22:01:11" Yes End of Broadcast
description String "FooBar BarFoo" No Description/speech text of Broadcast
recommended Boolean true No Recommended flag for EPG exports
published Boolean true No Broadcast will be displayed on dashboard
genre_id Integer 2611 No ID from genre, should exist
short_name String "foobarshow" No Short name/title for EPG exports, max 8 chars
medium_name String "foobar" No Medium name/title for EPG exports, max 16 chars
website String "http://example.com" No Website of Broadcast/Program
email String "info@example.com" No Email of Broadcast/Program
language String "English" No Language of Program/Broadcast
field_values JSON Object {"foo":"Bar"} No Your extra metadata, as defined in the ModelType

Note: to find the possible ModelTypes you can use for a certain model, you can use the following endpoint:
api/v1/modeltypes?model=broadcast

Campaign

Campaigns are events that can cover multiple Broadcasts/Programs. This part of the API is still work in progress and it is adviced to plan Campaigns through the User Interface.

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/campaigns/
Create POST /api/v1/campaigns/
Read GET /api/v1/campaigns/{id}
Update PATCH /api/v1/campaigns/{id}
Delete DELETE /api/v1/campaigns/{id}

Structure

Name Type Example Required Explanation
model_type_id Integer 12 Yes ID of ModelType, must be for "campaign"
title String "FooBar Event" Yes Title of the Campaign
start ISO8601 "2016-01-11T22:01:11" Yes Start of Campaign
stop ISO8601 "2016-01-22T22:01:11" Yes End of Campaign
description String "Give Away Free Stuff!" No Description of Campaign
recommended Boolean true No Action will be displayed on dashboard
field_values JSON Object {"type":"giveaway"} No Your extra metadata, as defined in the ModelType

Contact

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/contacts/
Create POST /api/v1/contacts/
Read GET /api/v1/contacts/{id}
Update PATCH /api/v1/contacts/{id}
Delete DELETE /api/v1/contacts/{id}

Structure

Name Type Example Required Explanation
model_type_id Integer 8 Yes ID of Modeltype, should be for "contact"
firstname String "John" No First name of Contact
lastname String "Doe" No Last name of Contact
email String "john@example.com" No Email address of Contact
phone String "+316123456789" No Phone number of Contact
field_values JSON Object {"foo":"Bar"} No Your extra metadata, as defined in the ModelType

Genre

The Genres endpoint is read only. The genres are defined according to the EBUContentGenre Standard.

Endpoint

Action HTTP Method Endpoint
List GET /api/v1/genres/
Read GET /api/v1/genres/{id}

Item

Endpoint

Action HTTP Method Endpoint
List GET /api/v1/items/
Create POST /api/v1/items/
Read GET /api/v1/items/{id}
Update PATCH /api/v1/items/{id}
Delete DELETE /api/v1/items/{id}
Add current/now playing POST /api/v1/items/current
Add playlist POST /api/v1/items/playlist
Get current/now playing GET /api/v1/items/current
Get next GET /api/v1/items/next

Note: To add a playlist or now playing, please use RadioManager Connect, instead of directly calling the endpoint. To post a current/now playing song also see Special API's.

Structure

Name Type Example Required Explanation
external_id String "ID_1234" Yes ID from playout
model_type_id Integer 12 Yes ID of Modeltype, should be for "item"
block_id Integer 1 No ID of Block
program_id Integer 1 No ID of Program
station_id Integer 1 No ID of Station
user_id Integer 1 No ID of User
start ISO 8601 "2016-01-11T22:01:11" No When does the item start, timezone could be added
duration Integer 120 No Duration of the item in seconds
title String "Foobar" No Title of the item
details String "Details of item" No Description/speech text of item
field_values JSON Object {"artist":"2Pac"} No Your extra metadata, as defined in the ModelType
_previous_id Integer 1040 No Set this item after this item id

Note: although block_id, program_id, user_id and station_id are listed as not required, you should provide one of them.

The details field supports the use of HTML. For internal use we parse HTML with a XML parser. This means that the HTML you get can be different from what you send. For some specific lay-out, like font size and alignment, we use specific classes. To be able to use the details out-of-the-box add the following css to your website, or write your own piece of css for these classes.

/*lists etc*/
.rm-content ul, ol, p {
  margin: 0
}
 
/*photos*/
.rm-content img.rm-photo {
  display: block;
  max-width: 100%
}
 
.rm-content .rm-photo.rm-align-center {
  margin: 0 auto
}
 
.rm-content .rm-photo.rm-align-right {
  margin: 0 0 0 auto;
}
 
/*font sizes*/
.rm-content .rm-size-small {
  font-size: 0.75em;
}
 
.rm-content .rm-size-large {
  font-size: 1.5em;
}
 
.rm-content .rm-size-huge {
  font-size: 2.5em;
}
 
/*alignments*/
.rm-content .rm-align-center {
  text-align: center;
}
 
.rm-content .rm-align-right {
  text-align: right;
}
 
.rm-content .rm-align-justify {
  text-align: justify;
}
 
/*indents*/
.rm-content .rm-indent-1 {
  padding-left: 3em
}
 
.rm-content .rm-indent-2 {
  padding-left: 6em
}
 
.rm-content .rm-indent-3 {
  padding-left: 9em
}
 
.rm-content .rm-indent-4 {
  padding-left: 12em
}
 
.rm-content .rm-indent-5 {
  padding-left: 15em
}
 
.rm-content .rm-indent-6 {
  padding-left: 18em
}
 
.rm-content .rm-indent-7 {
  padding-left: 21em
}
 
.rm-content .rm-indent-8 {
  padding-left: 24em
}

ModelType

The ModelTypes endpoint is read only and used to find the modeltype id's needed to post certain models. To adapt the ModelTypes one should use the User Interface in RadioManager.

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/modeltypes/
Read GET /api/v1/modeltypes/{id}

Note: to find the possible ModelTypes you can use for a certain model, you can use the following endpoint:
api/v1/modeltypes?model=broadcast

Presenter

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/presenters/
Create POST /api/v1/presenters/
Read GET /api/v1/presenters/{id}
Update PATCH /api/v1/presenters/{id}
Delete DELETE /api/v1/presenters/{id}

Structure

Name Type Example Required Explanation
model_type_id Integer 7 Yes ID of Modeltype, should be for "presenter"
name String "John Doe" No Full name of the Presenter
active Boolean true No Wether Presenter is active and findable
field_values JSON Object {'Foo':'Bar'} No Your extra metadata, as defined in the ModelType

Program

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/programs/
Create POST /api/v1/programs/
Read GET /api/v1/programs/{id}
Update PATCH /api/v1/programs/{id}
Delete DELETE /api/v1/programs/{id}

Structure

Name Type Example Required Explanation
model_type_id Integer 12 Yes ID of ModelType, must be for "program"
title String "FooBar Show" Yes Title of the item
description String "FooBar BarFoo" No Description/speech text of item
recommended Boolean true No Recommended flag for EPG exports
published Boolean true No Broadcasts of Program will be displayed on dashboard
genre_id Integer 2611 No ID from genre, should exist
medium_name String "foobarshow" No Short name/title for EPG exports, max 8 chars
short_name String "foobar" No Medium name/title for EPG exports, max 16 chars
website String "http://example.com" No Website url of Program
email String "info@example.com" No Email address of Program
language ISO 639-1 "English" No Language of Program
field_values JSON Object {'foo':'Bar'} No Your extra metadata, as defined in the ModelType

Role

This API is read only. If you wish to add, alter or remove Roles use the User Interface in RadioManager

Endpoints

Action HTTP Method Endpoint
All GET /api/v1/roles/
Read GET /api/v1/roles/{key}

User

Endpoints

Action HTTP Method Endpoint
List GET /api/v1/users/
Create POST /api/v1/users/
Read GET /api/v1/users/{id}
Update PATCH /api/v1/users/{id}
Delete DELETE /api/v1/users/{id}
Invite POST /api/v1/users/invite

Structure

Name Type Example Required Explanation
firstname String "John" Yes First name of the User
lastname String "Doe" Yes Last name of the User
email String "john@example.com" Yes Email address of the User, an email will be send upon creation
password String "FooBar BarFoo" Yes Password for the User
phone String true No Phone number of the user
active Boolean true No Is the User active
settings Object {"zoomFactor":50} No Personal settings
language String "en_GB" No Language of the User and how RadioManager will be presented
role_id Integer 1 No Role of the user, see Role endpoint

Note: The Invite endpoint only accepts "email" and "role_id", both are required.

Special API's

Station

This API is read only and will only return information about your own Station

Endpoints

Action HTTP Method Endpoint
Read GET /api/v1/stations/

StationSetting

This API is read only and will only return information about your own Station

Endpoints

Action HTTP Method Endpoint
All GET /api/v1/stationsettings/
Read GET /api/v1/stationsettings/{key}

External Message Queue API

This endpoint allows the user to add extra external message to the message-queue(Twitter, Facebook), visible inside the Live Rundown of Radiomanager.
This endpoint is POST only and the message queue is NOT persistent!

Endpoints

Action HTTP Method Endpoint
Create POST /api/v1/externalmessagequeue

Structure

Name Type Example Required Explanation
model_type_id Integer 18 Yes ID of ModelType, must be for "external"
message_id String "SMS00123" Yes The (source) ID of the message
sender_name String "FooBar BarFoo" Yes Name of the originator
message JSON Object {'text': 'Your message!', 'photos': ['http://url-to-picture.com']} The actual message
sender_id String "User00123" No The (source) ID of the originator
avatar_url String "http://example.com/avatar.jpg" No Url of avatar of the originator
external_url String "http://example.com/mess.xml" No External url to the message origin
field_values JSON Object {'foo':'Bar'} No Your extra metadata, as defined in the ModelType

Search API

An extra API to simplify searching in models. The controller uses a different technique to find results than the REST API. The query in the request should just be a string. Optionally two date arguments may be provided: "start" and "stop". These will filter the results for some models. The following models can be searched through the API:

Model Permissions needed Start/stop arguments
broadcasts broadcasts.view, presenters.view yes
contacts contacts.view No
campaigns campaigns.view No
items items.view, contacts.view Yes
presenters presenters.view No
programs programs.view, presenters.view Yes
users station.management No

Endpoints

Action HTTP Method Endpoint
Search GET /api/v1/search/{model}/{query}

Send current song

All items can be created in the interface and you can change the state of an item to 'played' in the live rundown. To change the now on air you can use this API endpoint. We check first if there is an item with the same external_id, if not, we create a new item. The state of the item will be set to 'playing' and will change to 'played' if another item is send or you can change it in the live rundown.

You can also use RM Connect to send the now playing.

Endpoints

Action HTTP Method Endpoint
Create/UPDATE POST /api/v1/items/current/

Structure

Name Type Example Required Explanation
external_id String "ID_1234" Yes ID from playout
model_type_id Integer 12 Yes ID from type
start ISO 8601 "2016-01-11T22:01:11" Yes When does the item start, timezone could be added
duration Integer 120 Yes Duration of the item in seconds
title String "Foobar" No Title of the item
details String "Details of item" No Description/speech text of item
field_values JSON Object "{'artist':'2Pac'} No Your extra metadata, should exists in type

Datetime configuration

Because the date strings could be in another format then the ISO 8601 format RadioManager accepts there is a way how to set your date time string for correct parsing. With the dateime_format you can setup your string how to parse the dates of your file. If the date is in ISO 8601 you can leave this setting out. The following characters could be used:

Input Example Description
YYYY 2016 4 digit year
YY 16 2 digit year
MM 01..12 Month number
MMM Jan Three characters month
MMMM December Full English month
DD 01..31 2 digit day of month
X 1410715640 Unix timestamp
x 1410715640579 Unix ms timestamp
HH 00..23 24 hour time
hh 01..12 12 hour time
a am/pm Post- or ante meridiem
mm 00..59 2 digit minutes
ss 00..59 2 digit seconds
Z ZZ +12:00 Offset from UTC as +-HH:mm, +-HHmm, or Z

Examples:

Example from your XML Example config setting
31-01-2016 23:59:00 DD-MM-YYYY HH:mm:ss
10:53:12am 2016-31-01 hh:mm:ssa YYYY-DD-MM
1410715640579 x

RadioDNS

RadioDNS is an open standard that resolves metadata of your station to services and devices. Pluxbox RadioManager does support the RadioDNS standard by default. The location of your files are obfiscated and the radioDNS records still should be registered by RadioDNS itself. You can request changes in the Organisation window found in the menu. You need to send your changes to RadioDNS only if there are changes in your FM, DAB, DRM and HD Radio transmissions. Be sure all the fields in the organisation and stations settings are filled in for valid RadioDNS For more information about RadioDNS visit http://radiodns.org/

Push API

With our Push API you can notify your system if there's any change in RadioManager's objects. You can find the options in the StationSettings menu, within the API tab. If you define an endpoint here and activate the models you'd like to be informed of, then Radiomanager will send an request to that endpoint with the model name, the model id and the action type. Optionally you may want to implement HMAC Authentication on the endpoint, which is supported by the Push API. And example of an message from our Push API:

{'action' : 'create', 'model_name' : 'broadcast', 'model_id' : 1, 'job_id' : 1, 'resync' : false }

The "job_id" works as counter to make sure the receiving system will handle the jobs in correct order. The "resync" option will be true if the "Resync" button is used within Radiomanager. It will be false on automated messages.

Pluxbox RadioManager

Hi there :)

We love to get in touch with you!

Email is not valide
Pluxbox RadioManager

Thank You

You will hear from us as soon as possible!

Pluxbox RadioManager

Pluxbox Newsletter

RadioManager News is a monthly curated publication full of interesting, relevant links. Subscribe below and never miss an issue.

Email is not valid

Your email address will only ever be used for RadioManager News and you can easily unsubscribe with a single click at any time.

Pluxbox RadioManager

Thank You!

Almost finished... We need to confirm your email address. To complete the subscription process, please click the link in the email we just sent you.