Template Bundles
Export Bundle
Exports the selected categories/items as a ZIP file (application/zip).
The response is a binary download with Content-Disposition: attachment.
Requires templates.export.
POST
/
api
/
v1
/
templates
/
export
Export Bundle
curl --request POST \
--url https://api.evoai.app/api/v1/templates/export \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '
{
"template_name": "Onboarding default",
"description": "Standard automations and canned responses for new instances",
"author": "Davidson Gomes",
"selection": {
"inboxes": {
"all": true
},
"agents": {
"ids": [
"a1f8...",
"b3c0..."
]
},
"automation_rules": {
"all": true
},
"canned_responses": {
"all": true
}
}
}
'import requests
url = "https://api.evoai.app/api/v1/templates/export"
payload = {
"template_name": "Onboarding default",
"description": "Standard automations and canned responses for new instances",
"author": "Davidson Gomes",
"selection": {
"inboxes": { "all": True },
"agents": { "ids": ["a1f8...", "b3c0..."] },
"automation_rules": { "all": True },
"canned_responses": { "all": True }
}
}
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
template_name: 'Onboarding default',
description: 'Standard automations and canned responses for new instances',
author: 'Davidson Gomes',
selection: {
inboxes: {all: true},
agents: {ids: ['a1f8...', 'b3c0...']},
automation_rules: {all: true},
canned_responses: {all: true}
}
})
};
fetch('https://api.evoai.app/api/v1/templates/export', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.evoai.app/api/v1/templates/export",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'template_name' => 'Onboarding default',
'description' => 'Standard automations and canned responses for new instances',
'author' => 'Davidson Gomes',
'selection' => [
'inboxes' => [
'all' => true
],
'agents' => [
'ids' => [
'a1f8...',
'b3c0...'
]
],
'automation_rules' => [
'all' => true
],
'canned_responses' => [
'all' => true
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"api_access_token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.evoai.app/api/v1/templates/export"
payload := strings.NewReader("{\n \"template_name\": \"Onboarding default\",\n \"description\": \"Standard automations and canned responses for new instances\",\n \"author\": \"Davidson Gomes\",\n \"selection\": {\n \"inboxes\": {\n \"all\": true\n },\n \"agents\": {\n \"ids\": [\n \"a1f8...\",\n \"b3c0...\"\n ]\n },\n \"automation_rules\": {\n \"all\": true\n },\n \"canned_responses\": {\n \"all\": true\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("api_access_token", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.evoai.app/api/v1/templates/export")
.header("api_access_token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"template_name\": \"Onboarding default\",\n \"description\": \"Standard automations and canned responses for new instances\",\n \"author\": \"Davidson Gomes\",\n \"selection\": {\n \"inboxes\": {\n \"all\": true\n },\n \"agents\": {\n \"ids\": [\n \"a1f8...\",\n \"b3c0...\"\n ]\n },\n \"automation_rules\": {\n \"all\": true\n },\n \"canned_responses\": {\n \"all\": true\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.evoai.app/api/v1/templates/export")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["api_access_token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"template_name\": \"Onboarding default\",\n \"description\": \"Standard automations and canned responses for new instances\",\n \"author\": \"Davidson Gomes\",\n \"selection\": {\n \"inboxes\": {\n \"all\": true\n },\n \"agents\": {\n \"ids\": [\n \"a1f8...\",\n \"b3c0...\"\n ]\n },\n \"automation_rules\": {\n \"all\": true\n },\n \"canned_responses\": {\n \"all\": true\n }\n }\n}"
response = http.request(request)
puts response.read_body"<string>"{
"success": false,
"message": "<string>"
}Autorizações
Corpo
application/json
Per-category selection of items. For each category, either
use { all: true } to include everything, or
{ ids: [...] } to cherry-pick.
Show child attributes
Show child attributes
Name of the template bundle (appears in the ZIP manifest)
Optional description of the bundle
Author name (appears in the manifest)
Resposta
ZIP bundle generated
The response is of type file.
⌘I
Export Bundle
curl --request POST \
--url https://api.evoai.app/api/v1/templates/export \
--header 'Content-Type: application/json' \
--header 'api_access_token: <api-key>' \
--data '
{
"template_name": "Onboarding default",
"description": "Standard automations and canned responses for new instances",
"author": "Davidson Gomes",
"selection": {
"inboxes": {
"all": true
},
"agents": {
"ids": [
"a1f8...",
"b3c0..."
]
},
"automation_rules": {
"all": true
},
"canned_responses": {
"all": true
}
}
}
'import requests
url = "https://api.evoai.app/api/v1/templates/export"
payload = {
"template_name": "Onboarding default",
"description": "Standard automations and canned responses for new instances",
"author": "Davidson Gomes",
"selection": {
"inboxes": { "all": True },
"agents": { "ids": ["a1f8...", "b3c0..."] },
"automation_rules": { "all": True },
"canned_responses": { "all": True }
}
}
headers = {
"api_access_token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {api_access_token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
template_name: 'Onboarding default',
description: 'Standard automations and canned responses for new instances',
author: 'Davidson Gomes',
selection: {
inboxes: {all: true},
agents: {ids: ['a1f8...', 'b3c0...']},
automation_rules: {all: true},
canned_responses: {all: true}
}
})
};
fetch('https://api.evoai.app/api/v1/templates/export', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.evoai.app/api/v1/templates/export",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'template_name' => 'Onboarding default',
'description' => 'Standard automations and canned responses for new instances',
'author' => 'Davidson Gomes',
'selection' => [
'inboxes' => [
'all' => true
],
'agents' => [
'ids' => [
'a1f8...',
'b3c0...'
]
],
'automation_rules' => [
'all' => true
],
'canned_responses' => [
'all' => true
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"api_access_token: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.evoai.app/api/v1/templates/export"
payload := strings.NewReader("{\n \"template_name\": \"Onboarding default\",\n \"description\": \"Standard automations and canned responses for new instances\",\n \"author\": \"Davidson Gomes\",\n \"selection\": {\n \"inboxes\": {\n \"all\": true\n },\n \"agents\": {\n \"ids\": [\n \"a1f8...\",\n \"b3c0...\"\n ]\n },\n \"automation_rules\": {\n \"all\": true\n },\n \"canned_responses\": {\n \"all\": true\n }\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("api_access_token", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.evoai.app/api/v1/templates/export")
.header("api_access_token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"template_name\": \"Onboarding default\",\n \"description\": \"Standard automations and canned responses for new instances\",\n \"author\": \"Davidson Gomes\",\n \"selection\": {\n \"inboxes\": {\n \"all\": true\n },\n \"agents\": {\n \"ids\": [\n \"a1f8...\",\n \"b3c0...\"\n ]\n },\n \"automation_rules\": {\n \"all\": true\n },\n \"canned_responses\": {\n \"all\": true\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.evoai.app/api/v1/templates/export")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["api_access_token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"template_name\": \"Onboarding default\",\n \"description\": \"Standard automations and canned responses for new instances\",\n \"author\": \"Davidson Gomes\",\n \"selection\": {\n \"inboxes\": {\n \"all\": true\n },\n \"agents\": {\n \"ids\": [\n \"a1f8...\",\n \"b3c0...\"\n ]\n },\n \"automation_rules\": {\n \"all\": true\n },\n \"canned_responses\": {\n \"all\": true\n }\n }\n}"
response = http.request(request)
puts response.read_body"<string>"{
"success": false,
"message": "<string>"
}