List of all Sessions

To show the client a list of all their sessions with a "GET" request

Clients can view a list of their active, future, and completed sessions.

1- Request URL:

https://gwidev.eq.optt.ca/gateway/profile/client/session?time-state=RUNNING

2- Request Method Type:
GET

3- query

parameter nameParameter TypeDescription
time-statestringRUNNING: Active sessions
FUTURE : Sessions that have not yet been activated
COMPLETED: Sessions closed by the Care provider

* One of these values must be used

A complete example of an API call:

curl -X GET "https://gwidev.eq.optt.ca/gateway/profile/client/session?time-state=RUNNING" -H "accept: */*" -H "Authorization: bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjM3NTgyMDY0ODksInVzZXJfbmFtZSI6ImxhbGVoQGNpdHJvbml0eS5jb20iLCJhdXRob3JpdGllcyI6WyJDTElFTlQiXSwianRpIjoiNGNhZTIyMDQtMWNkNi00NTJmLWFmOGItYjc0NWZkMjdmMGYxIiwiY2xpZW50X2lkIjoib3B0dC0wMmVlNzdkYy1hYzQ1LTQzNDQtODE3ZS0xN2NhNTJiNThiNWQiLCJzY29wZSI6WyJyZWFkIiwid3JpdGUiXX0.PON3BpI5KnDGxNHV3G-SfMiWDTcb2SQJJ5m5Mr9fKep_AMLSeJIeZzpnH6QSI2p_jgsaPZk9KYid7KJnfnjgLDYlQYQxj2fhvdyOkl6UY4OVwe1Vgr-3Zh6hibwDrrCcGUWQ_T3nTUTMyIpYGCAFck-Fz8EIxPj5MjOK2ImkFaqpIdfSFNRDV90IhdrR0qs0YptX9Hs6chP8EvQb_eJ4P-Hv5ZBT0WNvuzrcgflPqBjcge-eW0YO016ZqO15p-GPpHuqr-dSRFjciPG8RQhMytXZUAeHNXB9KtuFKMS9CDeD8bfHkl4bGjcdOdoTPWkfZ5Lj0RD393l-EmrrJ7ZZFA" -H "offset: 1"

Response:

{
  "content": [
    {
      "id": 809,
      "title": "covid test",
      "description": "covid test",
      "caregiverId": 2,
      "caregiverName": "caregiver1",
      "caregiverPosition": "Psychologist",
      "clientId": 1,
      "clientOpptId": "clinic 12ea9ab52-498a-4600-9d15-eea49f0b4eb8",
      "clientName": "client 1",
      "createDate": "2021/01/24 10:14",
      "startDate": "2021/01/24 10:14",
      "chatId": "600d48c174e8540001b6c390",
      "assignmentId": 1834,
      "assignmentName": "Evidence",
      "bookId": 5,
      "assignmentCount": 4,
      "completedAssignmentCount": 0,
      "pendingAssignmentCount": 4,
      "lastAssignmentScore": 0,
      "isClosed": false,
      "runningStatus": "RUNNING",
      "documents": [],
      "assignments": [],
      "feedbacks": []
    },
    {
      "id": 807,
      "title": "2",
      "description": "2020-12-08",
      "caregiverId": 2,
      "caregiverName": "caregiver1",
      "caregiverPosition": "Psychologist",
      "clientId": 1,
      "clientOpptId": "clinic 12ea9ab52-498a-4600-9d15-eea49f0b4eb8",
      "clientName": "client 1",
      "createDate": "2021/01/19 16:44",
      "startDate": "2021/01/19 16:43",
      "chatId": "60070c9b74e8540001b6c317",
      "assignmentId": 1828,
      "assignmentName": "Thought Record and Automatic thoughts",
      "bookId": 25,
      "assignmentCount": 10,
      "completedAssignmentCount": 6,
      "pendingAssignmentCount": 4,
      "lastAssignmentScore": null,
      "isClosed": false,
      "runningStatus": "RUNNING",
      "documents": [],
      "assignments": [],
      "feedbacks": []
    },
    {
      "id": 806,
      "title": "test",
      "description": "2",
      "caregiverId": 2,
      "caregiverName": "caregiver1",
      "caregiverPosition": "Psychologist",
      "clientId": 1,
      "clientOpptId": "clinic 12ea9ab52-498a-4600-9d15-eea49f0b4eb8",
      "clientName": "client 1",
      "createDate": "2021/01/19 12:53",
      "startDate": "2021/01/19 12:52",
      "chatId": "6006d66b74e8540001b6c307",
      "assignmentId": 1818,
      "assignmentName": "Thinking Errors",
      "bookId": 24,
      "assignmentCount": 7,
      "completedAssignmentCount": 0,
      "pendingAssignmentCount": 7,
      "lastAssignmentScore": 0,
      "isClosed": false,
      "runningStatus": "RUNNING",
      "documents": [],
      "assignments": [],
      "feedbacks": []
    },
    {
      "id": 805,
      "title": "covid",
      "description": "1",
      "caregiverId": 2,
      "caregiverName": "caregiver1",
      "caregiverPosition": "Psychologist",
      "clientId": 1,
      "clientOpptId": "clinic 12ea9ab52-498a-4600-9d15-eea49f0b4eb8",
      "clientName": "client 1",
      "createDate": "2021/01/19 11:28",
      "startDate": "2021/01/19 11:29",
      "chatId": "6006c27c74e8540001b6c2f9",
      "assignmentId": 1811,
      "assignmentName": "Anxiety and depression during COVID-19 pandemic",
      "bookId": 14,
      "assignmentCount": 4,
      "completedAssignmentCount": 0,
      "pendingAssignmentCount": 4,
      "lastAssignmentScore": 0,
      "isClosed": false,
      "runningStatus": "RUNNING",
      "documents": [],
      "assignments": [],
      "feedbacks": []
    },
    {
      "id": 792,
      "title": "0",
      "description": "09373932641",
      "caregiverId": 2,
      "caregiverName": "caregiver1",
      "caregiverPosition": "Psychologist",
      "clientId": 1,
      "clientOpptId": "clinic 12ea9ab52-498a-4600-9d15-eea49f0b4eb8",
      "clientName": "client 1",
      "createDate": "2021/01/15 14:12",
      "startDate": "2021/01/15 14:11",
      "chatId": "6001a31e74e8540001b6c1e2",
      "assignmentId": 1753,
      "assignmentName": "Alternative and balanced thinking",
      "bookId": 7,
      "assignmentCount": 3,
      "completedAssignmentCount": 0,
      "pendingAssignmentCount": 3,
      "lastAssignmentScore": 0,
      "isClosed": false,
      "runningStatus": "RUNNING",
      "documents": [],
      "assignments": [],
      "feedbacks": []
    }
  ],
  "last": false,
  "totalElements": 105,
  "totalPages": 6,
  "sort": null,
  "first": true,
  "numberOfElements": 20,
  "size": 20,
  "number": 0
}