Developer API documentation

Events

These endpoints provide lists of events which are associated with a given artist. Three types of events are available: tv, release, and alert

general

Calls are of the form:

http://api.semetric.com/artist/[artist_id]/[tv|release|alert]/?token=YOURAPIKEY

Where artist_id is any artist :doc: identification. token=YOURAPIKEY must be given. The event types are: tv provides television appearances for an artist (currently only US TV); release provides a list of releases, giving musicbrainz ids for each release; and alerts which provides a list of the large changes (worth of say, alerting people who are interested) of the various timeseries associated with an artist.

examples

The following command (this is the tv events endpoint for Lil Wayne):

$curl http://api.semetric.com/artist/08f2c17632f349c7a742c56289b98465/tv/?token=YOURAPIKEYHERE

will produce this json response:

{
"response": {
    "entities": [
        {
            "class": "tv",
            "country": "US",
            "end_time": 1308528000,
            "id": "musicmetric:183965",
            "name": "Lil Wayne was a performer on Unplugged, MTV2 Presents Unplugged Re Cut Lil Wayne",
            "start_time": 1308441600
        },
        {
            "class": "tv",
            "country": "US",
            "end_time": 1307923200,
            "id": "musicmetric:183965",
            "name": "Lil Wayne was a performer on Unplugged, MTV2 Presents Unplugged Lil Wayne",
            "start_time": 1307836800
        },
        ...
        ]
},
"success": true
}

The following command (this is the release events endpoint for Skrillex):

$curl http://api.semetric.com/artist/7668a8e2506b4282b396ee6c2851979e/release/?token=YOURAPIKEYHERE

will produce this json response:

{
"response": {
    "entities": [
        {
            "class": "remix",
            "country": "US",
            "end_time": 1328659200,
            "id": "musicbrainz:5db7def2-fb07-4501-9512-8726a23e6b84",
            "media_type": "Digital Media",
            "name": "Breakn' a Sweat (Zedd remix)",
            "start_time": 1328572800
        },
        {
            "class": "ep",
            "country": "US",
            "end_time": 1327449600,
            "id": "musicbrainz:fde88ca9-a04d-436f-b721-651db6464b14",
            "media_type": "CD",
            "name": "Bangarang",
            "start_time": 1327363200
        },
        {
            "class": "ep",
            "country": "US",
            "end_time": 1325030400,
            "id": "musicbrainz:13b61bbf-67ad-4a0b-9f68-85b425061968",
            "media_type": "Digital Media",
            "name": "Bangarang",
            "start_time": 1324944000
        },
        ...
        ]
},
"success": true
}

The following command (this is the alert events endpoint for Justin Bieber):

$curl http://api.semetric.com/artist/74d4539c16624efc9471c5a93292c6e7/alert/?token=YOURAPIKEYHERE

will produce this json response:

{
"response": {
    "entities": [
        {
            "abs_diff": 353974,
            "class": "alert",
            "end_time": 1269648000,
            "id": "musicmetric:549915",
            "kind": "plays",
            "name": "Youtube plays have increased 96% more than usual. Nicely done!",
            "per_diff": 96,
            "source": "youtube",
            "start_time": 1269648000
        },
        {
            "abs_diff": 409521,
            "class": "alert",
            "end_time": 1269734400,
            "id": "musicmetric:549915",
            "kind": "plays",
            "name": "Youtube plays have increased 107% more than usual. Nicely done!",
            "per_diff": 107,
            "source": "youtube",
            "start_time": 1269734400
        },
        {
            "abs_diff": 937537,
            "class": "alert",
            "end_time": 1269993600,
            "id": "musicmetric:549915",
            "kind": "plays",
            "name": "Youtube plays have increased 226% more than usual. Nicely done!",
            "per_diff": 226,
            "source": "youtube",
            "start_time": 1269993600
        },
        ...
        ]
},
"success": true
}