Create an export package
post
/AgentWeb/api/elementmanager/export/EMPackages
Creates an Element Manger export package
Request
Header Parameters
-
API_VERSION: string
API VERSION for the headerDefault Value:
1
Allowed Values:[ "1" ]
-
USERSESSION(required): string
Authentication token for the header
For new exports, specify the name and id of items to be exported.
For excluding items from exported packages, specify export id and items to be deleted
Root Schema : EMPackage
Type:
Show Source
object
-
desc:
string
-
excludedItems:
array excludedItems
Array of items to be excluded in exclude request
-
id:
number
Id of the item
-
ignoreDependencies:
boolean
Set to true if package has to be exported without dependencies
-
isExcludeItemsRequest:
boolean
Set to true if some items are to be removed. If set to true, specify the items to be excluded under excludedItems parameter
-
items:
array items
-
name:
string
Name of the item to be exported (required for custom scripts)
Example:
{
"name":"sample",
"desc":"description",
"items":[
{
"id":"0",
"type":"Workspace"
}
]
}
Nested Schema : excludedItems
Type:
array
Array of items to be excluded in exclude request
Show Source
Nested Schema : ExcludedItem
Type:
Show Source
object
-
id(required):
integer(int64)
Id of the item to be removed, obtained from the GET package status API
-
key:
string
-
type(required):
string
Allowed Values:
[ "Report", "Workspace", "DesktopAddIn", "BrowserExtension", "NavigationSet", "CustomObject", "SystemAttribute", "StandardText", "Variable", "ObjectEventHandler", "ConfigurationSetting", "MessageBase", "BusinessRule", "BusinessRuleVariable", "WorkspaceScript", "ExternalObject", "Image", "WorkflowImage", "CustomScript" ]
Nested Schema : EMItem
Type:
Show Source
object
-
id:
integer(int64)
-
key:
string
-
name:
string
-
phpVersion:
string
The PHP version of the file
-
subFolderPath:
string
-
type(required):
string
Allowed Values:
[ "Report", "Workspace", "AddIn", "NavigationSet", "CustomObject", "SystemAttribute", "StandardText", "Variable", "ObjectEventHandler", "ConfigurationSetting", "MessageBase", "BusinessRule", "BusinessRuleVariable", "WorkspaceScript", "ExternalObject", "CustomScript" ]
Response
Supported Media Types
- application/json
200 Response
Status of export
Nested Schema : EMPackageStatus
Type:
Show Source
object
-
code(required):
integer
-
description(required):
string
-
errorCode(required):
string
Error details of the item
Examples
The following example shows how to create an export package.
cURL Command Example
curl -X POST https://mysite.example.com/AgentWeb/api/elementmanager/export/EMPackages -H "USERSESSION: feihg98GnT7i" -H "API_VERSION: 1" -H "Content-Type: application/json" -d "{ \"name\": \"Test Em ext\", \"desc\": \"Export testing em extension\", \"items\": [ { \"id\": 101810, \"type\": \"Report\" } ] }"
Request Body Example
The following shows an example of the request body in JSON format.
{ "name": "Test Em ext", "desc": "Export testing em extension", "items": [ { "id": 101810, "type": "Report" } ] }
Response Body Example
The following shows an example of the response body in JSON format.
{ "description": "Prepare package for export", "id": 100012, "name": "Test Em ext", "status": { "code": "1", "description": "Export prepare start" }, "href": "http://mysite.example.com/AgentWeb/api/elementmanager/export/EMPackages/100012" }