Route: https://kayran.live/api/UploadFile
Users can use this function to Upload Files onto their Storage.
Roles Required: Admin, User and Private User.
Request Syntax
{
“apiKey”: “String”,
“name”: “String”,
“file”: file
}
Request Parameters
Parameters being used in the Request
Parameter Name :
apiKey
Parameter Usage and Options :
Your Kayran given API Key.
How do I get it ? :
Located in the “Profile” section.
Note : by default, the “API Status” is enabled, unless, the Admin has disabled it in the “Server Settings” section.
Type :
String
Is it Optional ? :
No.
Parameter Name :
name
Parameter Usage and Options :
The exact Name of the File you wish to Upload.
For example: file1.txt –> file1.txt (inc. the Extension).
Type :
String
Is it Optional ? :
No.
Parameter Name :
file
Parameter Usage and Options :
The File you wish to Upload.
Type :
Any File.
Is it Optional ? :
No.
Successful Response
{
“Error”: 0,
“Function”: “UploadFile”,
“Data”: “Uploaded Successfully”
}
Errors and their Possible Causes
For more information, please refer to the General Errors section.