Theme templates
Updates a theme template
Updates a template’s attributes. Send publish: true to publish the saved changes in the same call. Requires the application_themes update permission. Global templates and templates provided by a droplet cannot be edited (403). Changing a template into or out of a page type managed by a dedicated endpoint, such as members_page, is refused with 422.
PATCH
/
api
/
application_theme_templates
/
{id}
Updates a theme template
curl --request PATCH \
--url https://api.fluid.app/api/application_theme_templates/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data @- <<EOF
{
"application_theme_template": {
"name": "Paper Product Page",
"content": "{% layout 'theme' %}\n<section class=\"product\">\n <h1>{{ product.title }}</h1>\n <p class=\"sku\">{{ product.sku }}</p>\n {{ product.description }}\n</section>",
"country_ids": [
214
]
},
"publish": true
}
EOFimport requests
url = "https://api.fluid.app/api/application_theme_templates/{id}"
payload = {
"application_theme_template": {
"name": "Paper Product Page",
"content": "{% layout 'theme' %}
<section class=\"product\">
<h1>{{ product.title }}</h1>
<p class=\"sku\">{{ product.sku }}</p>
{{ product.description }}
</section>",
"country_ids": [214]
},
"publish": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
application_theme_template: {
name: 'Paper Product Page',
content: '{% layout \'theme\' %}\n<section class="product">\n <h1>{{ product.title }}</h1>\n <p class="sku">{{ product.sku }}</p>\n {{ product.description }}\n</section>',
country_ids: [214]
},
publish: true
})
};
fetch('https://api.fluid.app/api/application_theme_templates/{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.fluid.app/api/application_theme_templates/{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([
'application_theme_template' => [
'name' => 'Paper Product Page',
'content' => '{% layout \'theme\' %}
<section class="product">
<h1>{{ product.title }}</h1>
<p class="sku">{{ product.sku }}</p>
{{ product.description }}
</section>',
'country_ids' => [
214
]
],
'publish' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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.fluid.app/api/application_theme_templates/{id}"
payload := strings.NewReader("{\n \"application_theme_template\": {\n \"name\": \"Paper Product Page\",\n \"content\": \"{% layout 'theme' %}\\n<section class=\\\"product\\\">\\n <h1>{{ product.title }}</h1>\\n <p class=\\\"sku\\\">{{ product.sku }}</p>\\n {{ product.description }}\\n</section>\",\n \"country_ids\": [\n 214\n ]\n },\n \"publish\": true\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.fluid.app/api/application_theme_templates/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"application_theme_template\": {\n \"name\": \"Paper Product Page\",\n \"content\": \"{% layout 'theme' %}\\n<section class=\\\"product\\\">\\n <h1>{{ product.title }}</h1>\\n <p class=\\\"sku\\\">{{ product.sku }}</p>\\n {{ product.description }}\\n</section>\",\n \"country_ids\": [\n 214\n ]\n },\n \"publish\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fluid.app/api/application_theme_templates/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"application_theme_template\": {\n \"name\": \"Paper Product Page\",\n \"content\": \"{% layout 'theme' %}\\n<section class=\\\"product\\\">\\n <h1>{{ product.title }}</h1>\\n <p class=\\\"sku\\\">{{ product.sku }}</p>\\n {{ product.description }}\\n</section>\",\n \"country_ids\": [\n 214\n ]\n },\n \"publish\": true\n}"
response = http.request(request)
puts response.read_body{
"application_theme_template": {
"id": 48213,
"name": "Paper Product Page",
"content": "{% layout 'theme' %}\n<section class=\"product\">\n <h1>{{ product.title }}</h1>\n {{ product.description }}\n</section>",
"status": "active",
"themeable_type": "product",
"company_id": 1405,
"variables": {
"show_breadcrumbs": true
},
"created_at": "2026-09-08T14:22:31Z",
"updated_at": "2026-09-21T16:05:47Z",
"default": false,
"translations": {},
"hide_navbar": false,
"use_active_application_theme": false,
"country_ids": [
214
],
"stylesheet": null,
"stylesheet_tag_injected": true,
"stylesheet_column_hidden": true,
"global": false,
"application_theme_id": 7310,
"source": "theme",
"droplet_name": null,
"app_extension_id": null,
"extension_uri": null,
"versions": [
{
"version": 3,
"created_at": "2026-09-21T16:05:47Z",
"published": true,
"current": true,
"author_id": 90412,
"author_name": "Michael Scott"
},
{
"version": 2,
"created_at": "2026-09-15T10:12:03Z",
"published": false,
"current": false,
"author_id": 90415,
"author_name": "Pam Beesly"
}
],
"navbar_template_id": 48190,
"footer_template_id": 48191,
"assigned_themeable_ids": [
30117,
30118
],
"url": "https://shop.dundermifflin.com/products/20lb-copy-paper?preview=true&template_id=48213",
"available_theme_blocks": []
},
"meta": {
"request_id": "4f1c2a9e-7b3d-4e8a-9c61-2d5f8a0b3e17",
"timestamp": "2026-09-22T15:04:12Z"
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}
}Authorizations
Bearer token authentication
Path Parameters
⌘I
Updates a theme template
curl --request PATCH \
--url https://api.fluid.app/api/application_theme_templates/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data @- <<EOF
{
"application_theme_template": {
"name": "Paper Product Page",
"content": "{% layout 'theme' %}\n<section class=\"product\">\n <h1>{{ product.title }}</h1>\n <p class=\"sku\">{{ product.sku }}</p>\n {{ product.description }}\n</section>",
"country_ids": [
214
]
},
"publish": true
}
EOFimport requests
url = "https://api.fluid.app/api/application_theme_templates/{id}"
payload = {
"application_theme_template": {
"name": "Paper Product Page",
"content": "{% layout 'theme' %}
<section class=\"product\">
<h1>{{ product.title }}</h1>
<p class=\"sku\">{{ product.sku }}</p>
{{ product.description }}
</section>",
"country_ids": [214]
},
"publish": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
application_theme_template: {
name: 'Paper Product Page',
content: '{% layout \'theme\' %}\n<section class="product">\n <h1>{{ product.title }}</h1>\n <p class="sku">{{ product.sku }}</p>\n {{ product.description }}\n</section>',
country_ids: [214]
},
publish: true
})
};
fetch('https://api.fluid.app/api/application_theme_templates/{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.fluid.app/api/application_theme_templates/{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([
'application_theme_template' => [
'name' => 'Paper Product Page',
'content' => '{% layout \'theme\' %}
<section class="product">
<h1>{{ product.title }}</h1>
<p class="sku">{{ product.sku }}</p>
{{ product.description }}
</section>',
'country_ids' => [
214
]
],
'publish' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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.fluid.app/api/application_theme_templates/{id}"
payload := strings.NewReader("{\n \"application_theme_template\": {\n \"name\": \"Paper Product Page\",\n \"content\": \"{% layout 'theme' %}\\n<section class=\\\"product\\\">\\n <h1>{{ product.title }}</h1>\\n <p class=\\\"sku\\\">{{ product.sku }}</p>\\n {{ product.description }}\\n</section>\",\n \"country_ids\": [\n 214\n ]\n },\n \"publish\": true\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.fluid.app/api/application_theme_templates/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"application_theme_template\": {\n \"name\": \"Paper Product Page\",\n \"content\": \"{% layout 'theme' %}\\n<section class=\\\"product\\\">\\n <h1>{{ product.title }}</h1>\\n <p class=\\\"sku\\\">{{ product.sku }}</p>\\n {{ product.description }}\\n</section>\",\n \"country_ids\": [\n 214\n ]\n },\n \"publish\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fluid.app/api/application_theme_templates/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"application_theme_template\": {\n \"name\": \"Paper Product Page\",\n \"content\": \"{% layout 'theme' %}\\n<section class=\\\"product\\\">\\n <h1>{{ product.title }}</h1>\\n <p class=\\\"sku\\\">{{ product.sku }}</p>\\n {{ product.description }}\\n</section>\",\n \"country_ids\": [\n 214\n ]\n },\n \"publish\": true\n}"
response = http.request(request)
puts response.read_body{
"application_theme_template": {
"id": 48213,
"name": "Paper Product Page",
"content": "{% layout 'theme' %}\n<section class=\"product\">\n <h1>{{ product.title }}</h1>\n {{ product.description }}\n</section>",
"status": "active",
"themeable_type": "product",
"company_id": 1405,
"variables": {
"show_breadcrumbs": true
},
"created_at": "2026-09-08T14:22:31Z",
"updated_at": "2026-09-21T16:05:47Z",
"default": false,
"translations": {},
"hide_navbar": false,
"use_active_application_theme": false,
"country_ids": [
214
],
"stylesheet": null,
"stylesheet_tag_injected": true,
"stylesheet_column_hidden": true,
"global": false,
"application_theme_id": 7310,
"source": "theme",
"droplet_name": null,
"app_extension_id": null,
"extension_uri": null,
"versions": [
{
"version": 3,
"created_at": "2026-09-21T16:05:47Z",
"published": true,
"current": true,
"author_id": 90412,
"author_name": "Michael Scott"
},
{
"version": 2,
"created_at": "2026-09-15T10:12:03Z",
"published": false,
"current": false,
"author_id": 90415,
"author_name": "Pam Beesly"
}
],
"navbar_template_id": 48190,
"footer_template_id": 48191,
"assigned_themeable_ids": [
30117,
30118
],
"url": "https://shop.dundermifflin.com/products/20lb-copy-paper?preview=true&template_id=48213",
"available_theme_blocks": []
},
"meta": {
"request_id": "4f1c2a9e-7b3d-4e8a-9c61-2d5f8a0b3e17",
"timestamp": "2026-09-22T15:04:12Z"
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}
}{
"message": "<string>",
"error": "<string>",
"error_message": "<string>",
"errors": "<string>",
"meta": {
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z"
}
}