---
title: Catalog data sources
slug: commerce-connect-13/docs/catalog-data-sources
docTags: 
createdAt: 2026-07-23T09:44:51.000Z
---

:::hint{type="warning"}
**Note**
This feature applies to Optimizely Commerce Connect versions 10 to 13 and is subject to removal in future releases.
:::

Classes in this topic are in the Mediachase.Commerce.Catalog.DataSources namespace.

## Key classes and files

- CatalogIndexSearchDataSource. Represents a catalog search data source for data-bound controls.
- CatalogItemsDataSource.cs. Represents a catalog item's data source for data-bound controls.
- CatalogSearchDataSource.cs. Represents catalog search data source for data-bound controls.

## Overview

The following image shows the Catalog Data Sources API structure.

![](https://api.archbee.com/api/optimize/BrbvVORKJ5iIeSMZye5kI/gOVxKse-foZkz3kuZKvLD-20260723-094559.png "catalogdatasources.png")

**Example:** creating a CatalogIndexSearchDataSource

```csharp
private CatalogIndexSearchDataSource CreateCatalogIndexSearchDataSource()
      {
        // Set up CatalogEntrySearchCriteria object.
        SearchFilterHelper sfHelper = SearchFilterHelper.Current;
        string keywords = Request.QueryString["search"];
        SearchSort sortObject = CatalogEntrySearchCriteria.DefaultSortOrder
        CatalogEntrySearchCriteria criteria = sfHelper.CreateSearchCriteria(keywords, sortObject);
    
        // Set up CatalogIndexSearchDataSource object.
        int startIndex = SomeListView.StartRowIndex;
        int recordsToRetrieve = pageSize;
        int count = 0;
        CatalogEntryResponseGroup responseGroup = new CatalogEntryResponseGroup(CatalogEntryResponseGroup.ResponseGroup.CatalogEntryInfo);
        bool cacheResults = true;
        TimeSpan cacheTimeout = new TimeSpan(0, 0, 30);
    
        //...
    
        CatalogIndexSearchDataSource dataSource = null;
    
        // No need to perform search if there are no catalogs specified.
        if (criteria.CatalogNames.Count != 0)
          {
            Entries entries = sfHelper.SearchEntries(criteria, startIndex, recordsToRetrieve, out count, responseGroup, cacheResults, cacheTimeout);
            dataSource = new CatalogIndexSearchDataSource();
            dataSource.TotalResults = count;
            dataSource.CatalogEntries = entries;
          }
    
        return dataSource;
      }
```

After creating the CatalogIndexSearchDataSource object, you can bind it to an ASP.NET server control that supports data binding, such as the ListView control. When done, you have access to a collection of catalog entry results.

**Example:** accessing a catalog entry results collection

```csharp
SomeListView.DataSource = CatalogIndexSearchDataSource
    CatalogIndexSearchDataSource.CatalogEntries // propety of type Entries
    CatalogIndexSearchDataSource.CatalogEntries.Entry // array of type Entry[]
```
