radio-t

Radio-T API Wrapper for Python.


Keywords
radio-t, python, api-wrapper, podcast
License
MIT
Install
pip install radio-t==1.0

Documentation

Logo

Simple Radio-T API wrapper for Python. Uses requests library and made with ❤️.

Installation

Using pip

pip install radio_t

Using setuptools

python setup.py install

Using

import radio_t

podcasts = radio_t.get_last_podcasts(count=1)
# [<radio_t.Podcast object at 0x10d7e2240>]
podcast = podcasts[0]

podcast.title
# 'Радио-Т 629'

podcast.url
# 'https://radio-t.com/p/2018/12/22/podcast-629/'

podcast.date
# '2018-12-22T17:11:55-06:00'

podcast.image
# 'https://radio-t.com/images/radio-t/rt629.jpg'

podcast.file_name
# 'rt_podcast629'

podcast.body
# "<p><img src=\"https://ra…=\"none\"></audio></p>\n"

podcast.show_notes
# 'Amazon отослал 1,700 записей из Alexa не туда - 00:02:24.
# Google специально ломает YouTube - 00:09:24.
# И активно отрицает свою вину - 00:14:57.
# Прощай Mongo - 00:21:47.
# Лучшие и худшие гаджеты 2018 года - 00:35:34.
# Go модули в 2019 - 01:03:24.
# Новая модель управления разработкой Python - 01:14:01.
# AWS Client VPN - 01:20:05.
# Google перенёс закрытие Google+ - 01:33:59.
# Темы слушателей - 01:40:01.
# 
# Спонсор этого выпуска DigitalOcean'

podcast.audio_url
# 'http://cdn.radio-t.com/rt_podcast629.mp3'

labels = podcast.time_labels
# [<radio_t.TimeLabel object at 0x10d7e2240>,
# <radio_t.TimeLabel object at 0x10d7d5f60>,
# <radio_t.TimeLabel object at 0x10d7d5ef0>]
label = labels[0]

label.topic
# 'Amazon отослал 1,700 записей из Alexa не туда'

label.time
# '2018-12-21T15:02:24-06:00'

label.duration
# 420

Thanks for your podcasts.