Bibblio API Python
Python wrapper of Bibblio API
Register in Bibblio and get your CLIENT_ID and CLIENT_SECRET
Install
pip install bibbliothon
Configuration
import bibbliothon
set client_id and client_secret
bibbliothon.client_id = 'YOUR_CLIENT_ID'
bibbliothon.client_secret = 'YOUR_CLIENT_SECRET'
get access_token
bibbliothon.access_token = bibblio.Token.get_access_token()['access_token']
- the access token has a duration of 5 minutes, remember to update it.
Usage
For more information use Bibblio API Documentation
- payload is always a dict
- limit and page are optional and integers
- text is a string
- content_item_id is a string
Discovery
response = bibbliothon.Discovery.content_recommendations(content_item_id)
(Legacy) response = bibbliothon.Discovery.recommendations(payload)
Enrichment
response = bibbliothon.Enrichment.create_content_item(payload)
response = bibbliothon.Enrichment.get_content_items(limit=10, page=1)
response = bibbliothon.Enrichment.get_content_item(content_item_id)
response = bibbliothon.Enrichment.update_content_item(content_item_id, payload)
response = bibbliothon.Enrichment.delete_content_item(content_item_id)
(Legacy) response = bibbliothon.Enrichment.metadata(text)