> ## Documentation Index
> Fetch the complete documentation index at: https://docs.superoffice.com/llms.txt
> Use this file to discover all available pages before exploring further.

# SuperOffice.WebApi.Agents.IFreeTextAgent

<h1 id="SuperOffice_WebApi_Agents_IFreeTextAgent">
  Interface IFreeTextAgent
</h1>

Namespace: [SuperOffice.WebApi.Agents](SuperOffice.WebApi.Agents.md)\
Assembly: SuperOffice.WebApi.dll

This agent can be used to manage the free text system

```csharp theme={null}
public interface IFreeTextAgent : IAgentBase, IDisposable
```

#### Implements

[IAgentBase](SuperOffice.WebApi.Agents.IAgentBase.md),
[IDisposable](https://learn.microsoft.com/dotnet/api/system.idisposable)

## Methods

<h3 id="SuperOffice_WebApi_Agents_IFreeTextAgent_FreetextIndexRowsAsync_System_String_System_Int32___SuperOffice_WebApi_RequestOptions_">
  FreetextIndexRowsAsync(string, int\[], RequestOptions)
</h3>

Update the freetext index for one or more rows from the same table

```csharp theme={null}
Task FreetextIndexRowsAsync(string tableName, int[] iDs, RequestOptions requestOptions = null)
```

#### Parameters

`tableName` [string](https://learn.microsoft.com/dotnet/api/system.string)

The name of the table the rows come from; this table should have at least one freetext-indexable field

`iDs` [int](https://learn.microsoft.com/dotnet/api/system.int32)\[]

One or more primary keys, identifying records to be (re)indexed. It doesn't matter if they have been indexed before or not

`requestOptions` [RequestOptions](SuperOffice.WebApi.RequestOptions.md)

Override language/culture codes on this request.

#### Returns

[Task](https://learn.microsoft.com/dotnet/api/system.threading.tasks.task)

This method has no return value

<h3 id="SuperOffice_WebApi_Agents_IFreeTextAgent_GetStatusAsync_SuperOffice_WebApi_RequestOptions_">
  GetStatusAsync(RequestOptions)
</h3>

Returns status for the freetext search words

```csharp theme={null}
Task<FreeText> GetStatusAsync(RequestOptions requestOptions = null)
```

#### Parameters

`requestOptions` [RequestOptions](SuperOffice.WebApi.RequestOptions.md)

Override language/culture codes on this request.

#### Returns

[Task](https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1)\<[FreeText](SuperOffice.WebApi.Data.FreeText.md)\&gt;

The freetext status

<h3 id="SuperOffice_WebApi_Agents_IFreeTextAgent_RegenerateIndexAsync_System_Boolean_SuperOffice_WebApi_RequestOptions_">
  RegenerateIndexAsync(bool, RequestOptions)
</h3>

Wipe and regenerate the freetext index by scanning the database (freetext search will be unavailable while this operation runs

```csharp theme={null}
Task<BatchTaskInfo> RegenerateIndexAsync(bool runAsBatch, RequestOptions requestOptions = null)
```

#### Parameters

`runAsBatch` [bool](https://learn.microsoft.com/dotnet/api/system.boolean)

If true, then execute the regeneration as a Batch Task; the service call will return immediately. Otherwise wait until the task completes, may cause a timeout if called as a Web Service

`requestOptions` [RequestOptions](SuperOffice.WebApi.RequestOptions.md)

Override language/culture codes on this request.

#### Returns

[Task](https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1)\<[BatchTaskInfo](SuperOffice.WebApi.Data.BatchTaskInfo.md)\&gt;

Information about the batch task, if batch execution was requested. Otherwise null

<h3 id="SuperOffice_WebApi_Agents_IFreeTextAgent_SetEnabledAsync_System_Boolean_SuperOffice_WebApi_RequestOptions_">
  SetEnabledAsync(bool, RequestOptions)
</h3>

Sets freetext search to enabled (true) or disabled (false)

```csharp theme={null}
Task SetEnabledAsync(bool enabled, RequestOptions requestOptions = null)
```

#### Parameters

`enabled` [bool](https://learn.microsoft.com/dotnet/api/system.boolean)

If enabled true, else false

`requestOptions` [RequestOptions](SuperOffice.WebApi.RequestOptions.md)

Override language/culture codes on this request.

#### Returns

[Task](https://learn.microsoft.com/dotnet/api/system.threading.tasks.task)

This method has no return value

<h3 id="SuperOffice_WebApi_Agents_IFreeTextAgent_SetMultiWordOperatorAsync_SuperOffice_WebApi_Data_FreeTextOperator_SuperOffice_WebApi_RequestOptions_">
  SetMultiWordOperatorAsync(FreeTextOperator, RequestOptions)
</h3>

Sets the operator used when matching multiple words

```csharp theme={null}
Task SetMultiWordOperatorAsync(FreeTextOperator freeTextOperator, RequestOptions requestOptions = null)
```

#### Parameters

`freeTextOperator` [FreeTextOperator](SuperOffice.WebApi.Data.FreeTextOperator.md)

The operator

`requestOptions` [RequestOptions](SuperOffice.WebApi.RequestOptions.md)

Override language/culture codes on this request.

#### Returns

[Task](https://learn.microsoft.com/dotnet/api/system.threading.tasks.task)

No return value

<h3 id="SuperOffice_WebApi_Agents_IFreeTextAgent_SetSingleWordOperatorAsync_SuperOffice_WebApi_Data_FreeTextOperator_SuperOffice_WebApi_RequestOptions_">
  SetSingleWordOperatorAsync(FreeTextOperator, RequestOptions)
</h3>

Sets the operator used when matching single words

```csharp theme={null}
Task SetSingleWordOperatorAsync(FreeTextOperator freeTextOperator, RequestOptions requestOptions = null)
```

#### Parameters

`freeTextOperator` [FreeTextOperator](SuperOffice.WebApi.Data.FreeTextOperator.md)

The operator

`requestOptions` [RequestOptions](SuperOffice.WebApi.RequestOptions.md)

Override language/culture codes on this request.

#### Returns

[Task](https://learn.microsoft.com/dotnet/api/system.threading.tasks.task)

This method has no return value


## Related topics

- [SuperOffice.WebApi.Agents.FreeTextAgent](/en/api/reference/webapi/SuperOffice.WebApi.Agents.FreeTextAgent.md)
- [SuperOffice.WebApi.Data.FreeText](/en/api/reference/webapi/SuperOffice.WebApi.Data.FreeText.md)
- [SuperOffice.WebApi.Agents](/en/api/reference/webapi/SuperOffice.WebApi.Agents.md)
- [SuperOffice.WebApi.Data.FreeTextOperator](/en/api/reference/webapi/SuperOffice.WebApi.Data.FreeTextOperator.md)
- [SuperOffice.WebApi.Data.FreeText FreetextIndexRowsRequest](/en/api/reference/webapi/SuperOffice.WebApi.Data.FreeText_FreetextIndexRowsRequest.md)
- [SuperOffice.WebApi.Data.FreeText GetStatusRequest](/en/api/reference/webapi/SuperOffice.WebApi.Data.FreeText_GetStatusRequest.md)
