Mercurial > hg > AnnotationManager
view docs/howToTest.txt @ 6:5bb7cc86069c
restlet.jar
author | dwinter |
---|---|
date | Wed, 14 Mar 2012 16:21:45 +0100 |
parents | 77530be3c747 |
children |
line wrap: on
line source
Test POST: curl -i -X POST -d "username=james&xpointer=xx" http://127.0.01:8280/AnnotationManager/annotations curl -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"username":"testname","xpointer":"xx","text":"mytext"}' http://127.0.0.1:8280/AnnotationManager/annotator/annotations curl -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"username":"testname","xpointer":"xx","text":"mytext"}' http://euler.mpiwg-berlin.mpg.de:58080/AnnotationManager/annotator/annotations curl -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d ' {"id": "39fc339cf058bd22176771b3e3187329","created": "2011-05-24T18:52:08.036814","uri": "http://some.uri","text": "A note I wrote", "quote": "The lady said this.","ranges": [{"start": "/p[69]/font/font", "end": "/p[70]/font/font", "startOffset": "0", "endOffset": "120"}], "annotator_schema_version": "v1.0"}' http://127.0.0.1:8280/AnnotationManager/annotator/annotations Test: get: curl -i -H "Accept: application/json" -X GET http://127.0.0.1:8280/AnnotationManager/annotator/annotations?uri=http://www.mpiwg-berlin.mpg.de curl -i -H "Accept: application/json" -X GET http://127.0.0.1:8280/AnnotationManager/annotator/annotations?uri=http://some.uri