---
editLink: false
lastUpdated: false
---

[@salesforce/b2c-tooling-sdk](../../modules.md) / [project-index](../index.md) / BuildProjectIndexOptions

# Interface: BuildProjectIndexOptions

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:52](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L52)

Options for [buildProjectIndex](../functions/buildProjectIndex.md).

## Properties

### cartridgePath?

> `optional` **cartridgePath**: `string`[]

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:68](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L68)

Cartridge path order (names), applied to discovered cartridges.

***

### cartridgePathSource?

> `optional` **cartridgePathSource**: [`CartridgeOrder`](CartridgeOrder.md)

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:73](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L73)

Where `cartridgePath` came from, reported as [ProjectIndex.cartridgeOrder](ProjectIndex.md#cartridgeorder). Defaults to
`{source: 'configured'}`; pass `{source: 'instance', siteId, hostname}` for a path read from an instance.

***

### cartridges?

> `optional` **cartridges**: [`CartridgeLocation`](../../cartridges/interfaces/CartridgeLocation.md)[]

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:58](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L58)

Cartridges to index, in cartridge path order. Overrides discovery.

***

### detectSitePath?

> `optional` **detectSitePath**: `boolean`

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:79](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L79)

Without `cartridgePath` or `cartridges`, order by a site cartridge path found
in the project's site import files (`sites/<id>/site.xml`, the latest by
migration or import set timestamp). Defaults to true.

***

### host?

> `optional` **host**: [`CartridgeFileSystemHost`](../../cartridges/interfaces/CartridgeFileSystemHost.md)

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:82](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L82)

***

### includeAllCartridges?

> `optional` **includeAllCartridges**: `boolean`

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:64](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L64)

Index every cartridge in the project, not just those on the cartridge path: path cartridges first in path
order, then the rest in discovery order (as if the site ran them all). `notOnPath` is still reported.
Defaults to false.

***

### otherCartridges?

> `optional` **otherCartridges**: [`CartridgeLocation`](../../cartridges/interfaces/CartridgeLocation.md)[]

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:66](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L66)

With `cartridges`: cartridges in the project that aren't on the path, reported as [ProjectIndex.otherCartridges](ProjectIndex.md#othercartridges).

***

### paths?

> `optional` **paths**: `string`[]

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:56](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L56)

Additional directories to search for cartridges.

***

### root?

> `optional` **root**: `string`

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:54](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L54)

Directory to search for cartridges when `cartridges` is not given. Defaults to the current directory.

***

### siteId?

> `optional` **siteId**: `string`

Defined in: [packages/b2c-tooling-sdk/src/project-index/build.ts:81](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/project-index/build.ts#L81)

Site whose site.xml cartridge path to use; defaults to the best match.
