# CognitiveServicesConnectionOAuth2Proxy

- Module: [Aspire.Hosting.Azure.Provisioning.CognitiveServices](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices.md)
- Version: `17.0.0-preview.1.26567.5`
- Kind: `handle`
- Source: [GitHub](https://github.com/microsoft/aspire/tree/2d325b13709752ba6d9a943635c5e2940a2530c0)

Represents the CognitiveServicesConnectionOAuth2 Azure Provisioning model.

## Definition

```typescript
interface CognitiveServicesConnectionOAuth2Proxy {
  authUri: BicepValueProxy | uri;
  clientId: BicepValueProxy | guid;
  clientSecret: BicepValueProxy | string;
  developerToken: BicepValueProxy | string;
  password: BicepValueProxy | string;
  refreshToken: BicepValueProxy | string;
  tenantId: BicepValueProxy | guid;
  username: BicepValueProxy | string;
  clearAuthUri(): void;
  clearClientId(): void;
  clearClientSecret(): void;
  clearDeveloperToken(): void;
  clearPassword(): void;
  clearRefreshToken(): void;
  clearTenantId(): void;
  clearUsername(): void;
}
```

## Properties

- `authUri`: `BicepValueProxy | uri` `get - set` -- Gets or sets the AuthUri provisioning property.
- `clientId`: `BicepValueProxy | guid` `get - set` -- Gets or sets the ClientId provisioning property.
- `clientSecret`: `BicepValueProxy | string` `get - set` -- Gets or sets the ClientSecret provisioning property.
- `developerToken`: `BicepValueProxy | string` `get - set` -- Gets or sets the DeveloperToken provisioning property.
- `password`: `BicepValueProxy | string` `get - set` -- Gets or sets the Password provisioning property.
- `refreshToken`: `BicepValueProxy | string` `get - set` -- Gets or sets the RefreshToken provisioning property.
- `tenantId`: `BicepValueProxy | guid` `get - set` -- Gets or sets the TenantId provisioning property.
- `username`: `BicepValueProxy | string` `get - set` -- Gets or sets the Username provisioning property.

## Methods

- [clearAuthUri](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/clearauthuri.md) -- `method` -- Clears the AuthUri provisioning property.
    ```typescript
  clearAuthUri(): void
  ```
- [clearClientId](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/clearclientid.md) -- `method` -- Clears the ClientId provisioning property.
    ```typescript
  clearClientId(): void
  ```
- [clearClientSecret](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/clearclientsecret.md) -- `method` -- Clears the ClientSecret provisioning property.
    ```typescript
  clearClientSecret(): void
  ```
- [clearDeveloperToken](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/cleardevelopertoken.md) -- `method` -- Clears the DeveloperToken provisioning property.
    ```typescript
  clearDeveloperToken(): void
  ```
- [clearPassword](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/clearpassword.md) -- `method` -- Clears the Password provisioning property.
    ```typescript
  clearPassword(): void
  ```
- [clearRefreshToken](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/clearrefreshtoken.md) -- `method` -- Clears the RefreshToken provisioning property.
    ```typescript
  clearRefreshToken(): void
  ```
- [clearTenantId](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/cleartenantid.md) -- `method` -- Clears the TenantId provisioning property.
    ```typescript
  clearTenantId(): void
  ```
- [clearUsername](/reference/api/typescript/aspire.hosting.azure.provisioning.cognitiveservices/cognitiveservicesconnectionoauth2proxy/clearusername.md) -- `method` -- Clears the Username provisioning property.
    ```typescript
  clearUsername(): void
  ```
