# normalizePlaygroundOAuth2

**Kind:** Function

**Source:** [`atloria-monorepo/apps/api/src/project/playground-oauth2-input.ts`](https://github.com/sherkety/atloria/blob/main/atloria-monorepo/apps/api/src/project/playground-oauth2-input.ts#L68)

Validate an owner's OAuth2 declaration and return what to store, or null to clear it.

Throws `BadRequestException` with a message meant for the owner, not for a log line.

## Signature

```ts
function normalizePlaygroundOAuth2(input: unknown, current: PlaygroundOAuth2Config | null): PlaygroundOAuth2Config | null
```

## Parameters

| Name | Type |
|---|---|
| `input` | `unknown` |
| `current` | `PlaygroundOAuth2Config | null` |

**Returns:** `PlaygroundOAuth2Config | null`
