GET /structured-content/content-types/{content_type_id}
1 min
GET
https://api.cmp.optimizely.com/v3/structured-content/content-types/{content_type_id}
Path Parameters
- content_type_idstringrequiredDescription
Responses
200
- SCContentType
- objectBaseContentTypeModel
- namestringrequiredDescription
- descriptionstringDescription
- componentbooleanrequiredDescription
- disabledbooleanDescription
- sourcestringDescription
- thumbnail_guidstringDescription
- content_type_guidstringrequiredDescription
- created_bystringrequiredDescription
- updated_bystringrequiredDescription
- created_atstring<date-time>requiredDescriptionFormatdate-time
- updated_atstring<date-time>requiredDescriptionFormatdate-time
- source_idstringDescription
- source_metadatastringDescription
- linksobjectrequiredDescription
- selfstringExampleDescription
- versionsstringExampleDescription
- object
- latest_versionSCContentTypeVersionrequired
- BaseContentTypeVersionModel
- latestbooleanrequiredDescription
- version_guidstringrequiredDescription
- created_bystringrequiredDescription
- created_atstring<date-time>requiredDescriptionFormatdate-time
- expected_localesstring[]requiredDescription
- linksobjectrequiredDescription
- selfstringExampleDescription
- content_typestringExampleDescription
- object
- field_definitionsNumberFieldDefinition[]required
- coreCoreFieldDefrequired
- keystringrequiredDescription
- namestringrequiredDescription
- is_listbooleanrequiredDescription
- is_requiredbooleanrequiredDescription
- need_internationalizationbooleanrequiredDescription
- min_list_lengthintegerDescription
- max_list_lengthintegerDescription
- field_typeFieldTypeDescription
- source_idstringDescription
- source_metadatastringDescription
- order_indexintegerDescription
- help_textstringDescription
- editor_metadataobjectDescription
- min_valuenumberDescription
- max_valuenumberDescription
- default_valuesnumber[]Description
422
- HTTPValidationError
- detailValidationError[]Description
- locstring[]requiredDescription
- msgstringrequiredDescription
- typestringrequiredDescription
curl
curl --request GET \
--url https://api.cmp.optimizely.com/v3/structured-content/content-types/{content_type_id} \
--header 'accept: application/json'javascript
var myHeaders = new Headers();
myHeaders.append("accept", "application/json");
myHeaders.append("content-type", "application/json");
var requestOptions = {
method: 'GET',
headers: myHeaders,
redirect: 'follow'
};
fetch("https://api.cmp.optimizely.com/v3/structured-content/content-types/{content_type_id}", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));ruby
require "uri"
require "json"
require "net/http"
url = URI("https://api.cmp.optimizely.com/v3/structured-content/content-types/{content_type_id}")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Get.new(url)
request["accept"] = "application/json"
request["content-type"] = "application/json"
response = https.request(request)
puts response.read_body
python
import requests
import json
url = "https://api.cmp.optimizely.com/v3/structured-content/content-types/{content_type_id}"
payload = {}
headers = {
'accept': 'application/json',
'content-type': 'application/json'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
200
// Successful response
{
"name": "",
"description": "",
"component": false,
"disabled": false,
"source": "",
"thumbnail_guid": "",
"content_type_guid": "",
"created_by": "",
"updated_by": "",
"created_at": "",
"updated_at": "",
"source_id": "",
"source_metadata": "",
"links": {
"self": "https://api.cmp.optimizely.com/v3/structured-content/content-types/9fda53cf66a14fd487251480ca695c7b",
"versions": "https://api.cmp.optimizely.com/v3/structured-content/content-types/9fda53cf66a14fd487251480ca695c7b/versions"
},
"latest_version": {}
}422
// Validation error
{
"detail": [
{
"loc": [
""
],
"msg": "",
"type": ""
}
]
}