Tika 2262: Change route "/getcaptions" into "/captions"
@@ -128,17 +128,17 @@ def index():
<li> <code>/ping </code> - <br/>
<b> Description : </b> checks availability of the service. returns "pong" with status 200 when it is available
</li>
- <li> <code>/getcaptions</code> - <br/>
+ <li> <code>/captions</code> - <br/>
<table>
<tr><th align="left"> Description </th><td> This is a service that can caption images</td></tr>
<tr><th align="left"> How to supply Image Content </th></tr>
<tr><th align="left"> With HTTP GET : </th> <td>
Include a query parameter <code>url </code> which is an http url of JPEG image <br/>
- Example: <code> curl "localhost:8764/getcaptions?url=http://xyz.com/example.jpg"</code>
+ Example: <code> curl "localhost:8764/captions?url=http://xyz.com/example.jpg"</code>
</td></tr>
<tr><th align="left"> With HTTP POST :</th><td>
POST JPEG image content as binary data in request body. <br/>
- Example: <code> curl -X POST "localhost:8764/getcaptions" --data-binary @example.jpg </code>
+ Example: <code> curl -X POST "localhost:8764/captions" --data-binary @example.jpg </code>
</td></tr>
</table>
</li>
@@ -154,7 +154,7 @@ def ping_pong():
return "pong"
-@app.route("/getcaptions", methods=["GET", "POST"])
+@app.route("/captions", methods=["GET", "POST"])
def get_captions():
"""API to caption images"""
