Upload Media File Content In CMS
To upload the CMS of KnoxConfigure, use the following methods.
- class
- function
import { KnoxInstance } from '@redredgroup/samsungknox-api';
const instance = new KnoxInstance({
region: 'YOUR_KNOX_REGION',
knoxAccessToken: 'YOUR_JWT_TOKEN',
});
const uploadMediaFileContentInCms = await instance.kcContentManagementAsset.uploadMediaFileContentInCms({
args: {
file: 'YOUR_FILE_PATH',
},
});
console.log(uploadMediaFileContentInCms);
import { kcUploadMediaFileContentInCms } from '@redredgroup/samsungknox-api';
const uploadMediaFileContentInCms = await kcUploadMediaFileContentInCms({
args: {
file: 'YOUR_FILE_PATH',
},
region: 'YOUR-KNOX-REGION',
knoxAccessToken: 'YOUR-X-KNOX-APITOKEN',
});
console.log(uploadMediaFileContentInCms);
Input parameters:
- args: Insert parameters for the upload media file (required) file (for example, _.txt, _.png, _.pdf, _.ogg).
- region: Insert the Knox region. Most of them are EU (case insensitive)
- knoxAccessToken: Your X-KNOX-APITOKEN.
Output:
- Responds with information about the uploaded file.