Libsyn API Reference

Media

Handles Libsyn media (any audio/video file).

  • Search Media - Retrieve a list of Libsyn media file information by filters.
  • Retrieve Media File - Retrieve information on an individual Libsyn media file.
  • Delete Media - Permanently delete an individual Libsyn media file.

Fields

Field Type Description
content_id integer Represents an individual media file.
show_id integer Represents a valid Libsyn show ID (numeric or string) (may also be known as show slug).
file_name string File name of the media file.
file_size integer File size of the media file.
url string URL address of the media file.
secure_url string Secure URL address of the media file.
duration integer Length of the media file in seconds.
id3_title string id3 title tag of the media file.
id3_author string id3 author tag of the media file.
id3_artist string id3 artist tag of the media file.
id3_album string id3 album tag of the media file.
id3_year string id3 year tag of the media file.
id3_track string id3 track tag of the media file.
id3_genre string id3 genre tag of the media file.
id3_copyright string id3 copyright tag of the media file.
id3_comment string id3 comment tag of the media file.
upload_date string Upload date of the media file.
file_class string File class of the media file.
mime_type string Mime type of the media file.
bit_rate integer Bit rate of the media file.
audio_codec string Audio codec of the media file.
audio_bit_rate integer Audio bit rate of the media file.
audio_sample_rate integer Audio sample rate of the media file.
audio_channels string Audio channels of the media file.
video_codec string Video codec of the media file.
video_bit_rate integer Video bit rate of the media file.
frame_height integer Frame height of the media file.
frame_width integer Frame width of the media file.
frame_count integer Frame count of the media file.
frame_rate integer Frame rate of the media file.
page_count integer Total number of pages returned in the search request. (Present in the Search Posts endpoint.)
page_size integer Total number of items per page. (Present in the Search Posts endpoint.)
total_items integer Total number of items returned in the search request. (Present in the Search Posts and Retrieve Post endpoints.)

Request
Headers
Header Value
Accept application/json
Content-Type multipart/form-data
Specific Search Parameters
Parameters Description
video_codec Returns results with the specified video_codec.
audio_codec Returns results with the specified audio_codec.
mime_type Returns results with the specified mime_type.
file_name Returns results with the specified file_name.

Search Media

Retrieve a list of Libsyn media file information by filters.

Request

Send a GET request to the /media endpoint, the show_id search parameter is required:

$ curl https://api.libsyn.com/media?show_id=[:show_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 response:


{
	"_links": {
		"self": {
			"href": "/media"
		},
		"first": {
			"href": "/media?page={page}"
		},
		"prev": {
			"href": "/media?page={page}"
		},
		"next": {
			"href": "/media?page={page}"
		},
		"last": {
			"href": "/media?page={page}"
		}
	}
   "_embedded": {
       "media": [
		{
          "content_id": "(int) - Represents the content id of the media file.",
          "show_id": "(int) - Represents a valid Libsyn show ID (numeric or string) (may also be known as show slug)."
	  	  "file_name": "(string) - File name of the media file."
	  	  "file_size": "(int) - File size of the media file."
	  	  "url": "(string) - URL address of the media file."
	  	  "secure_url": "(string) - Secure URL address of the media file."
	  	  "duration": "(int) - Length of the media file in seconds."
	  	  "id3_title": "(string) - id3 title tag of the media file."
	  	  "id3_author": "(string) - id3 author tag of the media file."
	  	  "id3_artist": "(string) - id3 artist tag of the media file."
	  	  "id3_album": "(string) - id3 album tag of the media file."
	  	  "id3_year": "(string) - id3 year tag of the media file."
	  	  "id3_track": "(string) - id3 track tag of the media file."
	  	  "id3_genre": "(string) - id3 genre tag of the media file."
		  "id3_copyright": "(string) - id3 copyright tag of the media file."
	  	  "id3_comment": "(string) - id3 comment tag of the media file."
	  	  "upload_date": "(string) - Upload date of the media file."
		  "file_class": "(string) - File class of the media file."
		  "mime_type": "(string) - Mime type of the media file."
		  "bit_rate": "(int) - Bit_rate of the media file."
		  "audio_codec": "(string) - Audio codec of the media file."
		  "audio_bit_rate": "(int) - Audio bit rate of the media file."
		  "audio_sample_rate": "(int) - Audio sample rate of the media file."
		  "audio_channels": "(string) - Audio channels of the media file."
		  "video_codec": "(string) - Video codec of the media file."
		  "video_bit_rate": "(int) - Video bit rate of the media file."
		  "frame_height": "(int) - Frame height of the media file."
		  "frame_width": "(int) - Frame width of the media file."
		  "frame_count": "(int) - Frame count of the media file."
		  "frame_rate": "(int) - Frame rate of the media file."
		 }
	   ]
   }
	 "page_count": "(int)	- Total number of pages returned in the search request.",
	 "page_size": "(int)	- Total number of items per page.",
	 "total_items": "(int)	- Total number of items returned in the search request."
}
											
