Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/coolq1000/devrant-python-api
Another unofficial https://www.devrant.io api
https://github.com/coolq1000/devrant-python-api
Last synced: 3 months ago
JSON representation
Another unofficial https://www.devrant.io api
- Host: GitHub
- URL: https://github.com/coolq1000/devrant-python-api
- Owner: coolq1000
- License: wtfpl
- Created: 2017-08-27T00:33:12.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2017-08-28T00:14:39.000Z (about 7 years ago)
- Last Synced: 2024-06-23T11:40:49.514Z (5 months ago)
- Language: Python
- Homepage:
- Size: 5.86 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-devrant - devRant-Python-API - Another Python wrapper for the devRant API (Uncategorized / Uncategorized)
README
# devrant-python-api
Another unofficial https://www.devrant.io api.
## Installation
To include this into your project, it is very simple, all you must do is download(clone) this repo, and extract it in the same directory as your project, then import it.Here is what your directory tree should look a little like.
```
Project/
DevrantAPI/
devrant.py
scriptthatispartoftheproject.py
..etc.
```## Usage
To use this library, you must first import it.
```python
from Devrant import devrant
```Now we can create our devrant object.
```python
dr = devrant.Devrant()
```Then we can call some functions.
```python
dr.get_rants('SORT', LIMIT, SKIP)
dr.get_rant('SORT', INDEX)
dr.get_user_id('NAME')
dr.get_profile(ID)
dr.get_search('TERM')
```## Options
There are a few different options to choose from, in the above example you may have noticed `SORT`, `LIMIT`..etc.
These are options, here are what you can choose from.
```
get_rants():
SORT - STRING:
algo,
recent,
top
LIMIT - INTEGER:
0-50
SKIP - INTEGER:
0-~788
get_rant():
SORT - STRING:
algo,
recent,
top
INDEX - INTEGER:
0-~788
get_user_id():
NAME - STRING:
ANY STRING
get_profile():
ID - INTEGER:
0-?
get_search():
TERM - STRING:
ANY STRING
```If you are stuck you may look at the demo at the bottom of the api script.
Hope this API comes in handy!