aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2014-06-23 12:25:08 +0200
committerCédric Bonhomme <cedric@cedricbonhomme.org>2014-06-23 12:25:08 +0200
commit8c8710ba3cc33f7764a799ea0d889e77d874ffe9 (patch)
treeee4729ba750573670cdb75f95a94675f481ce5c0
parentDELETE method for the REST service has been implemented. (diff)
downloadnewspipe-8c8710ba3cc33f7764a799ea0d889e77d874ffe9.tar.gz
newspipe-8c8710ba3cc33f7764a799ea0d889e77d874ffe9.tar.bz2
newspipe-8c8710ba3cc33f7764a799ea0d889e77d874ffe9.zip
Updated README.
-rw-r--r--README.rst16
1 files changed, 16 insertions, 0 deletions
diff --git a/README.rst b/README.rst
index c3e494a3..ce804d89 100644
--- a/README.rst
+++ b/README.rst
@@ -187,10 +187,26 @@ Add an article:
{
"message": "ok"
}
+ >>>
>>> r = requests.get("https://pyaggr3g470r.herokuapp.com/api/v1.0/articles?feed=42&limit=1", auth=("your-email", "your-password"))
>>> print json.loads(r.content)["result"][0]["title"]
Sortie de pyAggr3g470r 5.3
>>>
+ >>> r = requests.delete("https://pyaggr3g470r.herokuapp.com/api/v1.0/articles/84574", auth=("root@pyAggr3g470r.localhost", "password"))
+ >>> print r.status_code
+ 200
+ >>> print r.content
+ {
+ "message": "ok"
+ }
+ >>> r = requests.delete("hhttps://pyaggr3g470r.herokuapp.com/api/v1.0/articles/84574", auth=("root@pyAggr3g470r.localhost", "password"))
+ >>> print r.status_code
+ 404
+ >>> print r.content
+ {
+ "code": 404,
+ "message": "Article not found"
+ }
For example you can use this in order to connect pyAggr3g470r to your own crawler.
bgstack15