curl --request POST \
--url https://api.octaviatech.app/cms/forms/create \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"title": {
"en": "Contact Us",
"fa": "Contact Us"
},
"slug": "contact-us",
"description": {
"en": "Public contact form"
},
"submitButtonText": {
"en": "Send"
},
"sections": [
{
"title": {
"en": "Basic Info"
},
"fields": [
{
"name": "fullName",
"type": "text",
"label": {
"en": "Full Name"
},
"required": true
},
{
"name": "email",
"type": "email",
"label": {
"en": "Email"
},
"required": true
},
{
"name": "message",
"type": "textarea",
"label": {
"en": "Message"
},
"required": true
}
]
}
],
"isActive": true
}
'import requests
url = "https://api.octaviatech.app/cms/forms/create"
payload = {
"title": {
"en": "Contact Us",
"fa": "Contact Us"
},
"slug": "contact-us",
"description": { "en": "Public contact form" },
"submitButtonText": { "en": "Send" },
"sections": [
{
"title": { "en": "Basic Info" },
"fields": [
{
"name": "fullName",
"type": "text",
"label": { "en": "Full Name" },
"required": True
},
{
"name": "email",
"type": "email",
"label": { "en": "Email" },
"required": True
},
{
"name": "message",
"type": "textarea",
"label": { "en": "Message" },
"required": True
}
]
}
],
"isActive": True
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
title: {en: 'Contact Us', fa: 'Contact Us'},
slug: 'contact-us',
description: {en: 'Public contact form'},
submitButtonText: {en: 'Send'},
sections: [
{
title: {en: 'Basic Info'},
fields: [
{name: 'fullName', type: 'text', label: {en: 'Full Name'}, required: true},
{name: 'email', type: 'email', label: {en: 'Email'}, required: true},
{name: 'message', type: 'textarea', label: {en: 'Message'}, required: true}
]
}
],
isActive: true
})
};
fetch('https://api.octaviatech.app/cms/forms/create', 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.octaviatech.app/cms/forms/create",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'title' => [
'en' => 'Contact Us',
'fa' => 'Contact Us'
],
'slug' => 'contact-us',
'description' => [
'en' => 'Public contact form'
],
'submitButtonText' => [
'en' => 'Send'
],
'sections' => [
[
'title' => [
'en' => 'Basic Info'
],
'fields' => [
[
'name' => 'fullName',
'type' => 'text',
'label' => [
'en' => 'Full Name'
],
'required' => true
],
[
'name' => 'email',
'type' => 'email',
'label' => [
'en' => 'Email'
],
'required' => true
],
[
'name' => 'message',
'type' => 'textarea',
'label' => [
'en' => 'Message'
],
'required' => true
]
]
]
],
'isActive' => 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.octaviatech.app/cms/forms/create"
payload := strings.NewReader("{\n \"title\": {\n \"en\": \"Contact Us\",\n \"fa\": \"Contact Us\"\n },\n \"slug\": \"contact-us\",\n \"description\": {\n \"en\": \"Public contact form\"\n },\n \"submitButtonText\": {\n \"en\": \"Send\"\n },\n \"sections\": [\n {\n \"title\": {\n \"en\": \"Basic Info\"\n },\n \"fields\": [\n {\n \"name\": \"fullName\",\n \"type\": \"text\",\n \"label\": {\n \"en\": \"Full Name\"\n },\n \"required\": true\n },\n {\n \"name\": \"email\",\n \"type\": \"email\",\n \"label\": {\n \"en\": \"Email\"\n },\n \"required\": true\n },\n {\n \"name\": \"message\",\n \"type\": \"textarea\",\n \"label\": {\n \"en\": \"Message\"\n },\n \"required\": true\n }\n ]\n }\n ],\n \"isActive\": true\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.octaviatech.app/cms/forms/create")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"title\": {\n \"en\": \"Contact Us\",\n \"fa\": \"Contact Us\"\n },\n \"slug\": \"contact-us\",\n \"description\": {\n \"en\": \"Public contact form\"\n },\n \"submitButtonText\": {\n \"en\": \"Send\"\n },\n \"sections\": [\n {\n \"title\": {\n \"en\": \"Basic Info\"\n },\n \"fields\": [\n {\n \"name\": \"fullName\",\n \"type\": \"text\",\n \"label\": {\n \"en\": \"Full Name\"\n },\n \"required\": true\n },\n {\n \"name\": \"email\",\n \"type\": \"email\",\n \"label\": {\n \"en\": \"Email\"\n },\n \"required\": true\n },\n {\n \"name\": \"message\",\n \"type\": \"textarea\",\n \"label\": {\n \"en\": \"Message\"\n },\n \"required\": true\n }\n ]\n }\n ],\n \"isActive\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.octaviatech.app/cms/forms/create")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"title\": {\n \"en\": \"Contact Us\",\n \"fa\": \"Contact Us\"\n },\n \"slug\": \"contact-us\",\n \"description\": {\n \"en\": \"Public contact form\"\n },\n \"submitButtonText\": {\n \"en\": \"Send\"\n },\n \"sections\": [\n {\n \"title\": {\n \"en\": \"Basic Info\"\n },\n \"fields\": [\n {\n \"name\": \"fullName\",\n \"type\": \"text\",\n \"label\": {\n \"en\": \"Full Name\"\n },\n \"required\": true\n },\n {\n \"name\": \"email\",\n \"type\": \"email\",\n \"label\": {\n \"en\": \"Email\"\n },\n \"required\": true\n },\n {\n \"name\": \"message\",\n \"type\": \"textarea\",\n \"label\": {\n \"en\": \"Message\"\n },\n \"required\": true\n }\n ]\n }\n ],\n \"isActive\": true\n}"
response = http.request(request)
puts response.read_bodyCreate form
Creates a new form with multilingual text fields, sections, and fields. Keys inside multilingual objects must be valid language codes configured in your system (e.g., “en”, “fa”, …).
curl --request POST \
--url https://api.octaviatech.app/cms/forms/create \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"title": {
"en": "Contact Us",
"fa": "Contact Us"
},
"slug": "contact-us",
"description": {
"en": "Public contact form"
},
"submitButtonText": {
"en": "Send"
},
"sections": [
{
"title": {
"en": "Basic Info"
},
"fields": [
{
"name": "fullName",
"type": "text",
"label": {
"en": "Full Name"
},
"required": true
},
{
"name": "email",
"type": "email",
"label": {
"en": "Email"
},
"required": true
},
{
"name": "message",
"type": "textarea",
"label": {
"en": "Message"
},
"required": true
}
]
}
],
"isActive": true
}
'import requests
url = "https://api.octaviatech.app/cms/forms/create"
payload = {
"title": {
"en": "Contact Us",
"fa": "Contact Us"
},
"slug": "contact-us",
"description": { "en": "Public contact form" },
"submitButtonText": { "en": "Send" },
"sections": [
{
"title": { "en": "Basic Info" },
"fields": [
{
"name": "fullName",
"type": "text",
"label": { "en": "Full Name" },
"required": True
},
{
"name": "email",
"type": "email",
"label": { "en": "Email" },
"required": True
},
{
"name": "message",
"type": "textarea",
"label": { "en": "Message" },
"required": True
}
]
}
],
"isActive": True
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
title: {en: 'Contact Us', fa: 'Contact Us'},
slug: 'contact-us',
description: {en: 'Public contact form'},
submitButtonText: {en: 'Send'},
sections: [
{
title: {en: 'Basic Info'},
fields: [
{name: 'fullName', type: 'text', label: {en: 'Full Name'}, required: true},
{name: 'email', type: 'email', label: {en: 'Email'}, required: true},
{name: 'message', type: 'textarea', label: {en: 'Message'}, required: true}
]
}
],
isActive: true
})
};
fetch('https://api.octaviatech.app/cms/forms/create', 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.octaviatech.app/cms/forms/create",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'title' => [
'en' => 'Contact Us',
'fa' => 'Contact Us'
],
'slug' => 'contact-us',
'description' => [
'en' => 'Public contact form'
],
'submitButtonText' => [
'en' => 'Send'
],
'sections' => [
[
'title' => [
'en' => 'Basic Info'
],
'fields' => [
[
'name' => 'fullName',
'type' => 'text',
'label' => [
'en' => 'Full Name'
],
'required' => true
],
[
'name' => 'email',
'type' => 'email',
'label' => [
'en' => 'Email'
],
'required' => true
],
[
'name' => 'message',
'type' => 'textarea',
'label' => [
'en' => 'Message'
],
'required' => true
]
]
]
],
'isActive' => 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.octaviatech.app/cms/forms/create"
payload := strings.NewReader("{\n \"title\": {\n \"en\": \"Contact Us\",\n \"fa\": \"Contact Us\"\n },\n \"slug\": \"contact-us\",\n \"description\": {\n \"en\": \"Public contact form\"\n },\n \"submitButtonText\": {\n \"en\": \"Send\"\n },\n \"sections\": [\n {\n \"title\": {\n \"en\": \"Basic Info\"\n },\n \"fields\": [\n {\n \"name\": \"fullName\",\n \"type\": \"text\",\n \"label\": {\n \"en\": \"Full Name\"\n },\n \"required\": true\n },\n {\n \"name\": \"email\",\n \"type\": \"email\",\n \"label\": {\n \"en\": \"Email\"\n },\n \"required\": true\n },\n {\n \"name\": \"message\",\n \"type\": \"textarea\",\n \"label\": {\n \"en\": \"Message\"\n },\n \"required\": true\n }\n ]\n }\n ],\n \"isActive\": true\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.octaviatech.app/cms/forms/create")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"title\": {\n \"en\": \"Contact Us\",\n \"fa\": \"Contact Us\"\n },\n \"slug\": \"contact-us\",\n \"description\": {\n \"en\": \"Public contact form\"\n },\n \"submitButtonText\": {\n \"en\": \"Send\"\n },\n \"sections\": [\n {\n \"title\": {\n \"en\": \"Basic Info\"\n },\n \"fields\": [\n {\n \"name\": \"fullName\",\n \"type\": \"text\",\n \"label\": {\n \"en\": \"Full Name\"\n },\n \"required\": true\n },\n {\n \"name\": \"email\",\n \"type\": \"email\",\n \"label\": {\n \"en\": \"Email\"\n },\n \"required\": true\n },\n {\n \"name\": \"message\",\n \"type\": \"textarea\",\n \"label\": {\n \"en\": \"Message\"\n },\n \"required\": true\n }\n ]\n }\n ],\n \"isActive\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.octaviatech.app/cms/forms/create")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"title\": {\n \"en\": \"Contact Us\",\n \"fa\": \"Contact Us\"\n },\n \"slug\": \"contact-us\",\n \"description\": {\n \"en\": \"Public contact form\"\n },\n \"submitButtonText\": {\n \"en\": \"Send\"\n },\n \"sections\": [\n {\n \"title\": {\n \"en\": \"Basic Info\"\n },\n \"fields\": [\n {\n \"name\": \"fullName\",\n \"type\": \"text\",\n \"label\": {\n \"en\": \"Full Name\"\n },\n \"required\": true\n },\n {\n \"name\": \"email\",\n \"type\": \"email\",\n \"label\": {\n \"en\": \"Email\"\n },\n \"required\": true\n },\n {\n \"name\": \"message\",\n \"type\": \"textarea\",\n \"label\": {\n \"en\": \"Message\"\n },\n \"required\": true\n }\n ]\n }\n ],\n \"isActive\": true\n}"
response = http.request(request)
puts response.read_bodyAuthorizations
Body
Map of language code → string (at least one entry required).
Show child attributes
Show child attributes
URL-friendly, unique per tenant. Must satisfy the service’s slug rules (lowercase, digits, hyphens; no spaces).
Ordered list of sections; each section contains fields.
1Show child attributes
Show child attributes
Multilingual description (language code → string).
Show child attributes
Show child attributes
Multilingual submit button label (language code → string).
Show child attributes
Show child attributes
Whether the form is enabled (default true).
Whether the form is reachable on the public submit route. Defaults to "public"; "internal" forms are only submittable through /forms/{id}/internal-submit.
public, internal Per-form CAPTCHA gate. enabled defaults to false.
provider defaults to the service-wide CAPTCHA_PROVIDER_DEFAULT (falling back to "recaptcha").
minScore (0–1) applies to providers that return a score.
Show child attributes
Show child attributes
Optional submission notifications. enabled defaults to false.
email and push each take admin and submitter sub-objects whose
enabled flags default to false. Notifications are fire-and-forget and never
block or fail the HTTP response.
Show child attributes
Show child attributes
Optional relation to other forms for multi-step flows.
Show child attributes
Show child attributes
Response
Created
Was this page helpful?

