From 6d260af932b53aefe45c981305edc81272a6ed56 Mon Sep 17 00:00:00 2001 From: Thor77 Date: Sat, 8 Aug 2015 11:47:09 +0200 Subject: [PATCH] convert api-description into table --- README.md | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 1604cc9..97ae27a 100644 --- a/README.md +++ b/README.md @@ -260,14 +260,13 @@ The encryption is made on the server since Lutim is made to be usable even witho ## API You can add images by using the API. Here's the parameters of the `POST` request to `/` adress:. -* format: json - MANDATORY if you want to get a json response, otherwise it will send a web page -* file: the image file - MANDATORY -* delete-day: number of days you want the image to stay - OPTIONAL if 0, it will be available undefinitely -* first-view: 1 - OPTIONAL if not 0, the image will be deleted at first view + +|name|type|description|optional/default| +|----|----|-----------|--------| +|format|string|`json` if you want to get a json response, otherwise it will send a web page|| +|file|file|the image file|| +|delete-day|int|number of days you want the image to stay|0 (undefinitely)| +|first-view|int|if not 0, the image will be deleted at first view|0| Exemple with curl: