Delete files and folders for datasets and connections

<< Click to Display Table of Contents >>

Current:  System Integration > WebAPI 

Delete files and folders for datasets and connections

Previous pageReturn to chapter overviewNext page

Request address

http://ip:port/bi/api?action=deleteQuery&token=xxxx

Request message

Request parameter

required parameter:xmlData (required)

<?xml version="1.0" encoding="UTF-8"?>

<info>

  <type>connection</type>

  <path>test</path>

</info>

parametric description

Parameter is node information :

1)type(required)Include: data sources, data source folders, datasets(for data set types, see appendix),dataset folder.

2)path(required):Specify the path to a folder (Example is the test folder in the root directory)

Sample

function deleteQueryFolder() {

        var xml = getXml();

        $.post("http://" + ip + ":" + port + "/" + project + "/api?action=deleteQuery&token=xxxx",

           {xmlData : xml},

           function(result) {        

              writeXml(result);

           });

     }

Response message

Response result

 

1)Successful operation

<?xml version="1.0" encoding="UTF-8"?>

<results>

  <result>

     <level>1</level>

     <message>Delete successfully.</message>

  </result>

</results>

2)Operation failure

<?xml version="1.0" encoding="UTF-8"?>

<results>

  <result>

     <level>6</level>

     <message>Folder not found:“test”.</message>

  </result>

</results>

or

<?xml version="1.0" encoding="UTF-8"?>

<results>

  <result>

     <level>6</level>

     <message>Asset not found:“test”.</message>

  </result>

</results>

 

 

Result description