03-04-2016 15:55:17

TRQL Radio's API

Our API is currently under construction and very few services are functional at this stage (18-01-19 11:29:48)! Stay tuned!

Introduction

Unlimited Access, without stress, without identification. TRQL Radio Simple API provides a nice set of services to build up web applications allowing the discovery of TRQL Radio's catalogue.

You may use ordinary HTTP GET requests. The base URL for each API method is similar to the following:

http://www.trql.fm/api/<verb>/<subject>/?parameters

Encoding

All requests and responses must be in UTF-8.

Responses

All responses are provided in JSON by default. They can also be returned in XML provided that the xml field is sent with the request.

Examples

JSON: http://www.trql.fm/api/tribute/Michael%20McDonald

XML: http://www.trql.fm/api/tribute/Michael%20McDonald?xml

Response Anatomy

The response is always contained in a root structure that encompass the whole response sent by the services of the TRQL Radio API: LSTRQLRadio.

Immediately below the LSTRQLRadio root structure, there is a Copyright construct and a first sibling: Service:

<LSTRQLRadio … some attributes>
    <Copyright>
        …
    </Copyright>
    <Service>
        …
    </Service>
</LSTRQLRadio>

The Service child contains two other children: Request and Response

<LSTRQLRadio … some attributes>
    <Copyright>
        …
    </Copyright>
    <Service … name=some name>
        <Request>
            …
        </Request>

        <Response retcode=some return code>
            …
        </Response>
    </Service>
</LSTRQLRadio>

If the return code is not equal to ERROR_SUCCESS then ... the Response structure contains a detailed message of the error that occurred such as illustrated below:

<Response retcode="1000404">
    <Message>
        <![CDATA[ Missing artist ]]>
    </Message>
</Response>

Response Pagination

All responses are ALWAYS provided in full: there is no pagination mechanism involved for maximum simplicity!

JSON Transposal

Ici expliquer que la structuer XML se retrouve de manière IDENTIQUE dans la structure JSON

Dire que les attributs d'une réponses sont fournis avec __ en début de nom d'attribut

Response Return Codes

Return Code Description
ERROR_SUCCESS The call to the service is successful
1000404 Not found
More error codes soon Description

Air Power

Here, soon … our console to play with the Air Power service

Artist

Description

Returns all titles of a given artist.

End point

http://www.trql.fm/api/artist/

Return

Collection of tracks (title + artist):

Name Description Type
Title The title of the track string
Artist The Artist/Group of the track string

Sample