Retrieve Media File

Retrieve information on an individual Libsyn media file.

Request

Send a GET request to the /post endpoint, the show_id search parameter is required:

$ curl https://api.libsyn.com/media[/:content_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 response:


{
 "_links": {
     "self": {
         "href": "media[/:content_id]"
     },
 }
 "_embedded": {
     "media": {
        "content_id": "(int) - Represents the content id of the media file.",
        "show_id": "(int) - Represents a valid Libsyn show ID (numeric or string) (may also be known as show slug)."
  	  "file_name": "(string) - File name of the media file."
  	  "file_size": "(int) - File size of the media file."
  	  "url": "(string) - URL address of the media file."
  	  "secure_url": "(string) - Secure URL address of the media file."
  	  "duration": "(int) - Length of the media file in seconds."
  	  "id3_title": "(string) - id3 title tag of the media file."
  	  "id3_author": "(string) - id3 author tag of the media file."
  	  "id3_artist": "(string) - id3 artist tag of the media file."
  	  "id3_album": "(string) - id3 album tag of the media file."
  	  "id3_year": "(string) - id3 year tag of the media file."
  	  "id3_track": "(string) - id3 track tag of the media file."
  	  "id3_genre": "(string) - id3 genre tag of the media file."
	  "id3_copyright": "(string) - id3 copyright tag of the media file."
  	  "id3_comment": "(string) - id3 comment tag of the media file."
  	  "upload_date": "(string) - Upload date of the media file."
	  "file_class": "(string) - File class of the media file."
	  "mime_type": "(string) - Mime type of the media file."
	  "bit_rate": "(int) - Bit_rate of the media file."
	  "audio_codec": "(string) - Audio codec of the media file."
	  "audio_bit_rate": "(int) - Audio bit rate of the media file."
	  "audio_sample_rate": "(int) - Audio sample rate of the media file."
	  "audio_channels": "(string) - Audio channels of the media file."
	  "video_codec": "(string) - Video codec of the media file."
	  "video_bit_rate": "(int) - Video bit rate of the media file."
	  "frame_height": "(int) - Frame height of the media file."
	  "frame_width": "(int) - Frame width of the media file."
	  "frame_count": "(int) - Frame count of the media file."
	  "frame_rate": "(int) - Frame rate of the media file."
   }
 },
 "total_items": "(int)	- The total number of items returned in the search request."
}
											
Delete Media

Permanently delete an individual Libsyn media file.

Field Type Description
status string The status of the media file you are attempting to delete.
media object Media content_id.
Request

Send a DELETE request to the /media[/:content_id] endpoint:

$ curl https://api.libsyn.com/post[/:item_id]

-X DELETE \

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

-H 'Accept: application/json'


Response

On success, your app will receive the following response:


{
	"status": "(string)		- The status of the media file you are attempting to delete.",
	"media": {
		"id": "(int)		- Represents the content_id of the media file you are attempting to delete."
	}
}