ContentType

View as Markdown

ContentType

ContentType provides Entry and Query instance.

fetch

Fetch the specific content type

NameTypeDescription
paramsobject

Parameters to fetch content

use Contentstack\Contentstack;


$stack = Contentstack::Stack('api_key', 'delivery_token', 'environment');

$result = $stack-ContentType('content_type_uid')->fetch();

Entry

Entry object to create the "Query" on the specified ContentType

NameTypeDescription
uid (required)string

Entry uid to get details

use Contentstack\Contentstack;


$stack = Contentstack::Stack('api_key', 'delivery_token', 'environment');

$entry = $stack-ContentType('content_type_uid')->Entry('entry_uid');

Query

A query that is used to query for Entry instance.

use Contentstack\Contentstack;


$stack = Contentstack::Stack('api_key', 'delivery_token', 'environment');

$query = $stack-ContentType('content_type_uid')->Query();