Libsyn API Reference

Statistics (Only Available for Libsyn Pro)

Retrieve downloads metrics

  • Request Types can be either item, show, or network accordingly. Which are used in the endpoints when building a type-specific request, or you have the option to build endpoints as non-type specific requests by passing the type parameter. Below are examples of both with replacing [:type] and [:id] variables with their corresponding values.
  • Type Specific Request

    $ curl https://api.libsyn.com/stats/[:type]/summary/[:id]


    Non-Type Specific Request

    $ curl https://api.libsyn.com/stats/summary/[:id]?type=[:type]


Fields

Field Required Type Description
type Yes string Depending on the request, this is either in the endpoint or passed as a query string parameter. Only show item or network are accepted values.
date_start No string Start date for request in Y-m-d format.
date_end No string End date for request in Y-m-d format. Note: If no end date has been submitted, the current server date will be chosen.
download_type No string Downloads metric type, either traditional download (default) or IAB stats. Accepts: IAB or LES.
region_code No string Filter by a valid region/country code (Geographic stats only).

Request
Headers
Header Value
Accept application/json
Content-Type multipart/form-data
Specific Search Parameters
Parameters Description
search Returns results with the matching the passed string.
page Returns results on the selected page.
limit Returns the number of results per page passed. (Default 20)
order_column Returns results by a valid column.
order_direction Returns results in Ascending/Decending order. Accepts: ASC or DESC.

Daily Downloads

Retrieve daily downloads.

Request

Send a GET request to the /stats/[:type]/daily/[:id] endpoint. Replacing type with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/daily/[:id]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/daily/12345"
        }
    },
    "_embedded": {
        "stats_show_daily": {
            "current": 1,
            "previous": 1,
            "itemCountPerPage": 20,
            "pageCount": 171,
            "recordsTotal": 3413,
            "data": [
                {
                    "metric": "2021-01-25",
                    "requests": "4"
                },
                {
                    "metric": "2021-01-24",
                    "requests": "15"
                },
                {
                    "metric": "2021-01-23",
                    "requests": "26"
                },
                {
                    "metric": "2021-01-22",
                    "requests": "3"
                },
                {
                    "metric": "2021-01-21",
                    "requests": "8"
                },
                {
                    "metric": "2021-01-20",
                    "requests": "62"
                },
                {
                    "metric": "2021-01-19",
                    "requests": "33"
                },
                {
                    "metric": "2021-01-18",
                    "requests": "23"
                },
                {
                    "metric": "2021-01-17",
                    "requests": "9"
                },
                {
                    "metric": "2021-01-16",
                    "requests": "9"
                },
                {
                    "metric": "2021-01-15",
                    "requests": "18"
                },
                {
                    "metric": "2021-01-14",
                    "requests": "10"
                },
                {
                    "metric": "2021-01-13",
                    "requests": "4"
                },
                {
                    "metric": "2021-01-12",
                    "requests": "14"
                },
                {
                    "metric": "2021-01-11",
                    "requests": "21"
                },
                {
                    "metric": "2021-01-10",
                    "requests": "15"
                },
                {
                    "metric": "2021-01-09",
                    "requests": "25"
                },
                {
                    "metric": "2021-01-08",
                    "requests": "30"
                },
                {
                    "metric": "2021-01-07",
                    "requests": "12"
                },
                {
                    "metric": "2021-01-06",
                    "requests": "9"
                }
            ]
        }
    },
    "total_items": 20
}
											
Weekly Downloads

Retrieve weekly downloads.

Request

Send a GET request to the /stats/[:type]/weekly/[:id] endpoint. Replacing type with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/weekly/[:id]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/weekly/12345"
        }
    },
    "_embedded": {
        "stats_show_weekly": {
            "current": 1,
            "previous": 1,
            "itemCountPerPage": 20,
            "pageCount": 2,
            "recordsTotal": 40,
            "data": [
                {
                    "metric_id": 101234,
                    "metric": "2021-01-25",
                    "requests": "5"
                },
                {
                    "metric_id": 101235,
                    "metric": "2021-01-24",
                    "requests": "170"
                },
                {
                    "metric_id": 101236,
                    "metric": "2021-01-17",
                    "requests": "85"
                },
                {
                    "metric_id": 101237,
                    "metric": "2021-01-10",
                    "requests": "169"
                },
                {
                    "metric_id": 101238,
                    "metric": "2021-01-03",
                    "requests": "69"
                },
                {
                    "metric_id": 101239,
                    "metric": "2020-12-27",
                    "requests": "133"
                },
                {
                    "metric_id": 101240,
                    "metric": "2020-12-20",
                    "requests": "147"
                },
                {
                    "metric_id": 101241,
                    "metric": "2020-12-13",
                    "requests": "155"
                },
                {
                    "metric_id": 101242,
                    "metric": "2020-12-06",
                    "requests": "344"
                },
                {
                    "metric_id": 101243,
                    "metric": "2020-11-29",
                    "requests": "4"
                },
                {
                    "metric_id": 101244,
                    "metric": "2020-11-22",
                    "requests": "303"
                },
                {
                    "metric_id": 101245,
                    "metric": "2020-11-15",
                    "requests": "245"
                },
                {
                    "metric_id": 101246,
                    "metric": "2020-11-08",
                    "requests": "370"
                },
                {
                    "metric_id": 101247,
                    "metric": "2020-11-01",
                    "requests": "225"
                },
                {
                    "metric_id": 101248,
                    "metric": "2020-10-25",
                    "requests": "517"
                },
                {
                    "metric_id": 101249,
                    "metric": "2020-10-18",
                    "requests": "204"
                },
                {
                    "metric_id": 101250,
                    "metric": "2020-10-11",
                    "requests": "414"
                },
                {
                    "metric_id": 101251,
                    "metric": "2020-10-04",
                    "requests": "228"
                },
                {
                    "metric_id": 101252,
                    "metric": "2020-09-27",
                    "requests": "408"
                },
                {
                    "metric_id": 101253,
                    "metric": "2020-09-20",
                    "requests": "211"
                }
            ]
        }
    },
    "total_items": 20
}
													
