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

[@salesforce/b2c-tooling-sdk](../../modules.md) / [logging](../index.md) / redactLogValue

# Function: redactLogValue()

> **redactLogValue**\<`T`\>(`value`): `T`

Defined in: [packages/b2c-tooling-sdk/src/logging/redaction.ts:164](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/d7ff38c7ca2b1411cd718b9554500c9416f00266/packages/b2c-tooling-sdk/src/logging/redaction.ts#L164)

Returns a copy of `value` with secrets removed, at any depth:

- values of keys that name a secret (`password`, `clientSecret`,
  `refresh_token`, `authorization`, `clientCredentials`, ...);
- JWTs, `Bearer`/`Basic` credentials and form-encoded secrets
  (`client_secret=...`) inside any string.

Use it on entries a host logs itself, or register [deepLogRedactor](../variables/deepLogRedactor.md)
to apply it to every SDK log entry.

## Type Parameters

### T

`T`

## Parameters

### value

`T`

## Returns

`T`
