Upload a file to MDM for usage in other APIs such as app distribution, content management, and profile configuration Deprecated

Open in ChatGPT Open in ChatGPT to ask questions about this page
Open in Claude Open in Claude to ask questions about this page
Copy as MarkdownCopy this page as markdown to use with AI assistants
View as Markdown Open this page as markdown in a new tab

Uploads a binary file and returns file metadata including a unique file_id for subsequent API calls.

This API endpoint is deprecated

This API is deprecated as of On-Premises build 11.2.2509.XX. Use /emsapi/files for new implementations and migrate existing usage to this endpoint before it is completely removed.

View new endpoint   >
Endpoints

Request URL

https://{serverurl}/api/v1/mdm/files

Scope

MDMOnDemand.MDMDeviceMgmt.CREATECopied!

Header

Authorization: Zoho-oauthtoken d92d4xxxxxxxxxxxxx15f52

- Request Body

multipart/form-data
string

Sample Request

Curl
Java
Python
Deluge
PowerShell
Copied!
curl --request POST \
  --url https://appdomain/api/v1/mdm/files \
  --header 'Authorization: Zoho-oauthtoken  d92d4xxxxxxxxxxxxx15f52' \
  --header 'content-type: multipart/form-data'
Show full

Response Parameters

- HTTP code 200

Response Body - application/json

JSON object
Hide Sub-Attributes
content_typestring

MIME type of the uploaded file. Common values: application/vnd.android.package-archive (apk), application/x-itunes-ipa (ipa), application/zip (appxbundle, xap, appx, msix), application/x-ms-installer (msi)

file_namestring

Name of the uploaded file including its extension

file_idlong

Unique identifier assigned to the uploaded file. Use this ID to check upload status via Get File Upload Status

expiry_timelong

Unix timestamp (in milliseconds) until when the uploaded file is valid. The file will be automatically deleted after this time

content_lengthstring

Length of the uploaded file in bytes

Possible HTTP Status Codes

200HTTP code

Sample Response: HTTP 200

Android APK file successfully uploaded

Copied!
  {
    "content_type": "application/vnd.android.package-archive",
    "file_name": "zylker-app.apk",
    "file_id": 9007199254741076,
    "expiry_time": 15987913528,
    "content_length": 2048576
  }
                
Show full

Image file successfully uploaded

Copied!
  {
    "content_type": "image/png",
    "file_name": "check.png",
    "file_id": 9007199254741076,
    "expiry_time": 15987913528,
    "content_length": 1479
  }
                
Show full

Duration: 1 minute | Threshold: 30 | Lock period: 5 minutes

Duration - Time window for the threshold.
Threshold - Number of API calls allowed within the specified duration.
Lock Period - Wait time before consecutive API requests.