> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://contentful.com/developers/docs/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://contentful.com/_mcp/server. # Get a content type GET https://cdn.contentful.com/spaces/{space_id}/environments/{environment_id}/content_types/{content_type_id} Reference: https://contentful.com/developers/docs/references/content-delivery-api/content-types/get-a-content-type ## Request ### Path parameters - `space_id` (string, required) — ID of the space in form of a string - `environment_id` (string, required) — ID of the environment in form of a string - `content_type_id` (string, required) — ID of the content type in form of a string ### Query parameters - `access_token` (string, required) — A *production* Content Delivery API key. ## Response ### 200 OK - Request successful - `map from string to any` ## Examples **Response** ```json { "displayField": "productName", "fields": [ { "id": "productName", "localized": false, "name": "Product name", "required": true, "type": "Text" }, { "id": "slug", "localized": false, "name": "Slug", "required": false, "type": "Symbol" }, { "id": "productDescription", "localized": false, "name": "Description", "required": false, "type": "Text" }, { "id": "sizetypecolor", "localized": false, "name": "Size/Type/Color", "required": false, "type": "Symbol" }, { "id": "image", "items": { "linkType": "Asset", "type": "Link" }, "localized": false, "name": "Image", "required": false, "type": "Array" }, { "id": "tags", "items": { "type": "Symbol" }, "localized": false, "name": "Tags", "required": false, "type": "Array" }, { "id": "categories", "items": { "linkContentType": "6XwpTaSiiI2Ak2Ww0oi6qa", "linkType": "Entry", "type": "Link", "validations": "" }, "localized": false, "name": "Categories", "required": false, "type": "Array" }, { "disabled": true, "id": "price", "localized": false, "name": "Price", "required": false, "type": "Number" }, { "id": "brand", "linkType": "Entry", "localized": false, "name": "Brand", "required": false, "type": "Link" }, { "id": "quantity", "localized": false, "name": "Quantity", "required": false, "type": "Integer" }, { "id": "sku", "localized": false, "name": "SKU", "required": false, "type": "Symbol" }, { "id": "website", "localized": false, "name": "Available at", "required": false, "type": "Symbol" } ], "name": "Product", "sys": { "createdAt": "2025-06-21T05:18:39.000Z", "id": "2PqfXUJwE8qSYKuM0U6w8M", "revision": 1, "space": { "sys": { "id": "yadj1kx9rmg0", "linkType": "Space", "type": "Link" } }, "type": "ContentType", "updatedAt": "2025-06-21T05:18:39.000Z" } } ``` **SDK Code** ```android Android // Create the Contentful client. final CDAClient client = CDAClient .builder() .setToken("") .setSpace("") .setEnvironment("") .build(); client .observe(CDAContentType.class) .one("") // Execute result handling on the `main thread`. .observeOn(AndroidSchedulers.mainThread()) // Networking should happen on io thread. .subscribeOn(io.reactivex.schedulers.Schedulers.io()) .subscribe( new DisposableSubscriber() { CDAContentType result; @Override public void onComplete() { // Do something with the result. new AlertDialog.Builder(context) .setTitle("Contentful") .setMessage("Content type: " + (result == null ? "" : result.toString())) .show(); } @Override public void onError(Throwable e) { // Handle error case. new AlertDialog.Builder(context) .setTitle("Contentful") .setMessage("An error occurred: " + e.toString()) .show(); } @Override public void onNext(CDAContentType type) { // Array received, maybe more to come. result = type; } } ); ``` ```java Java // Create the Contentful client. final CDAClient client = CDAClient .builder() .setToken("") // required .setSpace("") // required .setEnvironment("") // optional, defaults to `master` .build(); final CDAArray all = client .fetch(CDAContentType.class) .all(); ``` ```kotlin Kotlin // Create the Contentful client. val client = CDAClient .builder() .setToken("") // required .setSpace("") // required .setEnvironment("") // optional, defaults to `master` .build() val all = client .fetch(CDAContentType::class.java) .all() ``` ```swift Swift import Contentful // Retain the client as a property on a type you define so that // the client's asynchronous network callbacks are executed. let client = Client(spaceId: "", environmentId: "", // Defaults to "master" if omitted accessToken: "") client.fetch(ContentType.self, id: "") { (result: Result) in switch result { case .success(let contentType): print(contentType) case .error(let error): print(error) } } ``` ```javascript JavaScript import { createClient } from 'contentful-management' const client = createClient({ space: '', environment: '', // defaults to 'master' if not set accessToken: '' }) client.getContentType('') .then((contentType) => console.log(contentType)) .catch(console.error) ``` ```php PHP // contentful.php 3.0 $client = new Contentful\Delivery\Client( '', '', '' // Defaults to "master" if ommitted ); $contentType = $client->getContentType(''); ``` ```ruby Ruby require 'contentful' client = Contentful::Client.new( space: '', access_token: '', environment: 'master', # Optional - defaults to 'master'. dynamic_entries: :auto # Enables Content Type caching. ) content_type = client.content_type('') ``` ```python Python from contentful import Client client = Client( '', '', environment='master' # Optional - it defaults to 'master'. ) content_type = client.content_type('') ``` ```.net .NET // This client should only be created once per application. var httpClient = new HttpClient(); var client = new ContentfulClient(httpClient, "", "", ""); var contentType = await client.GetContentType(""); ```