> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://docs.itential.com/itential-platform/2023-2/api-reference/prebuilts/export-prebuilt/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.itential.com/_mcp/server. # Export a prebuilt GET http://localhost:3000/prebuilts/{id}/export Exports a prebuilt from Itential Platform. Reference: https://docs.itential.com/itential-platform/6/api-reference/prebuilts/export-prebuilt ## Authentication - `Authorization` header (basic auth, required) — Basic authentication of the form `Basic `. ## Request ### Path parameters - `id` (string, required) — The object id of the selected prebuilt. ## Response ### 200 The data for a prebuilt. - `metadata` (object, required) - `name` (string, required) - `version` (string, required) - `description` (string, required) - `author` (string, required) - `license` (string, required) - `repository` (object, required) - `type` (enum, required) - Allowed values: `local`, `gitlab`, `git` - `hostname` (string, optional) - `path` (string, optional) - `IAPDependencies` (object, required) - `keywords` (list of string, optional) - `gitlabId` (integer, optional) - `manifest` (object, required) - `bundleName` (string, required) - `artifacts` (list of object, required) - `id` (string, optional) - `name` (string, optional) - `type` (enum, optional) - Allowed values: `automation`, `forms`, `golden-config`, `integration`, `integration-model`, `json-forms`, `mop-template`, `mop-analytic-template`, `service-catalog`, `template`, `transformation`, `workflow` - `location` (string, optional) - `fingerprint` (string, optional) - `createdEpoch` (string, optional) - `bundles` (list of object, required) - `type` (enum, required) - Allowed values: `automation`, `forms`, `golden-config`, `integration`, `integration-model`, `json-forms`, `mop-template`, `mop-analytic-template`, `service-catalog`, `template`, `transformation`, `workflow` - `data` (object, required) - `readme` (string, required) ## Errors ### 500 Internal Server Error Error response from API - `any` ## Examples **Response** ```json { "metadata": { "name": "@itentialopensource/aggregate-functions-for-arrays", "version": "0.0.1", "description": "A basic description", "author": "Itential Artifacts", "license": "Apache-2.0", "repository": { "type": "local", "hostname": "gitlab.com", "path": "/itentialopensource/pre-built-automations" }, "IAPDependencies": {}, "keywords": [ "Itential" ], "gitlabId": 17866482 }, "manifest": { "bundleName": "aggregateFunctions", "artifacts": [ { "id": "5e5ea3bd16da51d52b4a8f9f", "name": "aggregateFunctions", "type": "automation", "location": "/bundles/workflows/IAP Test Artifact Workflow.json" } ], "fingerprint": "5e84f892c5eab11ec2eee16d", "createdEpoch": "1585772690392" }, "bundles": [ { "type": "automation", "data": {} } ], "readme": "example of readme" } ``` **SDK Code** ```python import requests url = "http://localhost:3000/prebuilts/id/export" response = requests.get(url) print(response.json()) ``` ```javascript const url = 'http://localhost:3000/prebuilts/id/export'; const options = {method: 'GET'}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "http://localhost:3000/prebuilts/id/export" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("http://localhost:3000/prebuilts/id/export") http = Net::HTTP.new(url.host, url.port) request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("http://localhost:3000/prebuilts/id/export") .asString(); ``` ```php request('GET', 'http://localhost:3000/prebuilts/id/export'); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("http://localhost:3000/prebuilts/id/export"); var request = new RestRequest(Method.GET); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let request = NSMutableURLRequest(url: NSURL(string: "http://localhost:3000/prebuilts/id/export")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```