# Queries / Trashed Items

# Trashed Items

**Query**
## trashedItems — Returns [ConnectionType](/documentation/General/Connections) of [TrashedItem](/documentation/Objects/Trashed-Item#TrashedItem)

**Scopes required:** see_trashed_items

### Sortable Fields
*Fields from [TrashedItem](/documentation/Objects/Trashed-Item#TrashedItem) that can be used to sort the connection items*

- name
- deletedAt

| Arguments | Type | Description |
| --- | --- | --- |
| search | *String* | Needle to use to search through the trashed items |
| type | [RecoverableTrashTypeEnum](/documentation/Enums/Recoverable-Trash-Type-Enum#RecoverableTrashTypeEnum) | Filter by type |
| deletedAfter | [Date](/documentation/Types/Date#Date) | The start of when the items were deleted (inclusive) |
| deletedBefore | [Date](/documentation/Types/Date#Date) | The end of when the items were deleted (inclusive) |

**Example Query**

```graphql
query GetTrashedItems($search: String) {
    trashedItems(search: $search) {
        edges {
            node {
                id,
                type,
                name,
                deletedAt
            }
        },
        pageInfo {
            hasNextPage,
            endCursor
        }
    }
}

# Example variables
{
    "search": "<SEARCH>"
}
```