# PimTrashedCollection

The PimTrashedCollection type of the TypeScript SDK, which calendars.listTrash and addressbooks.listTrash take or answer.

```ts
type PimTrashedCollection = {
  color: string | null
  components: ('VEVENT' | 'VTODO')[] | null
  createdAt: number
  description: string | null
  displayName: string | null
  expiresAt: number
  id: string
  kind: ('calendar' | 'addressbook')
  name: string
  objectCount: number
  role: string | null
  trashedAt: number
}
```

## Fields

| Field | Type | Description |
| --- | --- | --- |
| `color` | `string` \| `null` |  |
| `components` | `('VEVENT' \| 'VTODO')[] \| null` | Supported primary components, in VEVENT then VTODO order; null for addressbooks. Legacy mixed calendars may also retain journals or unparsed resources. Narrowing refuses with components_conflict and a count of incompatible live and restorable trashed objects. |
| `createdAt` | `number` | Creation timestamp in epoch seconds |
| `description` | `string` \| `null` |  |
| `displayName` | `string` \| `null` |  |
| `expiresAt` | `number` | When the purge duty removes it and its members for good, in epoch seconds |
| `id` | `string` | Collection ULID: the same id it had, and will have again |
| `kind` | `('calendar' \| 'addressbook')` | Collection type ('calendar' or 'addressbook') |
| `name` | `string` | URL slug it had; a restore refuses (409 name_taken) while a live collection holds it |
| `objectCount` | `number` | Members that went with it, and come back with it |
| `role` | `string` \| `null` | Special role ('tasks'), or null; the default collection cannot be deleted |
| `trashedAt` | `number` | When it was deleted, in epoch seconds |

## Used by

| Method | What it does |
| --- | --- |
| [`calendars.listTrash`](/docs/sdks/typescript/calendars/list-trash) | List deleted calendars |
| [`addressbooks.listTrash`](/docs/sdks/typescript/addressbooks/list-trash) | List deleted addressbooks |
