VirtuousAI
Reference

Notifications

List Notifications

GET
/api/v1/notifications

Query Parameters

limit?integer
Default25
Range1 <= value <= 100
cursor?|
unread?|
kinds?array<>|
includeCleared?boolean
Defaultfalse

Header Parameters

authorization?|
X-API-Key?|
vai_token?|

Response Body

application/json

application/json

curl -X GET "https://loading/api/v1/notifications"
{
  "items": [
    {
      "body": "string",
      "clearedAt": "2019-08-24T14:15:22Z",
      "createdAt": "2019-08-24T14:15:22Z",
      "id": "string",
      "kind": "string",
      "link": "string",
      "readAt": "2019-08-24T14:15:22Z",
      "title": "string"
    }
  ],
  "nextCursor": "string"
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Mark All Notifications Read

POST
/api/v1/notifications/read-all

Header Parameters

authorization?|
X-API-Key?|
vai_token?|

Response Body

application/json

application/json

curl -X POST "https://loading/api/v1/notifications/read-all"
{
  "marked": 0
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Get Unread Count

GET
/api/v1/notifications/unread-count

Header Parameters

authorization?|
X-API-Key?|
vai_token?|

Response Body

application/json

application/json

curl -X GET "https://loading/api/v1/notifications/unread-count"
{
  "count": 0
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Clear Notification

POST
/api/v1/notifications/{notification_id}/clear

Path Parameters

notification_id*string
Formatuuid

Header Parameters

authorization?|
X-API-Key?|
vai_token?|

Response Body

application/json

application/json

curl -X POST "https://loading/api/v1/notifications/497f6eca-6276-4993-bfeb-53cbbbba6f08/clear"
{
  "cleared": 0
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}

Mark Notification Read

POST
/api/v1/notifications/{notification_id}/read

Path Parameters

notification_id*string
Formatuuid

Header Parameters

authorization?|
X-API-Key?|
vai_token?|

Response Body

application/json

application/json

curl -X POST "https://loading/api/v1/notifications/497f6eca-6276-4993-bfeb-53cbbbba6f08/read"
{
  "marked": 0
}
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}