Monthly Downloads

Retrieve monthly downloads.

Request

Send a GET request to the /stats/[:type]/monthly/[:id] endpoint. Replacing type with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/monthly/[:id]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/monthly/12345"
        }
    },
    "_embedded": {
        "stats_show_monthly": {
            "current": 1,
            "previous": 1,
            "itemCountPerPage": 20,
            "pageCount": 1,
            "recordsTotal": 8,
            "data": [
                {
                    "metric_id": 202101,
                    "metric": "2021-01",
                    "requests": "486"
                },
                {
                    "metric_id": 202012,
                    "metric": "2020-12",
                    "requests": "789"
                },
                {
                    "metric_id": 202011,
                    "metric": "2020-11",
                    "requests": "924"
                },
                {
                    "metric_id": 202010,
                    "metric": "2020-10",
                    "requests": "1515"
                },
                {
                    "metric_id": 202009,
                    "metric": "2020-09",
                    "requests": "2486"
                },
                {
                    "metric_id": 202008,
                    "metric": "2020-08",
                    "requests": "1646"
                },
                {
                    "metric_id": 202007,
                    "metric": "2020-07",
                    "requests": "99"
                },
                {
                    "metric_id": 202006,
                    "metric": "2020-06",
                    "requests": "51"
                },
            ]
        }
    },
    "total_items": 8
}
													
Three Month Downloads Summary

Retrieve a three month downloads summary for the requested stats type.

Request

Send a GET request to the /stats/[:type]/three-month/[:id] endpoint. Replacing type with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/three-month/[:id]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/three-month/12345"
        }
    },
    "_embedded": {
        "stats_item_three-month": {
            "show_id": 12345,
            "item_title": "Testing Episode",
            "release_date": "2020-11-01 12:01:01",
            "unique_downloads": "78",
            "total_item_downloads": "26",
            "legacy_downloads": "22",
            "item_three_month": [
                {
                    "month": "2021-01",
                    "downloads": "12"
                },
                {
                    "month": "2020-12",
                    "downloads": "24"
                },
                {
                    "month": "2020-11",
                    "downloads": "42"
                }
            ],
            "daily_stats": [
                {
                    "metric": "2021-01-01",
                    "requests": "5"
                },
                {
                    "metric": "2021-01-02",
                    "requests": "10"
                },
                {
                    "metric": "2021-01-03",
                    "requests": "11"
                },
            ]
        }
    },
    "total_items": 8
}
												
Total Downloads Summary

Retrieve a total downloads summary for the requested stats type.

Request

Send a GET request to the /stats/[:type]/summary/[:id] endpoint. Replacing type with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/summary/[:id]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/summary/12345"
        }
    },
    "_embedded": {
        "stats_show_summary": {
            "legacy_downloads": "3210",
            "unique_downloads": "9465",
            "total_show_downloads": "12675",
            "items": [
                {
                    "item_id": 12345678,
                    "item_title": "My first episode",
                    "release_date": "2021-01-05 12:01:00",
                    "total_item_downloads": "2"
                },
                {
                    "item_id": 12345679,
                    "item_title": "My second episode",
                    "release_date": "2021-01-06 12:01:00",
                    "total_item_downloads": "1"
                },
                {
                    "item_id": 12345680,
                    "item_title": "My third episode",
                    "release_date": "2021-01-07 12:01:00",
                    "total_item_downloads": "1"
                },
                {
                    "item_id": 12345681,
                    "item_title": "My fourth episode",
                    "release_date": "2021-01-08 12:01:00",
                    "total_item_downloads": "2"
                },
                {
                    "item_id": 12345682,
                    "item_title": "My latest episode",
                    "release_date": "2021-01-09 12:01:00",
                    "total_item_downloads": "1"
                }
            ]
        }
    },
    "total_items": 4
}
													
Geographic Downloads by location

Retrieve geographic downloads by region. Note: A region_code must be provided to narrow results to regions of a country.

Request

