# health.hats.listAsks

> Asks the caller made, as a patient, and was asked, as a clinician, newest first. Service auth, so each caller sees only their own.

- Kind: query
- Authority: hats.health
- Lexicon: 1
- Published by [hats.health](https://lexicon.garden/identity/did:plc:uvvhtareovj2oaregs7vsibv), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:uvvhtareovj2oaregs7vsibv/health.hats.listAsks)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:uvvhtareovj2oaregs7vsibv/health.hats.listAsks/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:uvvhtareovj2oaregs7vsibv/health.hats.listAsks/analytics)

## Query (`health.hats.listAsks`)

Type: query · GET

### Output (application/json)

- `asks` (array, required)
  - `items` (ref)
    - Reference: `#ask`

## #ask (`health.hats.listAsks#ask`)

Type: object

### Properties

- `answer` (string): The clinician's note, such as a declined amendment's reason.
- `answeredAt` (string · datetime)
- `clinician` (string · did, required)
- `createdAt` (string · datetime, required)
- `dueAt` (string · datetime, required)
- `id` (string, required)
- `kind` (string, required)
  - Constraints: knownValues: correct | verify
- `patient` (string · did, required)
- `status` (string, required)
  - Constraints: knownValues: open | done | declined
- `target` (string · at-uri, required)
- `task` (string · at-uri, required)

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "ask": {
      "properties": {
        "answer": {
          "description": "The clinician's note, such as a declined amendment's reason.",
          "type": "string"
        },
        "answeredAt": {
          "format": "datetime",
          "type": "string"
        },
        "clinician": {
          "format": "did",
          "type": "string"
        },
        "createdAt": {
          "format": "datetime",
          "type": "string"
        },
        "dueAt": {
          "format": "datetime",
          "type": "string"
        },
        "id": {
          "type": "string"
        },
        "kind": {
          "knownValues": [
            "correct",
            "verify"
          ],
          "type": "string"
        },
        "patient": {
          "format": "did",
          "type": "string"
        },
        "status": {
          "knownValues": [
            "open",
            "done",
            "declined"
          ],
          "type": "string"
        },
        "target": {
          "format": "at-uri",
          "type": "string"
        },
        "task": {
          "format": "at-uri",
          "type": "string"
        }
      },
      "required": [
        "id",
        "patient",
        "clinician",
        "kind",
        "target",
        "task",
        "createdAt",
        "dueAt",
        "status"
      ],
      "type": "object"
    },
    "main": {
      "description": "Asks the caller made, as a patient, and was asked, as a clinician, newest first. Service auth, so each caller sees only their own.",
      "output": {
        "encoding": "application/json",
        "schema": {
          "properties": {
            "asks": {
              "items": {
                "ref": "#ask",
                "type": "ref"
              },
              "type": "array"
            }
          },
          "required": [
            "asks"
          ],
          "type": "object"
        }
      },
      "type": "query"
    }
  },
  "id": "health.hats.listAsks",
  "lexicon": 1
}
```
