Content (V1)
Endpoints for searching, reading, creating, updating, and deleting content items using the V1 field model (fields as typed array).
Base URL: https://api.contit.cloud
/contents/{contentTypeKey}
Search contents
Search and filter content items with pagination, ordering, localization, and nested filter groups.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key (e.g. 'Product', 'Article') |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
page |
integer | — | Page number (1-based) |
pageSize |
integer | — | Number of items per page (max 500) |
filter |
object | — | Filter tree with nested groups and rules to restrict results |
order |
object | — | Sorting configuration |
↳ fieldKey |
string | — | Field key to sort by |
↳ sortDir |
string | — | Sort direction: 'Asc' or 'Desc' |
locale |
string | — | Locale code for translated fields (e.g. 'en', 'it') |
includeRelations |
string[] | — | Array of relation field keys whose related content should be expanded inline |
Responses
items |
ContentModel[] | Array of content items with typed field arrays |
total |
integer | Total number of matching items |
page |
integer | Current page number |
pageSize |
integer | Items per page |
totalPages |
integer | Total number of pages |
hasMorePages |
boolean | Whether additional pages exist |
Code examples
curl -X POST "https://api.contit.cloud/contents/{contentTypeKey}" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"page": 1,
"pageSize": 1,
"filter": "filter_value",
"order": "order_value",
"locale": "locale_value",
"includeRelations": []
}'
var client = new ContitClient(
new ClientContitConfiguration(clientId, clientSecret));
var result = await client.Content.Get<MyModel>(contentType, new ContentsRequest
{
Page = 1, PageSize = 20
});
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}",
{
method: "POST",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"page": 1,
"pageSize": 1,
"filter": "filter_value",
"order": "order_value",
"locale": "locale_value",
"includeRelations": []
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"page": 1,
"pageSize": 1,
"filter": "filter_value",
"order": "order_value",
"locale": "locale_value",
"includeRelations": []
}
response = requests.post(
"https://api.contit.cloud/contents/{contentTypeKey}",
json=payload,
headers=headers
)
data = response.json()
{
"page": 1,
"pageSize": 20,
"filter": {
"type": "and",
"conditions": [
{
"type": "condition",
"fieldKey": "status",
"operator": "e",
"value": "published"
}
]
},
"order": {
"type": "condition",
"fieldKey": "title",
"sortDir": "Asc"
},
"locale": "en",
"includeRelations": ["category"]
}
{
"items": [
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"contentType": "Article",
"fields": [
{ "type": "Text", "key": "title", "value": "Hello World" },
{ "type": "Text", "key": "status", "value": "published" },
{ "type": "DateTime", "key": "publishDate", "value": "2026-03-15T10:30:00Z" }
],
"createdAt": "2026-03-10T08:00:00Z",
"updatedAt": "2026-03-15T10:30:00Z"
},
{
"id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
"contentType": "Article",
"fields": [
{ "type": "Text", "key": "title", "value": "Getting Started" },
{ "type": "Text", "key": "status", "value": "published" },
{ "type": "DateTime", "key": "publishDate", "value": "2026-03-12T14:00:00Z" }
],
"createdAt": "2026-03-11T09:00:00Z",
"updatedAt": "2026-03-12T14:00:00Z"
}
],
"total": 2,
"page": 1,
"pageSize": 20,
"totalPages": 1,
"hasMorePages": false
}
/contents/{contentTypeKey}/ids
Get content IDs only
Returns only the IDs of matching content items, useful for bulk operations or cross-referencing without loading full content.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key (e.g. 'Product', 'Article') |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
filter |
object | — | Filter tree to restrict results |
page |
integer | — | Page number (1-based) |
pageSize |
integer | — | Number of items per page |
Responses
ids |
string[] | Array of content item IDs |
total |
integer | Total number of matching items |
Code examples
curl -X POST "https://api.contit.cloud/contents/{contentTypeKey}/ids" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"filter": "filter_value",
"page": 1,
"pageSize": 1
}'
using var http = new HttpClient();
http.DefaultRequestHeaders.Add("X-Api-Key", "YOUR_API_KEY");
var content = new StringContent("{
\"filter\": \"filter_value\",
\"page\": 1,
\"pageSize\": 1
}",
Encoding.UTF8, "application/json");
var response = await http.PostAsync(
"https://api.contit.cloud/contents/{contentTypeKey}/ids", content);
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/ids",
{
method: "POST",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"filter": "filter_value",
"page": 1,
"pageSize": 1
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"filter": "filter_value",
"page": 1,
"pageSize": 1
}
response = requests.post(
"https://api.contit.cloud/contents/{contentTypeKey}/ids",
json=payload,
headers=headers
)
data = response.json()
{
"filter": {
"type": "and",
"conditions": [
{ "type": "condition", "fieldKey": "status", "operator": "e", "value": "published" }
]
},
"page": 1,
"pageSize": 100
}
{
"ids": [
"a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"b2c3d4e5-f6a7-8901-bcde-f12345678901",
"c3d4e5f6-a7b8-9012-cdef-123456789012"
],
"total": 3
}
/contents/{contentTypeKey}/{id}
Get single content
Retrieve a single content item by its ID.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
id |
string | ✓ | The content item ID (GUID) |
Responses
id |
string | Content item ID |
contentType |
string | Content type key |
fields |
ContentField[] | Array of typed fields |
createdAt |
datetime | Creation timestamp |
updatedAt |
datetime | Last update timestamp |
Code examples
curl -X GET "https://api.contit.cloud/contents/{contentTypeKey}/{id}" \
-H "X-Api-Key: YOUR_API_KEY"
using var http = new HttpClient();
http.DefaultRequestHeaders.Add("X-Api-Key", "YOUR_API_KEY");
var response = await http.GetAsync("https://api.contit.cloud/contents/{contentTypeKey}/{id}");
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/{id}",
{
method: "GET",
headers: {
"X-Api-Key": "YOUR_API_KEY",
}
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
response = requests.get(
"https://api.contit.cloud/contents/{contentTypeKey}/{id}",
headers=headers
)
data = response.json()
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"contentType": "Article",
"fields": [
{ "type": "Text", "key": "title", "value": "Hello World" },
{ "type": "RichText", "key": "body", "value": "<p>Welcome to Contit.</p>" },
{ "type": "DateTime", "key": "publishDate", "value": "2026-03-15T10:30:00Z" }
],
"createdAt": "2026-03-10T08:00:00Z",
"updatedAt": "2026-03-15T10:30:00Z"
}
/contents/{contentTypeKey}/{id}
Get content with relations
Retrieve a single content item by ID, optionally expanding related content and specifying a locale for translated fields.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
id |
string | ✓ | The content item ID (GUID) |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
locale |
string | — | Locale code for translated fields (e.g. 'en', 'it') |
includeRelations |
string[] | — | Relation field keys to expand inline |
Responses
id |
string | Content item ID |
contentType |
string | Content type key |
fields |
ContentField[] | Array of typed fields, with relations expanded |
Code examples
curl -X POST "https://api.contit.cloud/contents/{contentTypeKey}/{id}" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"locale": "locale_value",
"includeRelations": []
}'
var client = new ContitClient(
new ClientContitConfiguration(clientId, clientSecret));
var result = await client.Content.Get<MyModel>(contentType, new ContentsRequest
{
Page = 1, PageSize = 20
});
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/{id}",
{
method: "POST",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"locale": "locale_value",
"includeRelations": []
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"locale": "locale_value",
"includeRelations": []
}
response = requests.post(
"https://api.contit.cloud/contents/{contentTypeKey}/{id}",
json=payload,
headers=headers
)
data = response.json()
{
"locale": "it",
"includeRelations": ["category", "author"]
}
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"contentType": "Article",
"fields": [
{ "type": "Text", "key": "title", "value": "Ciao Mondo" },
{ "type": "Relation", "key": "category", "value": { "id": "d4e5f6a7-b8c9-0123-defg-456789012345", "contentType": "Category", "fields": [{ "type": "Text", "key": "name", "value": "Tecnologia" }] } },
{ "type": "Relation", "key": "author", "value": { "id": "e5f6a7b8-c9d0-1234-efgh-567890123456", "contentType": "Author", "fields": [{ "type": "Text", "key": "name", "value": "Marco Rossi" }] } }
],
"createdAt": "2026-03-10T08:00:00Z",
"updatedAt": "2026-03-15T10:30:00Z"
}
/contents/{contentTypeKey}/aggregate
Aggregate field values
Compute an aggregate (Sum, Avg, Min, Max, or Count) on a numeric field across matching content items.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
fieldKey |
string | ✓ | The field key to aggregate on |
aggregateType |
string | ✓ | Aggregation function: Sum, Avg, Min, Max, or Count |
filter |
object | — | Optional filter to restrict which items are aggregated |
Responses
value |
decimal | The computed aggregate value |
Code examples
curl -X POST "https://api.contit.cloud/contents/{contentTypeKey}/aggregate" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"fieldKey": "fieldKey_value",
"aggregateType": "aggregateType_value",
"filter": "filter_value"
}'
using var http = new HttpClient();
http.DefaultRequestHeaders.Add("X-Api-Key", "YOUR_API_KEY");
var content = new StringContent("{
\"fieldKey\": \"fieldKey_value\",
\"aggregateType\": \"aggregateType_value\",
\"filter\": \"filter_value\"
}",
Encoding.UTF8, "application/json");
var response = await http.PostAsync(
"https://api.contit.cloud/contents/{contentTypeKey}/aggregate", content);
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/aggregate",
{
method: "POST",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"fieldKey": "fieldKey_value",
"aggregateType": "aggregateType_value",
"filter": "filter_value"
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"fieldKey": "fieldKey_value",
"aggregateType": "aggregateType_value",
"filter": "filter_value"
}
response = requests.post(
"https://api.contit.cloud/contents/{contentTypeKey}/aggregate",
json=payload,
headers=headers
)
data = response.json()
{
"type": "condition",
"fieldKey": "price",
"aggregateType": "Avg",
"filter": {
"type": "and",
"conditions": [
{ "type": "condition", "fieldKey": "status", "operator": "e", "value": "published" }
]
}
}
{
"value": 49.95
}
/contents/{contentTypeKey}/aggregategroup
Grouped aggregation
Compute an aggregate grouped by a specific field, returning one result per distinct group value.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
fieldKey |
string | ✓ | The field key to aggregate on |
aggregateType |
string | ✓ | Aggregation function: Sum, Avg, Min, Max, or Count |
groupByFieldKey |
string | ✓ | The field key to group results by |
filter |
object | — | Optional filter to restrict which items are aggregated |
Responses
items |
AggregateGroupItem[] | Array of group-value / aggregate-value pairs |
Code examples
curl -X POST "https://api.contit.cloud/contents/{contentTypeKey}/aggregategroup" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"fieldKey": "fieldKey_value",
"aggregateType": "aggregateType_value",
"groupByFieldKey": "groupByFieldKey_value",
"filter": "filter_value"
}'
using var http = new HttpClient();
http.DefaultRequestHeaders.Add("X-Api-Key", "YOUR_API_KEY");
var content = new StringContent("{
\"fieldKey\": \"fieldKey_value\",
\"aggregateType\": \"aggregateType_value\",
\"groupByFieldKey\": \"groupByFieldKey_value\",
\"filter\": \"filter_value\"
}",
Encoding.UTF8, "application/json");
var response = await http.PostAsync(
"https://api.contit.cloud/contents/{contentTypeKey}/aggregategroup", content);
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/aggregategroup",
{
method: "POST",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"fieldKey": "fieldKey_value",
"aggregateType": "aggregateType_value",
"groupByFieldKey": "groupByFieldKey_value",
"filter": "filter_value"
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"fieldKey": "fieldKey_value",
"aggregateType": "aggregateType_value",
"groupByFieldKey": "groupByFieldKey_value",
"filter": "filter_value"
}
response = requests.post(
"https://api.contit.cloud/contents/{contentTypeKey}/aggregategroup",
json=payload,
headers=headers
)
data = response.json()
{
"type": "condition",
"fieldKey": "price",
"aggregateType": "Sum",
"groupByFieldKey": "category",
"filter": null
}
{
"items": [
{ "groupValue": "Electronics", "aggregateValue": 2499.90 },
{ "groupValue": "Books", "aggregateValue": 389.50 },
{ "groupValue": "Clothing", "aggregateValue": 1250.00 }
]
}
/contents/{contentTypeKey}/encrypt/check
Check encrypted field value
Verify that an encrypted field matches a given plaintext value without revealing the stored data.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
id |
string | ✓ | The content item ID |
encryptFields |
object | ✓ | Dictionary of field key to plaintext value to check against |
Responses
match |
boolean | Whether the provided value matches the stored encrypted value |
Code examples
curl -X POST "https://api.contit.cloud/contents/{contentTypeKey}/encrypt/check" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"id": "id_value",
"encryptFields": "encryptFields_value"
}'
using var http = new HttpClient();
http.DefaultRequestHeaders.Add("X-Api-Key", "YOUR_API_KEY");
var content = new StringContent("{
\"id\": \"id_value\",
\"encryptFields\": \"encryptFields_value\"
}",
Encoding.UTF8, "application/json");
var response = await http.PostAsync(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt/check", content);
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt/check",
{
method: "POST",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"id": "id_value",
"encryptFields": "encryptFields_value"
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"id": "id_value",
"encryptFields": "encryptFields_value"
}
response = requests.post(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt/check",
json=payload,
headers=headers
)
data = response.json()
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"encryptFields": {
"ssn": "123-45-6789"
}
}
{
"match": true
}
/contents/{contentTypeKey}/encrypt/decrypt
Decrypt encrypted fields
Decrypt one or more encrypted fields on a content item. Requires a valid TOTP code for additional security.
ReadAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
id |
string | ✓ | The content item ID |
encryptFieldKeys |
string[] | ✓ | Array of field keys to decrypt |
totpCode |
string | ✓ | Time-based one-time password for authorization |
Responses
fields |
object | Dictionary of field key to decrypted plaintext value |
Code examples
curl -X POST "https://api.contit.cloud/contents/{contentTypeKey}/encrypt/decrypt" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"id": "id_value",
"encryptFieldKeys": [],
"totpCode": "totpCode_value"
}'
using var http = new HttpClient();
http.DefaultRequestHeaders.Add("X-Api-Key", "YOUR_API_KEY");
var content = new StringContent("{
\"id\": \"id_value\",
\"encryptFieldKeys\": [],
\"totpCode\": \"totpCode_value\"
}",
Encoding.UTF8, "application/json");
var response = await http.PostAsync(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt/decrypt", content);
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt/decrypt",
{
method: "POST",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"id": "id_value",
"encryptFieldKeys": [],
"totpCode": "totpCode_value"
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"id": "id_value",
"encryptFieldKeys": [],
"totpCode": "totpCode_value"
}
response = requests.post(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt/decrypt",
json=payload,
headers=headers
)
data = response.json()
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"encryptFieldKeys": ["ssn", "taxId"],
"totpCode": "482916"
}
{
"fields": {
"ssn": "123-45-6789",
"taxId": "RSSMRC80A01H501Z"
}
}
/contents/{contentTypeKey}/encrypt
Set encrypted field values
Store one or more field values in encrypted form on a content item.
WriteAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
id |
string | ✓ | The content item ID |
encryptFields |
object | ✓ | Dictionary of field key to plaintext value to encrypt and store |
clientInfo |
string | — | Optional client identifier for audit logging |
Responses
Code examples
curl -X PUT "https://api.contit.cloud/contents/{contentTypeKey}/encrypt" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"id": "id_value",
"encryptFields": "encryptFields_value",
"clientInfo": "clientInfo_value"
}'
var client = new ContitClient(
new ClientContitConfiguration(clientId, clientSecret));
await client.Content.AddOrUpdate(contentType, contentModel);
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt",
{
method: "PUT",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"id": "id_value",
"encryptFields": "encryptFields_value",
"clientInfo": "clientInfo_value"
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"id": "id_value",
"encryptFields": "encryptFields_value",
"clientInfo": "clientInfo_value"
}
response = requests.put(
"https://api.contit.cloud/contents/{contentTypeKey}/encrypt",
json=payload,
headers=headers
)
data = response.json()
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"encryptFields": {
"ssn": "123-45-6789"
},
"clientInfo": "admin-panel-v3"
}
{
"success": true
}
/contents/{contentTypeKey}
Create or update content
Create a new content item (id = null) or update an existing one. Returns the full content model including system-generated fields.
WriteAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
id |
string | — | Content item ID. Pass null or omit to create a new item. |
contentType |
string | ✓ | The content type key (must match path parameter) |
fields |
ContentField[] | ✓ | Array of typed fields with type, key, and value |
clientInfo |
string | — | Optional client identifier for audit logging |
Responses
id |
string | Content item ID (generated if new) |
contentType |
string | Content type key |
fields |
ContentField[] | Array of typed fields |
createdAt |
datetime | Creation timestamp |
updatedAt |
datetime | Last update timestamp |
Code examples
curl -X PUT "https://api.contit.cloud/contents/{contentTypeKey}" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"id": "id_value",
"contentType": "contentType_value",
"fields": [],
"clientInfo": "clientInfo_value"
}'
var client = new ContitClient(
new ClientContitConfiguration(clientId, clientSecret));
await client.Content.AddOrUpdate(contentType, contentModel);
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}",
{
method: "PUT",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"id": "id_value",
"contentType": "contentType_value",
"fields": [],
"clientInfo": "clientInfo_value"
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"id": "id_value",
"contentType": "contentType_value",
"fields": [],
"clientInfo": "clientInfo_value"
}
response = requests.put(
"https://api.contit.cloud/contents/{contentTypeKey}",
json=payload,
headers=headers
)
data = response.json()
{
"id": null,
"contentType": "Article",
"fields": [
{ "type": "Text", "key": "title", "value": "New Article" },
{ "type": "RichText", "key": "body", "value": "<p>Article body here.</p>" },
{ "type": "DateTime", "key": "publishDate", "value": "2026-03-20T09:00:00Z" }
],
"clientInfo": "cms-editor"
}
{
"id": "f6a7b8c9-d0e1-2345-fghi-678901234567",
"contentType": "Article",
"fields": [
{ "type": "Text", "key": "title", "value": "New Article" },
{ "type": "RichText", "key": "body", "value": "<p>Article body here.</p>" },
{ "type": "DateTime", "key": "publishDate", "value": "2026-03-20T09:00:00Z" },
{ "type": "Text", "key": "_createdBy", "value": "api-client" }
],
"createdAt": "2026-03-20T09:00:00Z",
"updatedAt": "2026-03-20T09:00:00Z"
}
/contents/{contentTypeKey}/{id}
Delete content
Permanently delete a content item by its ID.
WriteAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
id |
string | ✓ | The content item ID (GUID) |
Responses
Code examples
curl -X DELETE "https://api.contit.cloud/contents/{contentTypeKey}/{id}" \
-H "X-Api-Key: YOUR_API_KEY"
var client = new ContitClient(
new ClientContitConfiguration(clientId, clientSecret));
await client.Content.Delete(contentType, id);
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/{id}",
{
method: "DELETE",
headers: {
"X-Api-Key": "YOUR_API_KEY",
}
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
response = requests.delete(
"https://api.contit.cloud/contents/{contentTypeKey}/{id}",
headers=headers
)
data = response.json()
{
"success": true
}
/contents/{contentTypeKey}/publish
Deprecated
Publish content (deprecated)
Deprecated. Use PUT /contents/{contentTypeKey} with the appropriate status field instead.
WriteAccess policy
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
contentTypeKey |
string | ✓ | The content type key |
Request Body application/json
| Property | Type | Required | Description |
|---|---|---|---|
id |
string | ✓ | The content item ID to publish |
clientInfo |
string | — | Optional client identifier |
Responses
Code examples
curl -X PUT "https://api.contit.cloud/contents/{contentTypeKey}/publish" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"id": "id_value",
"clientInfo": "clientInfo_value"
}'
var client = new ContitClient(
new ClientContitConfiguration(clientId, clientSecret));
await client.Content.AddOrUpdate(contentType, contentModel);
const response = await fetch(
"https://api.contit.cloud/contents/{contentTypeKey}/publish",
{
method: "PUT",
headers: {
"X-Api-Key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"id": "id_value",
"clientInfo": "clientInfo_value"
})
}
);
const data = await response.json();
import requests
headers = {"X-Api-Key": "YOUR_API_KEY"}
payload = {
"id": "id_value",
"clientInfo": "clientInfo_value"
}
response = requests.put(
"https://api.contit.cloud/contents/{contentTypeKey}/publish",
json=payload,
headers=headers
)
data = response.json()
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"clientInfo": "cms-editor"
}
{
"success": true
}