import requests
url = "https://{FUSION_HOST}/api/objects/export"
response = requests.get(url)
print(response.text)HttpResponse<String> response = Unirest.get("https://{FUSION_HOST}/api/objects/export")
.asString();const options = {method: 'GET'};
fetch('https://{FUSION_HOST}/api/objects/export', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));require 'uri'
require 'net/http'
url = URI("https://{FUSION_HOST}/api/objects/export")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodypackage main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{FUSION_HOST}/api/objects/export"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{FUSION_HOST}/api/objects/export",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}curl --request GET \
--url https://{FUSION_HOST}/api/objects/export{
"objects": {
"collections": [
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"searchClusterId": "<string>",
"autoCommit": 15,
"autoSoftCommit": false,
"commitWithin": 10000,
"features": {},
"compositeIdSpec": {
"routeKey1Field": "<string>",
"routeKey1Bits": 123,
"routeKey2Field": "<string>",
"routeKey2Bits": 123
},
"solrParams": {
"name": "<string>",
"numShards": 123,
"replicationFactor": 123,
"collection.configName": "<string>"
},
"modifiedAt": "2023-11-07T05:31:56Z",
"type": "DATA",
"relatedCollectionId": "<string>",
"metadata": {}
}
],
"indexPipelines": [
{
"id": "<string>"
}
],
"queryPipelines": [
{
"id": "<string>"
}
],
"searchClusters": [
{
"id": "<string>",
"connectString": "<string>",
"zkClientTimeout": 123,
"zkConnectTimeout": 123,
"cloud": true,
"bufferFlushInterval": 123,
"bufferSize": 123,
"concurrency": 123,
"authConfig": {
"authType": "NONE",
"username": "<string>",
"password": "<string>",
"keyTab": "<string>",
"principal": "<string>"
},
"validateCluster": true
}
],
"features": {},
"indexProfiles": [
{
"id": "<string>"
}
],
"queryProfiles": [
{
"id": "<string>"
}
],
"parsers": [
{
"id": "<string>"
}
],
"objectGroups": [
{
"id": "<string>",
"name": "<string>",
"isSystem": true,
"description": "<string>"
}
],
"links": [
{
"subject": "<string>",
"object": "<string>",
"linkType": "dependsOn",
"originator": "<string>"
}
],
"tasks": [
{
"id": "<string>",
"type": "<string>"
}
],
"jobs": [
{
"resource": "<string>",
"enabled": true,
"triggers": [
{
"enabled": true,
"type": "interval",
"startTime": "2023-11-07T05:31:56Z",
"endTime": "2023-11-07T05:31:56Z",
"interval": 123,
"repeatUnit": "minute",
"value": "<string>",
"jobID": "<string>",
"runOnSuccess": true,
"runOnFailure": true,
"runOnAbort": true
}
],
"default": true
}
],
"sparkJobs": [
{
"id": "<string>"
}
],
"blobs": [
{
"id": "<string>",
"path": "<string>",
"dir": "<string>",
"filename": "<string>",
"contentType": "<string>",
"size": 123,
"modifiedTime": "2023-11-07T05:31:56Z",
"version": 123,
"md5": "<string>",
"metadata": {}
}
],
"experiments": [
{
"id": "<string>"
}
],
"appkitApps": [
{
"appkitApp": {
"id": "<string>",
"name": "<string>",
"description": "<string>",
"contextPath": "<string>",
"enabled": true,
"type": "<string>",
"war": "<string>",
"warMd5": "<string>",
"warSize": 123
},
"editingSessions": [
{
"id": "<string>",
"owner": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"version": "<string>"
}
]
}
],
"fusionApps": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>"
}
],
"customRules": [
{
"id": "<string>"
}
],
"templates": [
{
"id": "<string>"
}
],
"zones": [
{
"id": "<string>"
}
],
"subscriptions": [
{
"id": "<string>"
}
],
"templateSettings": [
{
"id": "<string>",
"app": "<string>"
}
],
"dataModels": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"indexPipeline": "<string>",
"queryPipeline": "<string>",
"fields": [
{
"name": "<string>",
"description": "<string>",
"required": true,
"mappings": [
{
"solrField": "<string>",
"queryField": true,
"phraseMatch": true,
"boostValue": 123,
"phraseBoost": 123
}
]
}
]
}
],
"dataSources": [
{
"id": "<string>",
"created": "2023-11-07T05:31:56Z",
"modified": "2023-11-07T05:31:56Z",
"connector": "<string>",
"type": "<string>",
"description": "<string>",
"pipeline": "<string>",
"parserId": "<string>",
"properties": {}
}
]
},
"properties": [
{
"id": "<string>",
"schema": {
"type": "<string>",
"title": "<string>",
"description": "<string>",
"hints": [
"<string>"
]
}
}
],
"metadata": {
"formatVersion": "<string>",
"exportedBy": "<string>",
"exportedDate": "<string>",
"fusionVersion": "<string>",
"fusionGuid": "<string>"
}
}Export objects
Export Fusion objects as a zip file. To get JSON instead, send the header Accept: application/json. Omit parameters to export all objects.
By default, Fusion system objects aren’t exported, even if you request them by ID. To include them, set filterPolicy to none.
Exporting a collection includes its features. To include related objects such as profiles, pipelines, and datasources, request them by type or ID, or set deep=true.
Encrypted values, such as passwords, are replaced with variables whose names start with secret., for example secret.dataSources.DATASOURCE_ID.password, or secret.queryPipelines.PIPELINE_ID.bindPassword for an Active Directory security trimming stage. To list the variables in an export file, use /objects/substitutions. Supply the values when you import the file.
When you export an app that includes objects shared with other apps, all apps linked to those objects are also exported.
You can import a file exported from any Fusion 5.x version into any Fusion 5.x version. Files exported from Fusion 4.1 and 4.2 are also accepted. Other source versions fail validation.
If a large export times out, increase your client’s timeout, for example with curl’s --max-time option.
curl -u USERNAME:PASSWORD "https://FUSION_HOST/api/objects/export?app.ids=APP_ID" > app.zip
import requests
url = "https://{FUSION_HOST}/api/objects/export"
response = requests.get(url)
print(response.text)HttpResponse<String> response = Unirest.get("https://{FUSION_HOST}/api/objects/export")
.asString();const options = {method: 'GET'};
fetch('https://{FUSION_HOST}/api/objects/export', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));require 'uri'
require 'net/http'
url = URI("https://{FUSION_HOST}/api/objects/export")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodypackage main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://{FUSION_HOST}/api/objects/export"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{FUSION_HOST}/api/objects/export",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}curl --request GET \
--url https://{FUSION_HOST}/api/objects/export{
"objects": {
"collections": [
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"searchClusterId": "<string>",
"autoCommit": 15,
"autoSoftCommit": false,
"commitWithin": 10000,
"features": {},
"compositeIdSpec": {
"routeKey1Field": "<string>",
"routeKey1Bits": 123,
"routeKey2Field": "<string>",
"routeKey2Bits": 123
},
"solrParams": {
"name": "<string>",
"numShards": 123,
"replicationFactor": 123,
"collection.configName": "<string>"
},
"modifiedAt": "2023-11-07T05:31:56Z",
"type": "DATA",
"relatedCollectionId": "<string>",
"metadata": {}
}
],
"indexPipelines": [
{
"id": "<string>"
}
],
"queryPipelines": [
{
"id": "<string>"
}
],
"searchClusters": [
{
"id": "<string>",
"connectString": "<string>",
"zkClientTimeout": 123,
"zkConnectTimeout": 123,
"cloud": true,
"bufferFlushInterval": 123,
"bufferSize": 123,
"concurrency": 123,
"authConfig": {
"authType": "NONE",
"username": "<string>",
"password": "<string>",
"keyTab": "<string>",
"principal": "<string>"
},
"validateCluster": true
}
],
"features": {},
"indexProfiles": [
{
"id": "<string>"
}
],
"queryProfiles": [
{
"id": "<string>"
}
],
"parsers": [
{
"id": "<string>"
}
],
"objectGroups": [
{
"id": "<string>",
"name": "<string>",
"isSystem": true,
"description": "<string>"
}
],
"links": [
{
"subject": "<string>",
"object": "<string>",
"linkType": "dependsOn",
"originator": "<string>"
}
],
"tasks": [
{
"id": "<string>",
"type": "<string>"
}
],
"jobs": [
{
"resource": "<string>",
"enabled": true,
"triggers": [
{
"enabled": true,
"type": "interval",
"startTime": "2023-11-07T05:31:56Z",
"endTime": "2023-11-07T05:31:56Z",
"interval": 123,
"repeatUnit": "minute",
"value": "<string>",
"jobID": "<string>",
"runOnSuccess": true,
"runOnFailure": true,
"runOnAbort": true
}
],
"default": true
}
],
"sparkJobs": [
{
"id": "<string>"
}
],
"blobs": [
{
"id": "<string>",
"path": "<string>",
"dir": "<string>",
"filename": "<string>",
"contentType": "<string>",
"size": 123,
"modifiedTime": "2023-11-07T05:31:56Z",
"version": 123,
"md5": "<string>",
"metadata": {}
}
],
"experiments": [
{
"id": "<string>"
}
],
"appkitApps": [
{
"appkitApp": {
"id": "<string>",
"name": "<string>",
"description": "<string>",
"contextPath": "<string>",
"enabled": true,
"type": "<string>",
"war": "<string>",
"warMd5": "<string>",
"warSize": 123
},
"editingSessions": [
{
"id": "<string>",
"owner": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"version": "<string>"
}
]
}
],
"fusionApps": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>"
}
],
"customRules": [
{
"id": "<string>"
}
],
"templates": [
{
"id": "<string>"
}
],
"zones": [
{
"id": "<string>"
}
],
"subscriptions": [
{
"id": "<string>"
}
],
"templateSettings": [
{
"id": "<string>",
"app": "<string>"
}
],
"dataModels": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"indexPipeline": "<string>",
"queryPipeline": "<string>",
"fields": [
{
"name": "<string>",
"description": "<string>",
"required": true,
"mappings": [
{
"solrField": "<string>",
"queryField": true,
"phraseMatch": true,
"boostValue": 123,
"phraseBoost": 123
}
]
}
]
}
],
"dataSources": [
{
"id": "<string>",
"created": "2023-11-07T05:31:56Z",
"modified": "2023-11-07T05:31:56Z",
"connector": "<string>",
"type": "<string>",
"description": "<string>",
"pipeline": "<string>",
"parserId": "<string>",
"properties": {}
}
]
},
"properties": [
{
"id": "<string>",
"schema": {
"type": "<string>",
"title": "<string>",
"description": "<string>",
"hints": [
"<string>"
]
}
}
],
"metadata": {
"formatVersion": "<string>",
"exportedBy": "<string>",
"exportedDate": "<string>",
"fusionVersion": "<string>",
"fusionGuid": "<string>"
}
}Query Parameters
Whether to include linked objects. For apps, linked objects are included unless you set deep=false. For other object types, set deep=true to include them. Combining deep=true with a type value but no IDs, such as type=datasource&deep=true, returns an error. Use type.ids to name the objects instead.
Was this page helpful?