POST deleteFile

POST deleteFile

Method Description

This function allows you to delete a file in an external file storage location.

Returns

The file was deleted successfully

Limitations

None

Usage

For notes on how to authenticate see NetSuite documentation.
General usage notes see: File Sync REST API

Since

FileSync 0.6.0

Request Parameters

ParameterTypeRequiredDescriptionSince
options.script
stringrequiredStatic value that has to equal customscript_b4cd_fileapi_rl0.6.0
options.deploy

string

required

Static value that has to equal customdeploy_b4cd_fileapi_rl

0.6.0

Request Body

Note: The options parameter is a JavaScript object.

ParameterTypeRequiredDescriptionSince
options.action
stringrequired 

Value must equal "deleteFile"
This value represents the method that is called.

0.6.0
options.recordTypeConfigId

integer

required

Internal ID of the FileSync Record Type Configuration record (customrecord_b4cd_record_type_config).

0.6.0

options.fileUniqueId

stringrequired*The unique ID of the file for which the content is being requested. This value is generally retrieved by making a call to the getRecordFolderContents or the getFolderContentsByPath method.
*Optional - Can use options.fileUniquePath as below
0.6.0
options.filePath

string


optional


Server relative path of the file in SharePoint


0.6.0

Errors

Error CodeDetails
SSS_MISSING_REQD_ARGUMENT

A required argument is missing or undefined.

Example Request Body

{
    "fileUniqueId":"fa004411-8638-45f4-ae3e-075be2f55fb4",
    "recordTypeConfigId":3,
    "action":"deleteFile"
}

Was this article helpful?