---
title: "TermQuery"
description: "TermQuery"
url: "https://www.contentstack.com/docs/developers/sdks/content-delivery-sdk/typescript/reference/termquery"
product: "Contentstack"
doc_type: "guide"
audience:
  - developers
  - admins
version: "current"
last_updated: "2026-09-04"
---

# TermQuery

## TermQuery

TermQuery lets you query and retrieve multiple published terms within a specific taxonomy.

Name

Type

Description

taxonomyUid

string

UID of the taxonomy

**Note**: TermQuery has no public constructor. Get an instance through stack.taxonomy(taxonomyUid).term(), called with no term UID. Passing a term UID to term(termUid) instead returns a Term instance, for a single term.

## locale

The locale method scopes the query to terms published in the specified locale.

```
ValidationThere is no client-side validation of the locale code. An invalid or unpublished locale is not rejected at this step because locale only stores the value on the query. The API rejects it on the subsequent find() call. See Delivery API Errors.
BehaviorClient-side only. Sets the locale query parameter and returns the same TermQuery instance for chaining. No HTTP call is made until find() is called.
Exampleconst result = await stack
    .taxonomy(taxonomy_uid)
    .term()
    .locale('hi-in')
    .find()
```

Locale code (for example, hi-in, en-us).

## includeFallback

The includeFallback method falls back to the master locale for a term that is not localized in the requested locale.

```
ValidationThis method takes no parameters. There is no client-side validation. Calling includeFallback() without first calling locale() does not throw. The API applies its own default locale behavior in that case.
BehaviorClient-side only. Sets the include_fallback query parameter to 'true' and returns the same TermQuery instance for chaining. No HTTP call is made until find() is called.
Exampleconst result = await stack
    .taxonomy(taxonomy_uid)
    .term()
    .locale('hi-in')
    .includeFallback()
    .find()
```

## find

The find method retrieves a list of all published terms within a specific taxonomy.

```
ValidationThis method takes no parameters. There is no client-side validation. It sends the accumulated query parameters (locale, include_fallback) set by prior chained calls. See Delivery API Errors.
BehaviorMaps to a single GET request to /taxonomies/&#123;taxonomy_uid&#125;/terms with the accumulated query parameters. The full response object is returned as-is (not unwrapped), matching the FindResponse shape used elsewhere in the SDK.
Exampleconst result = await stack
    .taxonomy(taxonomy_uid)
    .term()
    .find()

// With locale and fallback
const localized = await stack
    .taxonomy(taxonomy_uid)
    .term()
    .locale('hi-in')
    .includeFallback()
    .find()
```

## TermQuery | TypeScript Delivery SDK | Contentstack

TermQuery represents a query for fetching multiple published terms in the TypeScript Delivery SDK, with locale filtering, locale fallback, and find.