Update the template of a user
curl --request PUT \
--url https://api.partoo.co/v2/review_booster/template \
--header 'Content-Type: application/json' \
--header 'x-APIKey: <api-key>' \
--data '
{
"template": "Hello ${client_name}, please leave a review ${url}"
}
'import requests
url = "https://api.partoo.co/v2/review_booster/template"
payload = { "template": "Hello ${client_name}, please leave a review ${url}" }
headers = {
"x-APIKey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'x-APIKey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({template: 'Hello ${client_name}, please leave a review ${url}'})
};
fetch('https://api.partoo.co/v2/review_booster/template', 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.partoo.co/v2/review_booster/template",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'template' => 'Hello ${client_name}, please leave a review ${url}'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-APIKey: <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.partoo.co/v2/review_booster/template"
payload := strings.NewReader("{\n \"template\": \"Hello ${client_name}, please leave a review ${url}\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-APIKey", "<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.put("https://api.partoo.co/v2/review_booster/template")
.header("x-APIKey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"template\": \"Hello ${client_name}, please leave a review ${url}\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.partoo.co/v2/review_booster/template")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-APIKey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"template\": \"Hello ${client_name}, please leave a review ${url}\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success"
}{
"errors": {
"json": {}
}
}{
"errors": {
"authentication": "User not authenticated"
}
}{
"errors": {
"authorization": "Operation not allowed"
}
}{
"errors": {
"json": "Resource not found"
}
}Review Booster
Update the template of a user
This endpoint lets you update the template associated with the user.
3 placeholders are available for the template: ${client_name}, ${business_name}, and ${url}.
There are 2 main constraints: - ${url} must be present in the template sent. - The text should not contain more than 250 characters (excluding placeholders).
The template must exist before the request is sent.
You need to be subscribed to the Review Booster product.
PUT
/
review_booster
/
template
Update the template of a user
curl --request PUT \
--url https://api.partoo.co/v2/review_booster/template \
--header 'Content-Type: application/json' \
--header 'x-APIKey: <api-key>' \
--data '
{
"template": "Hello ${client_name}, please leave a review ${url}"
}
'import requests
url = "https://api.partoo.co/v2/review_booster/template"
payload = { "template": "Hello ${client_name}, please leave a review ${url}" }
headers = {
"x-APIKey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'x-APIKey': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({template: 'Hello ${client_name}, please leave a review ${url}'})
};
fetch('https://api.partoo.co/v2/review_booster/template', 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.partoo.co/v2/review_booster/template",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'template' => 'Hello ${client_name}, please leave a review ${url}'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-APIKey: <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.partoo.co/v2/review_booster/template"
payload := strings.NewReader("{\n \"template\": \"Hello ${client_name}, please leave a review ${url}\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("x-APIKey", "<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.put("https://api.partoo.co/v2/review_booster/template")
.header("x-APIKey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"template\": \"Hello ${client_name}, please leave a review ${url}\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.partoo.co/v2/review_booster/template")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["x-APIKey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"template\": \"Hello ${client_name}, please leave a review ${url}\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success"
}{
"errors": {
"json": {}
}
}{
"errors": {
"authentication": "User not authenticated"
}
}{
"errors": {
"authorization": "Operation not allowed"
}
}{
"errors": {
"json": "Resource not found"
}
}Authorizations
Body
application/json
Was this page helpful?