summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md40
1 files changed, 40 insertions, 0 deletions
diff --git a/README.md b/README.md
index 2546c5c..202f307 100644
--- a/README.md
+++ b/README.md
@@ -46,6 +46,11 @@ Note that you can add multiple hosts from which you want to accept API requests.
46a space. 46a space.
47**IMPORTANT:** The default value if the variable is not set is: `Access-Control-Allow-Origin: *` 47**IMPORTANT:** The default value if the variable is not set is: `Access-Control-Allow-Origin: *`
48 48
49Configure another environment variable: `MAT2_MAX_FILES_BULK_DOWNLOAD=10`
50
51This specifies the max number of files that can be bulk downloaded using the api.
52Note: Each file has a max file size of 16mb
53
49Finally, restart uWSGI and your web server: 54Finally, restart uWSGI and your web server:
50 55
51``` 56```
@@ -149,6 +154,41 @@ The `file` parameter is the base64 encoded file which will be cleaned.
149] 154]
150``` 155```
151 156
157**Endpoint:** `/api/download/bulk`
158
159This endpoint allows you to bulk download several files
160which you uploaded beforehand. Note that the `download_list`
161MUST contain more than two files. The max length is configurable
162(default is 10).
163
164**HTTP Verbs:** POST
165
166**Body:**
167```json
168{
169 "download_list": [
170 {
171 "file_name": "uploaded_file_name.jpg",
172 "key": "uploaded_file_key"
173 }
174 ]
175}
176```
177
178The `file_name` parameter takes the file name from a previously uploaded file.
179The `key` parameter is the key from a previously uploaded file.
180
181**Example Response:**
182```json
183{
184 "output_filename": "files.2cd225d5-2d75-44a2-9f26-e120a87e4279.cleaned.zip",
185 "mime": "application/zip",
186 "key": "5ee4cf8821226340d3d5ed16bd2e1b435234a9ad218f282b489a85d116e7a4c4",
187 "meta_after": {},
188 "download_link": "http://localhost/api/download/5ee4cf8821226340d3d5ed16bd2e1b435234a9ad218f282b489a85d116e7a4c4/files.2cd225d5-2d75-44a2-9f26-e120a87e4279.cleaned.zip"
189}
190```
191
152# Docker 192# Docker
153There are two Dockerfiles present in this repository. The file called `Dockerfile.development` is used for development 193There are two Dockerfiles present in this repository. The file called `Dockerfile.development` is used for development
154and `Dockerfile.production` is used for production deployments. 194and `Dockerfile.production` is used for production deployments.