Update an email template group
curl --request PATCH \
--url https://api.heymilo.ai/api/v2/email-template-groups/{group_id} \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"name": "<string>",
"template_mappings": {},
"sender_email_id": "<string>",
"fallback_to_system_defaults": true
}
'import requests
url = "https://api.heymilo.ai/api/v2/email-template-groups/{group_id}"
payload = {
"name": "<string>",
"template_mappings": {},
"sender_email_id": "<string>",
"fallback_to_system_defaults": True
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
template_mappings: {},
sender_email_id: '<string>',
fallback_to_system_defaults: true
})
};
fetch('https://api.heymilo.ai/api/v2/email-template-groups/{group_id}', 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.heymilo.ai/api/v2/email-template-groups/{group_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'template_mappings' => [
],
'sender_email_id' => '<string>',
'fallback_to_system_defaults' => true
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <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.heymilo.ai/api/v2/email-template-groups/{group_id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"template_mappings\": {},\n \"sender_email_id\": \"<string>\",\n \"fallback_to_system_defaults\": true\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-KEY", "<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.patch("https://api.heymilo.ai/api/v2/email-template-groups/{group_id}")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"template_mappings\": {},\n \"sender_email_id\": \"<string>\",\n \"fallback_to_system_defaults\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.heymilo.ai/api/v2/email-template-groups/{group_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"template_mappings\": {},\n \"sender_email_id\": \"<string>\",\n \"fallback_to_system_defaults\": true\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "E629E33BC4AD",
"name": "Engineering Hiring Emails",
"template_mappings": {
"WEB_INTERVIEW_INVITATION": "B31EB9E73BEE",
"WEB_INTERVIEW_NUDGE": "637CE3438ACA"
},
"created_at": 1739612400,
"updated_at": 1739617200,
"object": "email_template_group",
"sender_email_id": "1BF9F7881AC8",
"fallback_to_system_defaults": true,
"is_default": false
},
"meta": {}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}Update an email template group
Change a group’s name, template mappings, sender address or fallback behavior. Only fields present in the request body are modified; template_mappings replaces the whole mapping. Interviewers using the group pick up the change on their next email.
PATCH
/
api
/
v2
/
email-template-groups
/
{group_id}
Update an email template group
curl --request PATCH \
--url https://api.heymilo.ai/api/v2/email-template-groups/{group_id} \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"name": "<string>",
"template_mappings": {},
"sender_email_id": "<string>",
"fallback_to_system_defaults": true
}
'import requests
url = "https://api.heymilo.ai/api/v2/email-template-groups/{group_id}"
payload = {
"name": "<string>",
"template_mappings": {},
"sender_email_id": "<string>",
"fallback_to_system_defaults": True
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
template_mappings: {},
sender_email_id: '<string>',
fallback_to_system_defaults: true
})
};
fetch('https://api.heymilo.ai/api/v2/email-template-groups/{group_id}', 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.heymilo.ai/api/v2/email-template-groups/{group_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'template_mappings' => [
],
'sender_email_id' => '<string>',
'fallback_to_system_defaults' => true
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <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.heymilo.ai/api/v2/email-template-groups/{group_id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"template_mappings\": {},\n \"sender_email_id\": \"<string>\",\n \"fallback_to_system_defaults\": true\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-KEY", "<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.patch("https://api.heymilo.ai/api/v2/email-template-groups/{group_id}")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"template_mappings\": {},\n \"sender_email_id\": \"<string>\",\n \"fallback_to_system_defaults\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.heymilo.ai/api/v2/email-template-groups/{group_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"template_mappings\": {},\n \"sender_email_id\": \"<string>\",\n \"fallback_to_system_defaults\": true\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "E629E33BC4AD",
"name": "Engineering Hiring Emails",
"template_mappings": {
"WEB_INTERVIEW_INVITATION": "B31EB9E73BEE",
"WEB_INTERVIEW_NUDGE": "637CE3438ACA"
},
"created_at": 1739612400,
"updated_at": 1739617200,
"object": "email_template_group",
"sender_email_id": "1BF9F7881AC8",
"fallback_to_system_defaults": true,
"is_default": false
},
"meta": {}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"error": {
"type": "invalid_request_error",
"code": "validation_error",
"message": "The request body failed validation",
"param": "<string>",
"doc_url": "<string>",
"errors": [
{
"code": "invalid_param",
"message": "title must be between 3 and 200 characters",
"param": "title"
}
]
}
}Authorizations
Body
application/json
Request body for updating an email template group. Send only what changes.
Response
Successful Response
Was this page helpful?