Send a GET request to the /stats/[:type]/geographic/[:id] endpoint. Replacing type with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/geographic/[:id]?region_code=[:region_code]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/geographic/12345"
        }
    },
    "_embedded": {
        "stats_show_geographic": {
            "current": 2,
            "previous": 1,
            "itemCountPerPage": 20,
            "pageCount": 2,
            "recordsTotal": 31,
            "data": [
                {
                    "metric": "India",
                    "id": "IN",
                    "requests": "2"
                },
                {
                    "metric": "Greece",
                    "id": "GR",
                    "requests": "1"
                },
                {
                    "metric": "Ghana",
                    "id": "GH",
                    "requests": "1"
                },
                {
                    "metric": "Germany",
                    "id": "DE",
                    "requests": "20"
                },
                {
                    "metric": "France",
                    "id": "FR",
                    "requests": "2"
                },
                {
                    "metric": "Denmark",
                    "id": "DK",
                    "requests": "1"
                },
                {
                    "metric": "China",
                    "id": "CN",
                    "requests": "72"
                },
                {
                    "metric": "Canada",
                    "id": "CA",
                    "requests": "4"
                },
                {
                    "metric": "Brazil",
                    "id": "BR",
                    "requests": "6"
                },
                {
                    "metric": "Australia",
                    "id": "AU",
                    "requests": "3"
                },
                {
                    "metric": "Argentina",
                    "id": "AR",
                    "requests": "2"
                }
            ]
        }
    },
    "total_items": 11
}
													
User Agent Downloads

Retrieve downloads by user agent.

Request

Send a GET request to the /stats/[:type]/user-agent/[:id] endpoint. Replacing type with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/user-agent/[:id]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/user-agent/12345"
        }
    },
    "_embedded": {
        "stats_show_user-agent": {
            "current": 1,
            "previous": 1,
            "itemCountPerPage": 20,
            "pageCount": 2,
            "recordsTotal": 23,
            "data": [
                {
                    "metric": "X-Libsyn-Youtube",
                    "requests": "1"
                },
                {
                    "metric": "WordPress",
                    "requests": "19"
                },
                {
                    "metric": "Wget",
                    "requests": "2"
                },
                {
                    "metric": "Unknown",
                    "requests": "0"
                },
                {
                    "metric": "Twitterbot",
                    "requests": "178"
                },
                {
                    "metric": "Safari",
                    "requests": "45"
                },
                {
                    "metric": "Orion",
                    "requests": "1"
                },
                {
                    "metric": "NSPlayer",
                    "requests": "3"
                },
                {
                    "metric": "MSIE",
                    "requests": "29"
                },
                {
                    "metric": "Mozilla",
                    "requests": "3946"
                },
                {
                    "metric": "MetaURI API",
                    "requests": "0"
                },
                {
                    "metric": "Libsyn",
                    "requests": "0"
                },
                {
                    "metric": "Lavf",
                    "requests": "7"
                },
                {
                    "metric": "Java",
                    "requests": "15"
                },
                {
                    "metric": "Headliner",
                    "requests": "7"
                },
                {
                    "metric": "GooglePodcasts",
                    "requests": "1"
                },
                {
                    "metric": "Googlebot-Video",
                    "requests": "1422"
                },
                {
                    "metric": "Google Podcasts (Android)",
                    "requests": "10"
                },
                {
                    "metric": "Go-http-client",
                    "requests": "0"
                },
                {
                    "metric": "Firefox",
                    "requests": "36"
                }
            ]
        }
    },
    "total_items": 20
}
													
Destination Downloads

Retrieve downloads by destination.

Request

Send a GET request to the /stats/[:type]/destination/[:id] endpoint. Replacing type (NOTE: network type is currently disabled) with the request type and corresponding id.:

$ curl https://api.libsyn.com/stats/[:type]/destination/[:id]

-X GET \

-H 'Authorization:Bearer (Your Access Token)'

-H 'Accept: application/json'

-H 'Content-Type: multipart/form-data'


Response

On success, your app will receive the following formatted similar to the example response:


{
    "_links": {
        "self": {
            "href": "https://api.libsyn.com/stats/show/destination/12345"
        }
    },
    "_embedded": {
        "stats_show_destination": {
            "current": 1,
            "previous": 1,
            "itemCountPerPage": 20,
            "pageCount": 1,
            "recordsTotal": 7,
            "data": [
                {
                    "metric_id": 323856,
                    "metric": "Wordpress",
                    "requests": "2"
                },
                {
                    "metric_id": 310203,
                    "metric": "Blogger",
                    "requests": "2"
                },
                {
                    "metric_id": 131753,
                    "metric": "Twitter",
                    "requests": "216"
                },
                {
                    "metric_id": 109070,
                    "metric": "Podcast Page (Legacy)",
                    "requests": "124"
                },
                {
                    "metric_id": 77417,
                    "metric": "Web Player",
                    "requests": "11"
                },
                {
                    "metric_id": 77416,
                    "metric": "Podcast Feed (Transcoded)",
                    "requests": "2349"
                }
            ]
        }
    },
    "total_items": 6
}