Spinitron v2 API
Notes Tutorial demo using this API is at [https://spinitron.com/v2-api-demo/](https://spinitron.com/v2-api-demo/). For web integration using iframes and/or…
Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.
Overview
Notes
Tutorial demo using this API is at https://spinitron.com/v2-api-demo/. For web integration using iframes and/or JavaScript instead of an API, see https://spinitron.github.io/v2-web-integration/.
Your API key is found in the Spinitron web app. Log in to Spinitron and go to Automation & API in the Admin menu.
Authenticate by presenting your API key using either HTTP Bearer Authorization
(preferred)
curl -H 'Authorization: Bearer YOURAPIKEY' 'https://spinitron.com/api/spins'
or in the query parameter access-token (less secure owing to webserver
log files)
curl 'https://spinitron.com/api/spins?access-token=YOURAPIKEY'
Limit per page of results is 20 by default and miximally 200.
Try it out below works to
generate example cURL requests but not to get responses from Spinitron. We
do not accept queries sent from web browsers. Copy-paste the cURL commands
and run them from your computer.
Cache the data you get from the API if you are using it in web or mobile integration. It's not ok to query the API on every page request you serve. The demo shows how easy it can be to implement a file cache.
An extension to this API with access to all stations for partner applications is available. Contact us.
Endpoints 9
Persona
- GETGet Personas
/personas?name=string&count=20&page=1&fields=string&expand=string - GETGet Persona by id
/personas/:id?fields=string&expand=string
Show
- GETReturns scheduled shows optionally filtered by {start} and/or {end} datetimes
/shows?start=2024-01-01T00:00:00Z&end=2024-01-01T00:00:00Z&count=20&page=1&fields=string&expand=stringTerminology: Spinitron defines a *show* as a radio program. A show can have one or more *schedules*, each of which may specify either an *occurence* or a… - GETGet a Show by id
/shows/:id?fields=string&expand=stringThe response object represents the next occurence of the show specified by {id}. Status 404 is returned if a show with {id} does not exist or if it does but…
Playlist
- GETReturns playlists optionally filtered by {start} and/or {end} datetimes
/playlists?start=2024-01-01T00:00:00Z&end=2024-01-01T00:00:00Z&show_id=0&persona_id=0&count=20&page=1&fields=string&expand=stringGet Playlists optionally filtered by a datetime range. Only past Playlists will be returned (with allowed tolerance equals 1 hour in future). Ordered… - GETGet a Playlist by id
/playlists/:id?fields=string&expand=stringThe response object represents the playlist specified by {id}. Status 404 is returned if a playlist with {id} does not exist or if it does but starts in the…
Spin
- GETReturns spins optionally filtered by {start} and/or {end} datetimes
/spins?start=2024-01-01T00:00:00Z&end=2024-01-01T00:00:00Z&playlist_id=0&show_id=0&count=20&page=1&fields=string&expand=stringGet Spins optionally filtered by a datetime range. Only past Spins will be returned. - POSTLog a Spin
/spinsAn endpoint for automation systems to log spins into the spin table. - GETGet a Spin by id
/spins/:id?fields=string&expand=string
API details
- Base URL
https://spinitron.com/api- Authentication
- An API key in the access-token query parameter
A bearer token in the Authorization header - Operations
- 9 operations on 8 pathsGET 8POST 1
- Main resources
- Spin 3Persona 2Playlist 2Show 2
- Response formats
application/jsonapplication/xml- Description format
- OpenAPI 3.0.0, API version
1.0.0 - Links
- OpenAPI document
- Listed from
- APIs.guru OpenAPI Directory (CC0-1.0)
Source updated
How to test the Spinitron v2 API in Swastik Codes
- Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
- Fork it into your workspaceChoose a workspace. You get your own copy of the Spinitron v2 API collection, without the publisher's secrets.
- Add your credentialsThis API uses an API key in the access-token query parameter. Add yours in the collection's variables or an environment; the requests already reference it.
- Send a requestPick an endpoint, for example “Get Personas” (GET /personas?name=string&count=20&page=1&fields=string&expand=string), and press Send. Check the response, add tests and run the whole collection with the runner.
Frequently asked questions
What is the Spinitron v2 API?
Notes Tutorial demo using this API is at [https://spinitron.com/v2-api-demo/](https://spinitron.com/v2-api-demo/). For web integration using iframes and/or… It is listed under Media & content and has 9 endpoints.
Who publishes the Spinitron v2 API?
It is listed from Spinitron's public API description (an OpenAPI document), not published by Spinitron on Swastik Codes. Anyone who controls spinitron.com can claim the profile by adding a DNS TXT record.
What is the base URL of the Spinitron v2 API?
Requests go to https://spinitron.com/api. Endpoint paths are added to this base URL.
How do I authenticate with the Spinitron v2 API?
It accepts 2 methods: an API key in the access-token query parameter; A bearer token in the Authorization header.
How many endpoints does the Spinitron v2 API have?
9 operations on 8 paths (8 GET, 1 POST). The largest groups are Spin, Persona, Playlist, Show.
Is forking the Spinitron v2 API free?
Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.