# Returns trashed documents in a document space.

GET https://api.awork.com/api/v1/documentspaces/{documentSpaceId}/documents/trash

Returns deleted documents visible in the specified document space.
            <Check title="Required Permissions" icon="key">The user must have at least `read` permission for the specified document space.</Check>

## Request example

```sh
curl -X GET --globoff 'https://api.awork.com/api/v1/documentspaces/{documentSpaceId}/documents/trash' \
  -H 'Authorization: Bearer <token>'
```

- path parameter `documentSpaceId`: string (required). The id of the document space to retrieve trashed documents from.

- query parameter `page`: integer. Page number for pagination

- query parameter `pageSize`: integer. Number of items per page

- query parameter `orderby`: string. The properties to order by

- query parameter `filterby`: string. The filter expression to filter by

## Response 200

OK

application/json

```json
[
  {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "createdOn": "2022-03-11T15:33:47.100Z",
    "createdBy": "123e4567-e89b-12d3-a456-426614174000",
    "updatedOn": "2022-03-11T21:15:00.100Z",
    "updatedBy": "123e4567-e89b-12d3-a456-426614174000",
    "name": "string",
    "currentDocumentVersionId": "123e4567-e89b-12d3-a456-426614174000",
    "documentSpaceId": "123e4567-e89b-12d3-a456-426614174000",
    "documentSpace": {
      "id": "123e4567-e89b-12d3-a456-426614174000",
      "createdOn": "2022-03-11T15:33:47.100Z",
      "createdBy": "123e4567-e89b-12d3-a456-426614174000",
      "updatedOn": "2022-03-11T21:15:00.100Z",
      "updatedBy": "123e4567-e89b-12d3-a456-426614174000",
      "name": "string",
      "isExternal": true,
      "emoji": "string",
      "color": "purple",
      "order": 1,
      "workspaceAccessLevel": "string",
      "contributors": [
        {
          "id": "123e4567-e89b-12d3-a456-426614174000",
          "userId": "123e4567-e89b-12d3-a456-426614174000",
          "accessLevel": "string",
          "firstName": "Lisa",
          "lastName": "Smith",
          "hasImage": true,
          "isDeactivated": false
        }
      ],
      "teams": [
        {
          "id": "123e4567-e89b-12d3-a456-426614174000",
          "teamId": "123e4567-e89b-12d3-a456-426614174000",
          "accessLevel": "string",
          "name": "Designers",
          "icon": "paintbrush",
          "color": "purple"
        }
      ]
    },
    "parentId": "123e4567-e89b-12d3-a456-426614174000",
    "projectId": "123e4567-e89b-12d3-a456-426614174000",
    "project": {
      "id": "123e4567-e89b-12d3-a456-426614174000",
      "name": "string",
      "createdBy": "123e4567-e89b-12d3-a456-426614174000",
      "teams": [
        {
          "id": "123e4567-e89b-12d3-a456-426614174000",
          "name": "string"
        }
      ],
      "members": [
        {
          "id": "123e4567-e89b-12d3-a456-426614174000",
          "projectRoleId": "123e4567-e89b-12d3-a456-426614174000",
          "userId": "123e4567-e89b-12d3-a456-426614174000"
        }
      ],
      "isPrivate": true,
      "isExternal": true
    },
    "taskId": "123e4567-e89b-12d3-a456-426614174000",
    "emoji": "string",
    "isPrivate": true,
    "order": 1,
    "isExternal": true,
    "isHiddenForConnectUsers": true,
    "contributors": [
      {
        "id": "123e4567-e89b-12d3-a456-426614174000",
        "userId": "123e4567-e89b-12d3-a456-426614174000",
        "accessLevel": "string",
        "firstName": "Lisa",
        "lastName": "Smith",
        "hasImage": true,
        "isDeactivated": false,
        "documentId": "123e4567-e89b-12d3-a456-426614174000",
        "inheritedFromDocumentContributorId": "123e4567-e89b-12d3-a456-426614174000",
        "inheritedDocumentContributor": {
          "documentId": "123e4567-e89b-12d3-a456-426614174000",
          "accessLevel": "string"
        }
      }
    ],
    "teams": [
      {
        "id": "123e4567-e89b-12d3-a456-426614174000",
        "teamId": "123e4567-e89b-12d3-a456-426614174000",
        "accessLevel": "string",
        "name": "Designers",
        "icon": "paintbrush",
        "color": "purple",
        "documentId": "123e4567-e89b-12d3-a456-426614174000",
        "inheritedFromDocumentToTeamId": "123e4567-e89b-12d3-a456-426614174000",
        "inheritedDocumentToTeam": {
          "documentId": "123e4567-e89b-12d3-a456-426614174000",
          "accessLevel": "string"
        }
      }
    ],
    "workspaceAccessLevel": "string",
    "inheritedWorkspaceAccessFromDocumentId": "123e4567-e89b-12d3-a456-426614174000",
    "inheritedWorkspaceAccessFromDocument": {
      "workspaceAccessLevel": "string"
    },
    "movedToTrashOn": "2026-01-15T09:30:00Z",
    "movedToTrashBy": "123e4567-e89b-12d3-a456-426614174000",
    "rootDocumentCreatedBy": "123e4567-e89b-12d3-a456-426614174000"
  }
]
```
