# LongTermRetentionPolicyProxy

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

Represents the LongTermRetentionPolicy Azure Provisioning model.

## Definition

```typescript
interface LongTermRetentionPolicyProxy {
  backupStorageAccessTier: BicepValueProxy | SqlBackupStorageAccessTier;
  readonly id: BicepValueProxy;
  makeBackupsImmutable: BicepValueProxy | boolean;
  monthlyRetention: BicepValueProxy | string;
  readonly name: BicepValueProxy | string;
  parent: SqlDatabaseProxy;
  readonly systemData: SqlSystemDataProxy;
  weeklyRetention: BicepValueProxy | string;
  weekOfYear: BicepValueProxy | number;
  yearlyRetention: BicepValueProxy | string;
  addTo(infrastructure: AzureResourceInfrastructure): void;
  clearBackupStorageAccessTier(): void;
  clearMakeBackupsImmutable(): void;
  clearMonthlyRetention(): void;
  clearWeeklyRetention(): void;
  clearWeekOfYear(): void;
  clearYearlyRetention(): void;
}
```

## Properties

- `backupStorageAccessTier`: `BicepValueProxy | SqlBackupStorageAccessTier` `get - set` -- Gets or sets the BackupStorageAccessTier provisioning property.
- `id`: `BicepValueProxy` `get` -- Gets the Id provisioning property.
- `makeBackupsImmutable`: `BicepValueProxy | boolean` `get - set` -- Gets or sets the MakeBackupsImmutable provisioning property.
- `monthlyRetention`: `BicepValueProxy | string` `get - set` -- Gets or sets the MonthlyRetention provisioning property.
- `name`: `BicepValueProxy | string` `get` -- Gets the Name provisioning property.
- `parent`: [SqlDatabaseProxy](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/sqldatabaseproxy.md) `get - set` -- Gets or sets the Parent provisioning property.
- `systemData`: [SqlSystemDataProxy](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/sqlsystemdataproxy.md) `get` -- Gets the SystemData provisioning property.
- `weeklyRetention`: `BicepValueProxy | string` `get - set` -- Gets or sets the WeeklyRetention provisioning property.
- `weekOfYear`: `BicepValueProxy | number` `get - set` -- Gets or sets the WeekOfYear provisioning property.
- `yearlyRetention`: `BicepValueProxy | string` `get - set` -- Gets or sets the YearlyRetention provisioning property.

## Methods

- [addTo](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/longtermretentionpolicyproxy/addto.md) -- `method` -- Adds this provisioning resource to the Azure resource infrastructure.
    ```typescript
  addTo(infrastructure: AzureResourceInfrastructure): void
  ```
- [clearBackupStorageAccessTier](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/longtermretentionpolicyproxy/clearbackupstorageaccesstier.md) -- `method` -- Clears the BackupStorageAccessTier provisioning property.
    ```typescript
  clearBackupStorageAccessTier(): void
  ```
- [clearMakeBackupsImmutable](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/longtermretentionpolicyproxy/clearmakebackupsimmutable.md) -- `method` -- Clears the MakeBackupsImmutable provisioning property.
    ```typescript
  clearMakeBackupsImmutable(): void
  ```
- [clearMonthlyRetention](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/longtermretentionpolicyproxy/clearmonthlyretention.md) -- `method` -- Clears the MonthlyRetention provisioning property.
    ```typescript
  clearMonthlyRetention(): void
  ```
- [clearWeeklyRetention](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/longtermretentionpolicyproxy/clearweeklyretention.md) -- `method` -- Clears the WeeklyRetention provisioning property.
    ```typescript
  clearWeeklyRetention(): void
  ```
- [clearWeekOfYear](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/longtermretentionpolicyproxy/clearweekofyear.md) -- `method` -- Clears the WeekOfYear provisioning property.
    ```typescript
  clearWeekOfYear(): void
  ```
- [clearYearlyRetention](/reference/api/typescript/aspire.hosting.azure.provisioning.sql/longtermretentionpolicyproxy/clearyearlyretention.md) -- `method` -- Clears the YearlyRetention provisioning property.
    ```typescript
  clearYearlyRetention(): void
  ```
