# Search Submissions

## Retrieve a checklist submissions

<mark style="color:green;">`POST`</mark> `https://api.xenia.team/v1/submissions/search`

Retrieve a submissions based on query filters

#### Path Parameters

| Name                                 | Type   | Description   |
| ------------------------------------ | ------ | ------------- |
| id<mark style="color:red;">\*</mark> | String | Submission id |

#### Headers

| Name                                            | Type   | Description |
| ----------------------------------------------- | ------ | ----------- |
| Authorization<mark style="color:red;">\*</mark> | String |             |

#### Request Body

| Name      | Type      | Description          |
| --------- | --------- | -------------------- |
| locations | string\[] | Array of location id |
| user      | string\[] | Array of user id     |
| team      | string\[] | Array of team id     |

{% tabs %}
{% tab title="200 Success" %}
```json
{
submissions: [{
    "id": "e77b6442-de60-401c-a173-0afc84a5747e",
    "name": "Kitchen Opening Checklist",
    "attachments": {
    "files": []
    }, 
    "progress": {
        completed: 12,
    
    },
    "status": "In Progress",
    "workspaceId": "e77b6442-de60-401c-a173-0afc84a5744h",
    "reportUrl": "https://cdn.xenia.team/submissions/reports/e77b6442.pdf",
    "publicUrl": "https://cdn.xenia.team/submissions/public/e77b6442",
    "createdBy": "e77b6442-de60-401c-a173-0afc84a5747f",
    "updatedBy": "e77b6442-de60-401c-a173-0afc84a5747f",
    "items" [{
        "id": "e77b6442-de60-401c-a173-0afc84a5747f",
        "type": "text",
        "answer": { value: "user anser" },
    }]
}],
    "createdAt": 1701743645
    "updatedAt": 2001743645
}]
}
```
{% endtab %}

{% tab title="401 Permission denied" %}

{% endtab %}

{% tab title="500: Internal Server Error Something went wrong" %}

{% endtab %}

{% tab title="404: Not Found Submission not found" %}

{% endtab %}

{% tab title="400: Bad Request Validation failed" %}

{% endtab %}
{% endtabs %}
