Clone Branding Theme
POST {{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone
The POST /environments/{{envID}}/themes/{{themeID}}/clone endpoint clones the branding configuration theme specified by its ID in the request URL. Cloning a branding theme creates a new theme with a configuration that is identical to the source. The new theme inherits the source template, gets a new UUID, is not set as default, and its configuration.name becomes <existing-name>-Clone (or Clone when the source name property is empty). The response is similar to a create request with HAL links pointing at /environments/{environmentID}/themes/{{newThemeId}}. This POST request uses an empty request body.
Example Request
-
cURL
-
C#
-
Go
-
HTTP
-
Java
-
jQuery
-
NodeJS
-
Python
-
PHP
-
Ruby
-
Swift
curl --location --globoff --request POST '{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone' \
--header 'Authorization: Bearer {{accessToken}}'
var options = new RestClientOptions("{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone")
{
MaxTimeout = -1,
};
var client = new RestClient(options);
var request = new RestRequest("", Method.Post);
request.AddHeader("Authorization", "Bearer {{accessToken}}");
RestResponse response = await client.ExecuteAsync(request);
Console.WriteLine(response.Content);
package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone"
method := "POST"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "Bearer {{accessToken}}")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := io.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}
POST /environments/{{envID}}/themes/{{themeID}}/clone HTTP/1.1
Host: {{apiPath}}
Authorization: Bearer {{accessToken}}
OkHttpClient client = new OkHttpClient().newBuilder()
.build();
MediaType mediaType = MediaType.parse("text/plain");
RequestBody body = RequestBody.create(mediaType, "");
Request request = new Request.Builder()
.url("{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone")
.method("POST", body)
.addHeader("Authorization", "Bearer {{accessToken}}")
.build();
Response response = client.newCall(request).execute();
var settings = {
"url": "{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone",
"method": "POST",
"timeout": 0,
"headers": {
"Authorization": "Bearer {{accessToken}}"
},
};
$.ajax(settings).done(function (response) {
console.log(response);
});
var request = require('request');
var options = {
'method': 'POST',
'url': '{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone',
'headers': {
'Authorization': 'Bearer {{accessToken}}'
}
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
import requests
url = "{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone"
payload = {}
headers = {
'Authorization': 'Bearer {{accessToken}}'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
<?php
require_once 'HTTP/Request2.php';
$request = new HTTP_Request2();
$request->setUrl('{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone');
$request->setMethod(HTTP_Request2::METHOD_POST);
$request->setConfig(array(
'follow_redirects' => TRUE
));
$request->setHeader(array(
'Authorization' => 'Bearer {{accessToken}}'
));
try {
$response = $request->send();
if ($response->getStatus() == 200) {
echo $response->getBody();
}
else {
echo 'Unexpected HTTP status: ' . $response->getStatus() . ' ' .
$response->getReasonPhrase();
}
}
catch(HTTP_Request2_Exception $e) {
echo 'Error: ' . $e->getMessage();
}
require "uri"
require "net/http"
url = URI("{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone")
http = Net::HTTP.new(url.host, url.port);
request = Net::HTTP::Post.new(url)
request["Authorization"] = "Bearer {{accessToken}}"
response = http.request(request)
puts response.read_body
var request = URLRequest(url: URL(string: "{{apiPath}}/environments/{{envID}}/themes/{{themeID}}/clone")!,timeoutInterval: Double.infinity)
request.addValue("Bearer {{accessToken}}", forHTTPHeaderField: "Authorization")
request.httpMethod = "POST"
let task = URLSession.shared.dataTask(with: request) { data, response, error in
guard let data = data else {
print(String(describing: error))
return
}
print(String(data: data, encoding: .utf8)!)
}
task.resume()
Example Response
200 OK
{
"_links": {
"self": {
"href": "https://api.pingone.com/v1/environments/abfba8f6-49eb-49f5-a5d9-80ad5c98f9f6/themes/9664b799-1bb6-457f-adc3-f47920d267c4"
},
"environment": {
"href": "https://api.pingone.com/v1/environments/abfba8f6-49eb-49f5-a5d9-80ad5c98f9f6"
}
},
"environment": {
"id": "abfba8f6-49eb-49f5-a5d9-80ad5c98f9f6"
},
"id": "9664b799-1bb6-457f-adc3-f47920d267c4",
"template": "slate",
"default": false,
"configuration": {
"logoType": "IMAGE",
"logo": {
"href": "https://d3uinntk0mqu3p.cloudfront.net/branding/market/a3d073bc-3108-49ad-b96c-404bea59a1d0.png",
"id": "00000000-0000-0000-0000-000000000000"
},
"applicationBackgroundColor": "#f8f8f8",
"backgroundType": "DEFAULT",
"bodyTextColor": "#4C4C4C",
"cardColor": "#FFFFFF",
"headingTextColor": "#4A4A4A",
"linkTextColor": "#5F5F5F",
"buttonColor": "#4A4A4A",
"buttonTextColor": "#FFFFFF",
"name": "Custom Slate-Clone",
"footer": "<p>Copyright © 2025 My Company</p>",
"backgroundOutlineColor": "#4A4A4A",
"foregroundMainColor": "#4A4A4A",
"foregroundHighlightColor": "#4A4A4A",
"schemaVersion": 2,
"buttonBorderColor": "#4A4A4A",
"focusRectangleColor": "#D033FF",
"buttonHoverStateFillColor": "#4A4A4A",
"buttonHoverStateBorderColor": "#4A4A4A",
"buttonHoverStateTextColor": "#FFFFFF",
"subTitleTextColor": "#4A4A4A",
"titleTextColor": "#4A4A4A",
"linkTextHoverColor": "#007CBA",
"inputLabelTextColor": "#798087",
"inputBoxBorderColor": "#4A4A4A",
"cardBorderColor": "#CACED3",
"globalFont": "\"Helvetica Neue\", Helvetica, sans-serif",
"logoHeight": "56px",
"buttonBorderWidth": "1px",
"buttonCornerRadius": "2px",
"buttonTextSize": "18px",
"buttonTextWeight": "400",
"titleTextSize": "20px",
"titleTextWeight": "600",
"subTitleTextSize": "15px",
"subTitleTextWeight": "400",
"bodyTextSize": "15px",
"bodyTextWeight": "400",
"linkTextSize": "15px",
"linkTextWeight": "400",
"inputLabelTextSize": "15px",
"inputLabelTextWeight": "600",
"inputValueTextSize": "15px",
"inputValueTextWeight": "600",
"inputValueTextColor": "#798087",
"inputBorderWidth": "1px",
"inputCornerRadius": "0px",
"inputLabelPosition": "float",
"cardBorderWidth": "0px",
"cardCornerRadius": "0px",
"cardShadow": "0px",
"cardHorizontalAlignment": "left",
"cardVerticalAlignment": "center",
"footerLocalized": {
"enabled": true,
"defaultLanguage": "en",
"contentType": "HTML",
"content": {
"en": {
"inputText": "<p>Copyright © 2025 My Company</p>"
}
}
},
"cardLogoAlignment": "left"
},
"modified": "2026-01-15T17:14:50.752Z"
}