<LSTRQLRadio rel="author" author="Pat Boens" href="https://plus.google.com/+PatrickBoens">
    <Copyright>
    <![CDATA[
    Copyright Lato Sensu Management. All rights reserved. All intellectual property rights belong to Pat Boens.
    This service is delivered without any warranty of any kind. We do not accept liability for our websites 
    being accurate, complete or up-to-date or for their contents. This statement is valid for all of the links 
    on the websites and for all contents of the pages to which the links lead. We are not responsible for 
    direct, indirect, incidental or consequential damages resulting from any defect, error or failure to perform.
    ]]>
    </Copyright>
    <Service name="artist">
        <Request>
            <![CDATA[ artist joe jackson ]]>
        </Request>
        <Response matchAt="114" retcode="ERROR_SUCCESS">
            <Track id="414e4f5445524f524c2d414e545257524c-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                    <![CDATA[ Another World ]]>
                </Title>
                <Artist>
                    <![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
            <Track id="4348414e474149534b492d53484e47534b-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                    <![CDATA[ Shanghai Sky ]]>
                </Title>
                <Artist>
                    <![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
            <Track id="53544550494e4f552d535450504e-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                    <![CDATA[ Steppin Out ]]>
                </Title>
                <Artist>
                <   ![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
                <Track id="494348455245414c49474f494e474f552d49535348524c4c4b4e4b544e444d-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                    <![CDATA[ Is She Really Going Out With Him ]]>
                </Title>
                <Artist>
                    <![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
            <Track id="4649465449444f4c41524c4f564541462d464654444c4c524c56464652-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                    <![CDATA[ Fifty Dollar Love Affair ]]>
                </Title>
                <Artist>
                    <![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
            <Track id="4348494e41544f554e2d43484e54574e-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                    <![CDATA[ Chinatown ]]>
                </Title>
                <Artist>
                    <![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
            <Track id="5245414c4d414e2d524c4d4e-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                    <![CDATA[ Real Men ]]>
                </Title>
                <Artist>
                    <![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
            <Track id="4a49524c2d47524c20-4a4f454a414b534f4e2d4a4a4b534e">
                <Title>
                <![CDATA[ Girl ]]>
                </Title>
                <Artist>
                <![CDATA[ Joe Jackson ]]>
                </Artist>
            </Track>
            <Track id="494e474f544e4f54494e425554424c552d494e27544b544e544e274254424c532f444e544e2727544c5246524d4d-4a4f454a414b534f4e5341524f4e4a4f2d4a4a4b534e2f5348524e4a4e534e4444504b4e47532f4d52544d50534e">
                <Title>
                    <![CDATA[
                    I Ain't Got Nothin' but the Blues / Do Nothin' 'Til You Hear from Me
                    ]]>
                </Title>
                <Artist>
                    <![CDATA[
                    Joe Jackson/Sharon Jones & The Dap-Kings/Amir Thompson
                    ]]>
                </Artist>
            </Track>
        </Response>
    </Service>
</LSTRQLRadio>

Example

JSON: http://www.trql.fm/api/artist/Michael%20McDonald

XML: http://www.trql.fm/api/artist/Michael%20McDonald?xml

Catalog

Description

This service returns the TRQL Radio Music Pie data (similar to what's shown on the http://www.trql.fm/catalog/ page)

End point

http://www.trql.fm/api/catalog/

Example

JSON: http://www.trql.fm/api/catalog/

XML: http://www.trql.fm/api/catalog/?xml

Track

Description

This service returns the internal information maintained by TRQL Radio about a track (a title of an artist)

End point

http://www.trql.fm/api/track/

Example

JSON: http://www.trql.fm/api/track/49474f54415452492d494b54545452-4d494348454c4d43444f4e414c2d4d4343484c4d43444e4c

XML: http://www.trql.fm/api/track/49474f54415452492d494b54545452-4d494348454c4d43444f4e414c2d4d4343484c4d43444e4c?xml

Tribute

Description

This service returns a list of tracks that can be used to create a tribute for an artist. ICI AUSSI PARLER DE LA LONGUEUR DU TRIBUTE ET LA FAçON D'AVOIR QQCH DE MOINS OU PLUS LONG!

End point

http://www.trql.fm/api/tribute/

Example

JSON: http://www.trql.fm/api/tribute/Michael%20McDonald

XML: http://www.trql.fm/api/tribute/Michael%20McDonald?xml

What Do We Know

Description

This service returns free-format information regarding what TRQL Radio knows about an artist

End point

http://www.trql.fm/api/wdwk/

Example

JSON: http://www.trql.fm/api/wdwk/Michael%20McDonald

XML: http://www.trql.fm/api/wdwk/Michael%20McDonald?xml


A bit more …

This site was conceived and developed by TRQL Labs!

Website Stats

Links

  1. About us
  2. Announcements
  3. Partners
  4. TRQL Labs
  5. API Explorer

Almost Perfect Adult Contemporary Music

Logo du site 'Quitus'

Top

Notre site utilise des cookies pour sauver vos préférences et RIEN d'autre. Nous vous demandons de bien vouloir accepter les cookies qui sont positionnés sur notre site et nous vous promettons en retour de ne RIEN laisser transparaître de votre parcours de visite, dont d'ailleurs vous nous faites l'honneur. Au cas où néanmoins vous n'accepteriez pas d'utiliser les cookies, vous aurez probablement une navigation LÉGÈREMENT dégradée sur notre site. Bonne visite!X