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

# Entry

## Entry

An Entry is the actual piece of content created using one of the defined content types.

## query()

To fetch all or find Entries query method is used.

```
let stack = Contentstack.stack(apiKey: "<API_KEY>", deliveryToken: "<DELIVERY_TOKEN>", environment: "<ENVIRNOMENT>")

let query = stack.contentType(uid: "<CONTENT_TYPE_UID>").entry(uid: "<ENTRY_UID>").query()
```

## query(_:)

To fetch all or find Entries to specific model query method is used.

```
let stack = Contentstack.stack(apiKey: "<API_KEY>", deliveryToken: "<DELIVERY_TOKEN>", environment: "<ENVIRNOMENT>")

let query = stack.contentType(uid: "<CONTENT_TYPE_UID>").entry(uid: "<ENTRY_UID>").query(Product.self)
```

A entry type for querying on.

## fetch(_:)

This call fetches the latest version of a specific Entry of a particular stack.

```
let stack = Contentstack.stack(apiKey: "<API_KEY>", deliveryToken: "<DELIVERY_TOKEN>", environment: "<ENVIRNOMENT>")

stack.contentType(uid: "<CONTENT_TYPE_UID>").entry(uid: "<ENTRY_UID>")
.fetch { (result: Result<EntryModel, Error>, response: ResponseType) in
   switch result {
   case .success(let model):

   case .failure(let error):

   }
}
```

A handler which will be called on completion of the operation.

## 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 1:
import Contentstack
let stack = Contentstack.stack(
    apiKey: <API_KEY>,
    deliveryToken: <DELIVERY_TOKEN>,
    environment: <ENVIRONMENT>
)

stack
.contentType(uid: <CT_UID>)
.entry(uid: <ENTRY_UID>)
.variants(uid: <VARIANT_UID/VARIANT_ALIAS>)
.fetch { (result: Result<EntryModel, Error>, response: ResponseType) in
    switch result {
        case .success(let contentstackResponse):
            // Contentstack response with variant entry data
        case .failure(let error):
            // Error Message
    }
}
Example 2:
import Contentstack
let stack = Contentstack.stack(
    apiKey: <API_KEY>,
    deliveryToken: <DELIVERY_TOKEN>,
    environment: <ENVIRONMENT>
)

stack
.contentType(uid: <CT_UID>)
.entry(uid: <ENTRY_UID>)
.variants(uids: [<VARIANT_UID_1/VARIANT_ALIAS_1>, <VARIANT_UID_2/<VARIANT_ALIAS_2>, <VARIANT_UID_3/VARIANT_ALIAS_3>])
.fetch { (result: Result<EntryModel, Error>, response: ResponseType) in
    switch result {
        case .success(let contentstackResponse):
            // Contentstack response with variant entry data
        case .failure(let error):
            // Error Message
    }
}
```

Enter the UID of the variant

Set cache policy for the entry request.

Stack instance for Entry to be fetched

URI Parameters.

Query parameter

## Entry | Swift Delivery SDK | Contentstack

Entry represents an actual piece of content created from a defined content type in the Contentstack Swift Delivery SDK.