---
title: "Entry"
description: "Entry"
url: "https://www.contentstack.com/docs/developers/sdks/content-delivery-sdk/dot-net/reference/entry"
product: "Contentstack"
doc_type: "guide"
audience:
  - developers
  - admins
version: "current"
last_updated: "2026-09-06"
---

# Entry

## Entry

An initializer is responsible for creating Entry object.

## GetContentType

Get contentType name.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
string contentType = stack.ContentType("content_Type_uid").Entry("entry_uid").GetContentType();
```

## GetUid

Get entry uid

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
var uid = entry.GetUid();
```

## GetTitle

Get entry title

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
var title = entry.GetTitle();
```

## GetTags

Returns tags of this entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
var tags = entry.GetTags();
```

## GetMetadata

Get metadata of entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
var metadata = entry.GetMetadata();
```

## GetHTMLText

Get html text for markdown data type

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
var result = entry.GetHTMLText("markdownKey");
```

field\_uid as key.

## GetMultipleHTMLText

Get html text for markdown data type which is multiple true

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
List<string> metadata = entry.GetMultipleHTMLText("markdown_field_uid");
```

Field\_uid as key.

## GetCreateAt

Get value of creation time of entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
DateTime datetime = entry.GetCreateAt();
```

## GetCreatedBy

Get uid who created this entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
string createdBy = entry.GetCreatedBy();
```

## GetUpdateAt

Get value of updating time of entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
DateTime datetime = entry.GetUpdateAt();
```

## GetUpdatedBy

Get uid who updated this entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
string updatedBy = entry.GetUpdatedBy();
```

## GetDeletedAt

Get value of deleting time of entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
DateTime datetime = entry.GetDeletedAt();
```

## GetDeletedBy

Get uid who created this entry.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
string deletedBy = entry.GetDeletedBy();
```

## Get

Get object value for key.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Entry>();
Object value = entry.Get("key");
```

Key to get value

## SetCachePolicy

To set cache policy using Entry instance.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_type_uid").Entry("entry_uid").SetCachePolicy(CachePolicy.NetworkElseCache).Fetch<Entry>();
```

CachePolicy instance

## SetHeader

To set headers for Contentstack rest calls.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_type_uid").Entry("entry_uid").SetHeader("custom_key", "custom_value").Fetch();
```

header name.

header value against given header name.

## RemoveHeader

Remove header key.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_type_uid").Entry("entry_uid").RemoveHeader("header_to_remove").Fetch();
```

key to be remove from header

## SetLocale

Sets the locale.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_type_uid").Entry("entry_uid").SetLocale("en-us").Fetch<Entry>();
```

Locale to fetch entry

## SetUid

Assigns a uid to current instance of an entry.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.Entry().SetUid("entry_uid").SetLocale("en-us").Fetch<Entry>();
```

Uid for entry to fetch

## SetTags

Assign a tag(s) for this Entry.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.Entry("entry_uid").SetTags(new List<string>() {
	"tag_1"
}).Fetch<Entry>();
```

Collection of tags.

## IncludeReferenceContentTypeUID

This method also includes the content type UIDs of the referenced entries returned in the response.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeReferenceContentTypeUID().Fetch<Entry>();
```

## IncludeReference

Add a constraint that requires a particular reference key details.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeReference(new String[]{"reference_uid_1", "reference_uid_2"}).Fetch<Entry>();
```

Array key that to be constrained.

## IncludeReference

Add a constraint that requires a particular reference key details.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeReference("reference_uid_1").Fetch<Entry>();
```

Key that to be constrained.

## IncludeOnlyReference

Specifies an array of except keys that would be excluded in the response.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeOnlyReference(new String[]{"name", "description"},"referenceUid").Fetch<Entry>();
```

Array of the only reference keys to be included in response.

Key who has reference to some other class object.

## IncludeExceptReference

Specifies an array of except keys that would be excluded in the response.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeExceptReference(new String[]{"name", "description"},"referenceUid").Fetch<Entry>();
```

Array of the except reference keys to be excluded in response.

Key who has reference to some other class object.

## IncludeEmbeddedItems

Include Embedded Objects (Entries and Assets) along with entry/entries details.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeEmbeddedItems().Fetch<Entry>();
```

## IncludeFallback

Include fallback locale publish content, if specified locale content is not publish.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeFallback().Fetch<Entry>();
```

## IncludeMetadata

The includeMetadata method will add the meta information to the response.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeMetadata().Fetch<Entry>();
```

## IncludeBranch

Include branch for publish content.

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeBranch().Fetch<Entry>();
```

## Only

Specifies an array of 'only' keys in BASE object that would be 'included' in the response.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
AssetLibrary assetLibrary = await stack.Entry().Only(new String[]{"name", "description"}).Fetch();
```

Array of the only reference keys to be included in response.

## Except

