REST WebService /resource/export

 

Initializes an existing resource export context in the planner and retrieves the data it returns.

Query

 

Method

URL

GET

ROOTVP/ws/rest/resource/export

 

Type

Parameters

Values

HEAD

apikey

String

QUERY

export

String

apikey

The user’s API key (must be sent in all the queries). Accesses the WebService for a given user and planner.

export

UID identifier of the resource export context to be initialized.

Response

The response is made up of a structure containing an error code (error), an associated message (message) and, in the event of success, a table (entities) of the resource attributes returned by the export context.

Error

Message

Entities

0

Chaque item du tableau aura la structure suivante :

[

{

« entityName » : « name1 »,

« enityValue » : « value1 »

},

{

« entityName » : « name2 »,

« enityValue » : « value2 »

}

]

1

Invalid session : apikey

2

No export context : exportUID

3

Invalid export context : exportUID

4

Fatal Error : errorMessage

5

No entities found

6

Export KO

Example:

For the “DEMO API REST” planner, installed on a Visual Planning server with the root http ://127.0.0.1:8906/ip50, with a resources export context with the internal UID identifier 22BE-2715-A5FF-8CD9-6D6F-3D1A-F4B4-A5DC and delivering the attributes Customer, Project, Phase, Task, task ref and the UID of the resource. With a user whose access key to the API is: d9f79618-59e4-a710-8203-a39bab9ad09b, we have:

URL:

http://127.0.0.1:8906/ip50/ws/rest/resource/export?export=22BE-2715-A5FF-8CD9-6D6F-3D1A-F4B4-A5DC

Response:

{

“error”:0,

“message”:””,

“entities”:

[

[

{“entityName”:”Client”,”entityValue”:”Client 1″},

{“entityName”:”Projet”,”entityValue”:”Projet 1″},

{“entityName”:”Phase”,”entityValue”:”Phase 1″},

{“entityName”:”Tâche”,”entityValue”:”Analyse”},

{“entityName”:”ref tâche”,”entityValue”:”0080″},

{“entityName”:”UID”,”entityValue”:”A230-6310-E3A5-A6A0-3278-1758-1FE9-B95C”}

],

[

{“entityName”:”Client”,”entityValue”:”Client 1″},

{“entityName”:”Projet”,”entityValue”:”Projet 1″},

{“entityName”:”Phase”,”entityValue”:”Phase 1″},

{“entityName”:”Tâche”,”entityValue”:”Conception”},

{“entityName”:”ref tâche”,”entityValue”:”0083″},

{“entityName”:”UID”,”entityValue”:”9BDA-CA97-501F-4229-81F0-DABF-2DDD-FCFA”}

],

[

{“entityName”:”Client”,”entityValue”:”Client 1″},

{“entityName”:”Projet”,”entityValue”:”Projet 1″},

{“entityName”:”Phase”,”entityValue”:”Phase 1″},

{“entityName”:”Tâche”,”entityValue”:”Développement”},

{“entityName”:”ref tâche”,”entityValue”:”0087″},

{“entityName”:”UID”,”entityValue”:”2664-A826-D2CC-9506-C1BE-8AE4-CAD0-1496″}

],

[

{“entityName”:”Client”,”entityValue”:”Client 1″},

{“entityName”:”Projet”,”entityValue”:”Projet 1″},

{“entityName”:”Phase”,”entityValue”:”Phase 1″},

{“entityName”:”Tâche”,”entityValue”:”Tests”},

{“entityName”:”ref tâche”,”entityValue”:”0102″},

{“entityName”:”UID”,”entityValue”:”D54B-F476-34B0-775A-3032-2A84-501E-860A”}

]

]

}

Print Friendly, PDF & Email
1 Etoile2 Etoiles3 Etoiles4 Etoiles5 Etoiles (No vote)
Loading...
Consulting training

Need training?

Use our consulting services!