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

[@salesforce/b2c-tooling-sdk](../../../modules.md) / [operations/logs](../index.md) / LogWatch

# Interface: LogWatch

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

A running tail of instance logs that buffers entries until they are polled,
for hosts that read logs in turns (agent tools, request/response UIs) rather
than through callbacks.

## Properties

### prefixes

> `readonly` **prefixes**: `string`[]

Defined in: [packages/b2c-tooling-sdk/src/operations/logs/watch.ts:53](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/operations/logs/watch.ts#L53)

## Methods

### info()

> **info**(): [`LogWatchInfo`](LogWatchInfo.md)

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

#### Returns

[`LogWatchInfo`](LogWatchInfo.md)

***

### poll()

> **poll**(`options?`): `Promise`\<[`LogWatchPoll`](LogWatchPoll.md)\>

Defined in: [packages/b2c-tooling-sdk/src/operations/logs/watch.ts:55](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/operations/logs/watch.ts#L55)

Wait up to `timeoutMs` for activity, then drain buffered entries and events.

#### Parameters

##### options?

[`LogWatchPollOptions`](LogWatchPollOptions.md)

#### Returns

`Promise`\<[`LogWatchPoll`](LogWatchPoll.md)\>

***

### stop()

> **stop**(): `Promise`\<`void`\>

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

Stop tailing. Unread entries stay readable through `poll()`. Safe to repeat.

#### Returns

`Promise`\<`void`\>
