Templates
Template upload
Upload a template to the storage
POST
/
api
/
templates
/
upload
Template upload
curl --request POST \
--url https://{baseUrl}/api/v1/api/templates/upload \
--header 'Content-Type: application/json' \
--data '
{
"templateId": "<string>",
"fileContent": "<string>"
}
'import requests
url = "https://{baseUrl}/api/v1/api/templates/upload"
payload = {
"templateId": "<string>",
"fileContent": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({templateId: '<string>', fileContent: '<string>'})
};
fetch('https://{baseUrl}/api/v1/api/templates/upload', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{baseUrl}/api/v1/api/templates/upload"
payload := strings.NewReader("{\n \"templateId\": \"<string>\",\n \"fileContent\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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))
}{
"path": "<string>"
}⌘I
Template upload
curl --request POST \
--url https://{baseUrl}/api/v1/api/templates/upload \
--header 'Content-Type: application/json' \
--data '
{
"templateId": "<string>",
"fileContent": "<string>"
}
'import requests
url = "https://{baseUrl}/api/v1/api/templates/upload"
payload = {
"templateId": "<string>",
"fileContent": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({templateId: '<string>', fileContent: '<string>'})
};
fetch('https://{baseUrl}/api/v1/api/templates/upload', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{baseUrl}/api/v1/api/templates/upload"
payload := strings.NewReader("{\n \"templateId\": \"<string>\",\n \"fileContent\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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))
}{
"path": "<string>"
}