Files
Add a file to MDM for usage in other API.
End Points
Attribute
content_type
string
Content Type :
| File Extension | Platform | Content type |
|---|---|---|
| apk | Android | application/vnd.android.package-archive |
| ipa | iOS | application/x-itunes-ipa |
| appxbundle | Windows | application/zip |
| xap | Windows | application/zip |
| appx | Windows | application/zip |
| msi | Windows | application/x-ms-installer |
| msix | Windows | application/zip |
file_name
string
Name of File
file_id
long
Unique Identifier for the file
expiry_time
long
Timestamp until when the file is valid
content_length
integer
Length of the file (in bytes)
Upload a file to MDM Deprecated
⚠️ Deprecation Notice:
/api/v1/mdm/files 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.
Upload a file
oauthscope : MDMOnDemand.MDMDeviceMgmt.CREATE
POST - /api/v1/mdm/files
Header
Content-Disposition
string
(Required)
Name of file with extension
Arguments
stream
bytestream
(Required)
bytestream of the file
Upload a File to MDM Using Module Configuration Recommended
✅ Recommended API:
This is the recommended API for file uploads starting from On-Premises build 11.2.2509.XX. It replaces the deprecated
/api/v1/mdm/files API and provides enhanced functionality with module configuration support. For file upload-related queries, please contact support.
Upload file to the server using module configuration. Supported file types include images, audios, videos, certificates and many more.
oauthscope : MDMOnDemand.MDMDeviceMgmt.CREATE
POST - /emsapi/files
Header
Module
string
(Required)
Specifies the module configuration where the uploaded file will be used.
Example: MDM_PROFILES_IMAGES - used for images in profile creation and modification.
Below are some commonly used modules. Additional module configurations are documented in their respective API references.
Example: MDM_PROFILES_IMAGES - used for images in profile creation and modification.
Below are some commonly used modules. Additional module configurations are documented in their respective API references.
| Module Name | Description | Supported File Types |
|---|---|---|
| MDM_CERTIFICATES | Upload security certificates for device authentication and encryption | .cer, .crt, .pem, .pfx, .p12 |
| MDM_APP_MGMT | Upload application packages for distribution to managed devices | .apk, .ipa, .xap, .msix, .msixbundle, .appx, .appxbundle, .pkg |
| MDM_CUSTOM_PROFILE | Upload custom configuration profiles for advanced device settings | .xml, .mobileconfig, .plist, .json |
| MDM_CONTENT_MGMT | Upload content files for distribution to devices (documents, media, etc.) | Various file types |
| MDM_APP_REPOSITORY_CUSTOM_CONFIG | Upload custom app configuration files for managed application settings | .xml, .plist |
Request Body
In that Multipart-from request the key should be "file" and the value should be the file content(binary).