Specifies list of field uids that would be excluded from the response.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
AssetLibrary assetLibrary = await stack.Entry("entry_uid").Except(new String[]{"name", "description"}).Fetch();
```

Field uid which get excluded from the response.

## ToJson

Get key/value pairs in json of current instance.

```
using Contentstack.Core; 
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Entry entry = await stack.ContentType("content_Type_uid").Entry("entry_uid").IncludeReferenceContentTypeUID().Fetch<Entry>();
JsonObject jObject = entry.ToJson();
```

## Fetch

Fetches the latest version of the entries from Contentstack.io content stack

```
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");
Product product = await stack.ContentType("content_Type_uid").Entry("entry_uid").Fetch<Product>();
```

## Variants

The variants method retrieves details of a specific entry variant or an array of entry variants based on the applied query.

When Personalize creates a variant in the CMS, it assigns a "Variant Alias" to identify that specific variant. When fetching entry variants using the Delivery API, you can pass variant aliases in place of variant UIDs in the x-cs-variant-uid header.

```
Example:
using Contentstack.Core;
using Contentstack.Core.Models;

ContentstackClient stack = new ContentstackClient("api_key", "delivery_token", "environment");

Entry entry = await stack
                    .ContentType("content_Type_uid")
                    .Entry("entry_uid")
                    .Variant(new String[]{"variant_uid1/variant_alias1", "variant_uid2/variant_alias2"})
                    .Fetch<Entry>();
```

List of variants

## assetFields

The assetFields method specifies which asset-related fields are included in the API response when fetching an entry or querying entries.

**Regional Behavior**

This method is currently supported only for stacks located in the **North America (NA)** region.

**For stacks in the Europe (EU) or Azure North America (Azure NA) regions:**

*   The API ignores the asset\_fields\[\] parameter.
*   The response returns the default asset metadata.
*   The system does not return an error or warning message if the parameter is used.

If you are working in these regions, ensure your application logic accounts for the full default metadata response rather than a filtered set of fields.

```
Returns the current Entry instance to enable method chaining. For example: Entry("id").AssetFields("...").Fetch<Entry>().
Request behavior: Calling AssetFields(...) only records the asset fields and does not make an API request.Execution: The HTTP request runs only when you call Fetch<T>() (single entry) or Find<T>() (multiple entries).Query parameter: The specified asset fields are sent as the asset_fields[] query parameter so that only those asset-related fields are returned in the response.Parameter Behavior
Specifies which asset-related metadata fields the CDA returns for assets referenced in the entry or entries.Applied when using stack.ContentType(uid).Entry(uid).AssetFields(...).Fetch<T>() or stack.ContentType(uid).Entry().AssetFields(...).Find<T>().When provided, the SDK sends the selected fields as the asset_fields[] query parameter. Only the requested asset metadata is returned in the API response.Supported Parameter Values
user_defined_fieldsembedded_metadataai_generated_metadatavisual_markupsNote: If AssetFields(...) is not called, or is called with no arguments, null, or an empty array, the SDK does not add the asset_fields[] query parameter. The CDA then returns the default asset metadata for referenced assets.
Fetch a single entry with specific fields
using Contentstack.Core;
using Contentstack.Core.Configuration;
using Contentstack.Core.Models;
using Microsoft.Extensions.Options;

var options = new ContentstackOptions
{
    ApiKey = "<API_KEY>",
    DeliveryToken = "<DELIVERY_TOKEN>",
    Environment = "<ENVIRONMENT>"
};

var stack = new ContentstackClient(new OptionsWrapper<ContentstackOptions>(options));

var entry = await stack
    .ContentType("blog_post")
    .Entry("entry_uid")
    .AssetFields("user_defined_fields", "embedded_metadata", "ai_generated_metadata")
    .Fetch<Entry>();Query multiple entries with asset fields
using Contentstack.Core;
using Contentstack.Core.Configuration;
using Contentstack.Core.Models;
using Microsoft.Extensions.Options;

var options = new ContentstackOptions
{
    ApiKey = "<API_KEY>",
    DeliveryToken = "<DELIVERY_TOKEN>",
    Environment = "<ENVIRONMENT>"
};

var stack = new ContentstackClient(new OptionsWrapper<ContentstackOptions>(options));

var result = await stack
    .ContentType("blog_post")
    .Entry()
    .AssetFields("user_defined_fields", "embedded_metadata")
    .Find<Entry>();
```

Asset field names to include in the response.

## Entry

Set key/value attributes of Metadata.

Set key/value attributes of an current entry instance.

Set array of Tags

Title of an entry

This is Entry Uid of an entry.

Set key/value attributes of Metadata.

Set key/value attributes of an current entry instance.

Set array of Tags

Title of an entry

This is Entry Uid of an entry.

## Entry | .NET Delivery SDK | Contentstack

Entry creates and retrieves single entry objects in the .NET Delivery SDK, giving access to the content stored within a Contentstack entry.