Details
-
Bug
-
Status: Closed
-
Resolution: Fixed
-
6.1.30 EE GA3, 6.2.0 CE M3, 7.0.0 M3
-
6.2.x
-
Committed
-
3
Description
It is not possible to upload files from API page:
- Log in as an administrator
- Go to add-file-entry method:
{domain}
/api/jsonws?signature=%2Fdlapp%2Fadd-file-entry-9-repositoryId-folderId-sourceFileName-mimeType-title-description-changeLog-file-serviceContext
- enter data, as follows, and select any file to upload:
repositoryId: Guest groupId
folderId: 0
sourceFileName: some string, like "Test"
mimeType: file extension, like "txt"
title: string
description: string, optional
changeLog: string, optional
Result: API call fails: "No JSON web service action with path /dlapp/add-file-entry and method null for /"
Expected: Results tab shows the JSON object that is returned after uploading the file. Go to Admin > Content > Documents and Media and file uploaded should be listed.
The reason for this is that API page does not really submit a multipart POST request, but a regular one, and the File attribute is therefore missing, and method can not be matched.