LoginSignup
1
1

More than 3 years have passed since last update.

Register RSS with api call to Feedly

Last updated at Posted at 2020-01-15

banner-feedly.jpg

✍ Intro

I recorded how to register rss with api calls to Feedly.
I used python.

Test environment

  • Python 3.7.4

Precondition

access token is required.
1. https://developer.feedly.com/v3/developer/ > Start here
feedly01.png
2. Sign in (ex: Google)
feedly02-1.png
feedly02-2.png
feedly03.png
3. Check Email > Click link
feedly04.png
4. Get access token 🔑
feedly05.png
id is also required.
- Get id 👌
Click Feed(ex: FROM-API) to get '/user...' id from url.
feedly06.png

Execution

Pre installation

$ pip install requests

Source code

$ vi add_rss.py
import requests
import json

access_token = 'AyxlSuDt3...8iw8u3vDqsxjU:feedlydev' # your token

headers = {
    'Authorization': 'OAuth ' + access_token
}

feed_url = "feed/" + "http://feeds.feedburner.com/Techcrunch" # Techcrunch rss url
name = "Techcrunch Blog"

data = {
    # FROM-API
    "id": "user/9211547f-644f-43a4-abad-77b184ce7d2b/category/c93b4c22-c73b-42d0-99c2-3fa1686da6b4",
    "feeds": [
        {
            "id": feed_url,
            "title": name
        }
    ]
}

res = requests.post('https://cloud.feedly.com/v3/collections', headers=headers, data=json.dumps(data), verify=False)
print (res.text)

💻 Execution Result

$ python ./add_rss.py
[{"customizable":true,"feeds":[{"id":"feed/http://feeds.feedburner.com/Techcrunch","feedId":"feed/http://feeds.feedburner.com/Techcrunch","title":"Techcrunch Blog","updated":1578669433716,"velocity":147.9,"topics":["tech"],"subscribers":1094984,"website":"https://techcrunch.com","partial":false,"estimatedEngagement":211,"contentType":"longform","language":"en","description":"TechCrunch is a group-edited blog that profiles the companies, products and events defining and transforming the new web."}],"label":"FROM-API","created":1578667348184,"enterprise":false,"numFeeds":1,"id":"user/9211547f-644f-43a4-abad-77b184ce7d2b/category/c93b4c22-c73b-42d0-99c2-3fa1686da6b4"}]

feedly07.png

Quota

  • Free users : max 250 api requests per day 😅
  • Pro&Team : max 500 api requests per day
1
1
4

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1