Put v1transactional email template - Terminal 3 Documentation

Documentation Index

Fetch the complete documentation index at: /llms.txt

Use this file to discover all available pages before exploring further.

cURL

curl --request PUT \
  --url https://staging.terminal3.io/v1/transactional_email_template/{transactional_email_template_id} \
  --header 'Content-Type: application/json' \
  --header 'x-api-token: <x-api-token>' \
  --data '\n{\n  "name": "<string>",\n  "subject": "<string>",\n  "body": "<string>",\n  "transactional_email_template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"\n}'\n```

### Python

import requests

url = "https://staging.terminal3.io/v1/transactional_email_template/{transactional_email_template_id}"

payload = { "name": "", "subject": "", "body": "", "transactional_email_template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a" } headers = { "x-api-token": "", "Content-Type": "application/json" }

response = requests.put(url, json=payload, headers=headers)

print(response.text)


### JavaScript

const options = { method: 'PUT', headers: {'x-api-token': '', 'Content-Type': 'application/json'}, body: JSON.stringify({ name: '', subject: '', body: JSON.stringify(''), transactional_email_template_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a' }) };

fetch('https://staging.terminal3.io/v1/transactional_email_template/{transactional_email_template_id}', options) .then(res => res.json()) .then(res => console.log(res)) .catch(err => console.error(err));


### PHP
"https://staging.terminal3.io/v1/transactional_email_template/{transactional_email_template_id}",\ 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([\ 'name' => '',\ 'subject' => '',\ 'body' => '',\ 'transactional_email_template_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'\ ]),\ CURLOPT_HTTPHEADER => [\ "Content-Type: application/json",\ "x-api-token: "\ ],\ ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } ?>

### Go

package main

import ( "fmt" "strings" "net/http" "io" )

func main() {

url := "https://staging.terminal3.io/v1/transactional_email_template/{transactional_email_template_id}"

payload := strings.NewReader("{\n "name": "",\n "subject": "",\n "body": "",\n "transactional_email_template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"}\n")

req, _ := http.NewRequest("PUT", url, payload)

req.Header.Add("x-api-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)) }


### cURL Response Codes

- 204
- 400
- 401
- 403
- 422

### Response Example

{ "errors": [
{
"code": "",
"message": ""
}
] }


### Headers

- **x-api-token**: string (required)
- **x-api-subclient-id**: string

### Path Parameters

- **transactional_email_template_id**: string<uuid> (required)

### Body

- **name**: string (required, Minimum string length: `1`)
- **subject**: string (required, Minimum string length: `1`)
- **body**: string (required, Minimum string length: `1`)
- **transactional_email_template_id**: string<uuid> (required)

### Response

- 204