Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/juliendelplanque/t411
A wrapper for T411 web api written in Pharo.
https://github.com/juliendelplanque/t411
Last synced: 16 days ago
JSON representation
A wrapper for T411 web api written in Pharo.
- Host: GitHub
- URL: https://github.com/juliendelplanque/t411
- Owner: juliendelplanque
- License: mit
- Created: 2015-05-17T20:17:41.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-11-01T12:10:19.000Z (about 9 years ago)
- Last Synced: 2024-10-31T07:05:11.531Z (2 months ago)
- Language: Smalltalk
- Size: 238 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# t411
A wrapper for T411 web api written in Pharo.## Installation
~~~
Metacello new
baseline: 'T411';
repository: 'github://juliendelplanque/t411/repository';
load.
~~~## Use this project as a dependency of your project
~~~
spec baseline: 'T411' with: [
spec repository: 'github://juliendelplanque/t411/repository' ].
~~~## How to use it?
The first thing to do if you want to use T411's api is to get a token:
~~~
api := T4Api new.
token := api retrieveAndSetTokenForUser: 'yourUsername' password: 'yourPassword'.
~~~Once it's done, you can browse the API and download torrents:
~~~
api search: ((T4SearchQuery queryString: 'stuff') limit: 5). "Return a list of 5 T4Torrents."
api me. "Return a T4User that is you!"
api details: 424242. "Get details on the torrent with id 424242."
~~~~~~
"This will download the torrent with id 424242 and store it in /tmp directory."
api download: 424242 in: FileLocator temp named: 'TheBestTorrentFileName'.
~~~