> ## Documentation Index
> Fetch the complete documentation index at: https://api-documentation.kare-app.fr/llms.txt
> Use this file to discover all available pages before exploring further.

# Ws



## AsyncAPI

````yaml api/rs/asyncapi.json ws
id: ws
title: Ws
description: ''
servers:
  - id: local
    protocol: ws
    host: localhost:3000
    bindings: []
    variables: []
address: /rs/ws
parameters: []
bindings: []
operations:
  - &ref_2
    id: sendToClient
    title: Send to client
    type: send
    messages:
      - &ref_3
        id: notification
        payload:
          - name: notification
            type: object
            properties:
              - name: v
                type: number
                description: 1
                required: true
              - name: id
                type: string
                required: true
              - name: ts
                type: string
                required: true
              - name: type
                type: string
                description: notification
                required: true
              - name: data
                type: object
                required: true
                properties:
                  - name: id
                    type: string
                    required: true
                  - name: type
                    type: string
                    enumValues:
                      - deadline_reminder
                      - deadline_overdue
                      - commission_reminder
                      - inbox_report_received
                      - conversation_message_received
                      - intervention_started
                      - intervention_signed
                      - intervention_planned
                      - intervention_overdue
                      - user_action
                    required: true
                  - name: severity
                    type: string
                    enumValues:
                      - alert
                      - reminder
                      - info
                    required: true
                  - name: expectation
                    type: string
                    enumValues:
                      - required
                      - suggested
                      - none
                    required: true
                  - name: action
                    type: string
                    required: true
                  - name: title
                    type: string
                    required: true
                  - name: body
                    type: string
                    required: true
                  - name: payload
                    type: object
                    required: true
                  - name: channels
                    type: array
                    required: true
                    properties:
                      - name: item
                        type: string
                        enumValues:
                          - in_app
                          - email
                          - sms
                        required: false
                  - name: subjectType
                    type: string
                    required: true
                  - name: subjectId
                    type: string
                    required: true
                  - name: subjectLabel
                    type: string
                    required: true
                  - name: readAt
                    type: string
                    required: true
                  - name: pinnedAt
                    type: string
                    required: true
                  - name: createdAt
                    type: string
                    required: true
                  - name: updatedAt
                    type: string
                    required: true
        headers: []
        jsonPayloadSchema:
          type: object
          properties:
            v:
              type: number
              const: 1
              x-parser-schema-id: <anonymous-schema-2>
            id:
              type: string
              x-parser-schema-id: <anonymous-schema-3>
            ts:
              type: string
              x-parser-schema-id: <anonymous-schema-4>
            type:
              type: string
              const: notification
              x-parser-schema-id: <anonymous-schema-5>
            data:
              type: object
              properties:
                id:
                  type: string
                  format: uuid
                  pattern: >-
                    ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                  x-parser-schema-id: <anonymous-schema-7>
                type:
                  type: string
                  enum:
                    - deadline_reminder
                    - deadline_overdue
                    - commission_reminder
                    - inbox_report_received
                    - conversation_message_received
                    - intervention_started
                    - intervention_signed
                    - intervention_planned
                    - intervention_overdue
                    - user_action
                  x-parser-schema-id: <anonymous-schema-8>
                severity:
                  type: string
                  enum:
                    - alert
                    - reminder
                    - info
                  x-parser-schema-id: <anonymous-schema-9>
                expectation:
                  type: string
                  enum:
                    - required
                    - suggested
                    - none
                  x-parser-schema-id: <anonymous-schema-10>
                action:
                  anyOf:
                    - type: string
                      enum:
                        - plan
                        - reschedule
                        - verify
                        - process
                        - prepare
                      x-parser-schema-id: <anonymous-schema-12>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-13>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-11>
                title:
                  type: string
                  minLength: 1
                  maxLength: 200
                  x-parser-schema-id: <anonymous-schema-14>
                body:
                  anyOf:
                    - type: string
                      maxLength: 2000
                      x-parser-schema-id: <anonymous-schema-16>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-17>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-15>
                payload:
                  anyOf:
                    - type: object
                      propertyNames:
                        type: string
                        x-parser-schema-id: <anonymous-schema-20>
                      properties: {}
                      x-parser-schema-id: <anonymous-schema-19>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-21>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-18>
                channels:
                  type: array
                  items:
                    type: string
                    enum:
                      - in_app
                      - email
                      - sms
                    x-parser-schema-id: <anonymous-schema-23>
                  x-parser-schema-id: <anonymous-schema-22>
                subjectType:
                  anyOf:
                    - type: string
                      enum:
                        - Anomaly
                        - AnomalyIntervention
                        - BoUser
                        - Building
                        - BuildingWork
                        - Comment
                        - Commission
                        - Compliance
                        - Contact
                        - Contract
                        - ContractDocument
                        - Conversation
                        - Diploma
                        - Document
                        - EmailSenderRule
                        - Equipment
                        - EquipmentSpecification
                        - Folder
                        - FormSubmission
                        - FormTemplate
                        - Identity
                        - InboxItem
                        - InboxMail
                        - Intervention
                        - InterventionLink
                        - Label
                        - LibraryAnomaly
                        - LibraryEquipmentSpecification
                        - LibraryLabel
                        - LibraryRole
                        - LibraryRule
                        - LibraryTechnicalInstallation
                        - DocumentExport
                        - Logbook
                        - Notification
                        - NotificationPreference
                        - Organization
                        - Plan
                        - PlanItem
                        - Project
                        - ProjectFolder
                        - Provider
                        - ProviderAccess
                        - PrUser
                        - QrCode
                        - QrCodeGeneration
                        - Report
                        - ReportAnalysis
                        - Responsibility
                        - Role
                        - Routine
                        - Rule
                        - SelectionPerimeter
                        - TagType
                        - TechnicalInstallation
                        - Unit
                        - User
                      x-parser-schema-id: <anonymous-schema-25>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-26>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-24>
                subjectId:
                  anyOf:
                    - type: string
                      format: uuid
                      pattern: >-
                        ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                      x-parser-schema-id: <anonymous-schema-28>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-29>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-27>
                subjectLabel:
                  anyOf:
                    - type: string
                      minLength: 1
                      maxLength: 200
                      x-parser-schema-id: <anonymous-schema-31>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-32>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-30>
                readAt:
                  anyOf:
                    - type: string
                      format: date-time
                      x-parser-schema-id: <anonymous-schema-34>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-35>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-33>
                pinnedAt:
                  anyOf:
                    - type: string
                      format: date-time
                      x-parser-schema-id: <anonymous-schema-37>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-38>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-36>
                createdAt:
                  type: string
                  format: date-time
                  x-parser-schema-id: <anonymous-schema-39>
                updatedAt:
                  type: string
                  format: date-time
                  x-parser-schema-id: <anonymous-schema-40>
              required:
                - id
                - type
                - severity
                - expectation
                - action
                - title
                - body
                - payload
                - channels
                - subjectType
                - subjectId
                - subjectLabel
                - readAt
                - pinnedAt
                - createdAt
                - updatedAt
              x-parser-schema-id: <anonymous-schema-6>
          required:
            - v
            - id
            - ts
            - type
            - data
          x-parser-schema-id: <anonymous-schema-1>
        title: Notification
        example: No examples found
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: notification
      - &ref_4
        id: system
        payload:
          - name: system
            type: object
            properties:
              - name: v
                type: number
                description: 1
                required: true
              - name: id
                type: string
                required: true
              - name: ts
                type: string
                required: true
              - name: type
                type: string
                description: system
                required: true
              - name: data
                type: object
                required: true
                properties:
                  - name: event
                    type: string
                    description: pong
                    required: true
                  - name: event
                    type: string
                    description: error
                    required: true
                  - name: code
                    type: string
                    required: true
                  - name: message
                    type: string
                    required: true
                  - name: event
                    type: string
                    description: reconnect
                    required: true
                  - name: reason
                    type: string
                    description: capabilities
                    required: true
        headers: []
        jsonPayloadSchema:
          type: object
          properties:
            v:
              type: number
              const: 1
              x-parser-schema-id: <anonymous-schema-42>
            id:
              type: string
              x-parser-schema-id: <anonymous-schema-43>
            ts:
              type: string
              x-parser-schema-id: <anonymous-schema-44>
            type:
              type: string
              const: system
              x-parser-schema-id: <anonymous-schema-45>
            data:
              oneOf:
                - type: object
                  properties:
                    event:
                      type: string
                      const: pong
                      x-parser-schema-id: <anonymous-schema-48>
                  required:
                    - event
                  x-parser-schema-id: <anonymous-schema-47>
                - type: object
                  properties:
                    event:
                      type: string
                      const: error
                      x-parser-schema-id: <anonymous-schema-50>
                    code:
                      type: string
                      x-parser-schema-id: <anonymous-schema-51>
                    message:
                      type: string
                      x-parser-schema-id: <anonymous-schema-52>
                  required:
                    - event
                    - code
                    - message
                  x-parser-schema-id: <anonymous-schema-49>
                - type: object
                  properties:
                    event:
                      type: string
                      const: reconnect
                      x-parser-schema-id: <anonymous-schema-54>
                    reason:
                      type: string
                      const: capabilities
                      x-parser-schema-id: <anonymous-schema-55>
                  required:
                    - event
                    - reason
                  x-parser-schema-id: <anonymous-schema-53>
              properties: {}
              x-parser-schema-id: <anonymous-schema-46>
          required:
            - v
            - id
            - ts
            - type
            - data
          x-parser-schema-id: <anonymous-schema-41>
        title: System
        example: |-
          {
            "v": 123,
            "id": "<string>",
            "ts": "<string>",
            "type": "<string>",
            "data": {
              "event": "<string>",
              "code": "<string>",
              "message": "<string>",
              "reason": "<string>"
            }
          }
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: system
      - &ref_5
        id: job
        payload:
          - name: job
            type: object
            properties:
              - name: v
                type: number
                description: 1
                required: true
              - name: id
                type: string
                required: true
              - name: ts
                type: string
                required: true
              - name: type
                type: string
                description: job
                required: true
              - name: data
                type: object
                required: true
                properties:
                  - name: jobId
                    type: string
                    required: true
                  - name: kind
                    type: string
                    required: true
                  - name: status
                    type: string
                    enumValues:
                      - queued
                      - running
                      - succeeded
                      - failed
                      - cancelled
                    required: true
                  - name: progress
                    type: number
                    required: false
                  - name: startedAt
                    type: string
                    required: false
                  - name: error
                    type: string
                    required: false
        headers: []
        jsonPayloadSchema:
          type: object
          properties:
            v:
              type: number
              const: 1
              x-parser-schema-id: <anonymous-schema-57>
            id:
              type: string
              x-parser-schema-id: <anonymous-schema-58>
            ts:
              type: string
              x-parser-schema-id: <anonymous-schema-59>
            type:
              type: string
              const: job
              x-parser-schema-id: <anonymous-schema-60>
            data:
              type: object
              properties:
                jobId:
                  type: string
                  x-parser-schema-id: <anonymous-schema-62>
                kind:
                  type: string
                  x-parser-schema-id: <anonymous-schema-63>
                status:
                  type: string
                  enum:
                    - queued
                    - running
                    - succeeded
                    - failed
                    - cancelled
                  x-parser-schema-id: <anonymous-schema-64>
                progress:
                  type: number
                  minimum: 0
                  maximum: 100
                  x-parser-schema-id: <anonymous-schema-65>
                startedAt:
                  type: string
                  x-parser-schema-id: <anonymous-schema-66>
                error:
                  type: string
                  x-parser-schema-id: <anonymous-schema-67>
              required:
                - jobId
                - kind
                - status
              x-parser-schema-id: <anonymous-schema-61>
          required:
            - v
            - id
            - ts
            - type
            - data
          x-parser-schema-id: <anonymous-schema-56>
        title: Job
        example: |-
          {
            "v": 123,
            "id": "<string>",
            "ts": "<string>",
            "type": "<string>",
            "data": {
              "jobId": "<string>",
              "kind": "<string>",
              "status": "<string>",
              "progress": 123,
              "startedAt": "<string>",
              "error": "<string>"
            }
          }
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: job
      - &ref_6
        id: entity
        payload:
          - name: entity
            type: object
            properties:
              - name: v
                type: number
                description: 1
                required: true
              - name: id
                type: string
                required: true
              - name: ts
                type: string
                required: true
              - name: type
                type: string
                description: entity
                required: true
              - name: data
                type: object
                required: true
                properties:
                  - name: entity
                    type: string
                    enumValues:
                      - Anomaly
                      - AnomalyIntervention
                      - BoUser
                      - Building
                      - BuildingWork
                      - Comment
                      - Commission
                      - Compliance
                      - Contact
                      - Contract
                      - ContractDocument
                      - Conversation
                      - Diploma
                      - Document
                      - EmailSenderRule
                      - Equipment
                      - EquipmentSpecification
                      - Folder
                      - FormSubmission
                      - FormTemplate
                      - Identity
                      - InboxItem
                      - InboxMail
                      - Intervention
                      - InterventionLink
                      - Label
                      - LibraryAnomaly
                      - LibraryEquipmentSpecification
                      - LibraryLabel
                      - LibraryRole
                      - LibraryRule
                      - LibraryTechnicalInstallation
                      - DocumentExport
                      - Logbook
                      - Notification
                      - NotificationPreference
                      - Organization
                      - Plan
                      - PlanItem
                      - Project
                      - ProjectFolder
                      - Provider
                      - ProviderAccess
                      - PrUser
                      - QrCode
                      - QrCodeGeneration
                      - Report
                      - ReportAnalysis
                      - Responsibility
                      - Role
                      - Routine
                      - Rule
                      - SelectionPerimeter
                      - TagType
                      - TechnicalInstallation
                      - Unit
                      - User
                    required: true
                  - name: action
                    type: string
                    required: true
                  - name: id
                    type: string
                    required: true
                  - name: orgId
                    type: string
                    required: true
        headers: []
        jsonPayloadSchema:
          type: object
          properties:
            v:
              type: number
              const: 1
              x-parser-schema-id: <anonymous-schema-69>
            id:
              type: string
              x-parser-schema-id: <anonymous-schema-70>
            ts:
              type: string
              x-parser-schema-id: <anonymous-schema-71>
            type:
              type: string
              const: entity
              x-parser-schema-id: <anonymous-schema-72>
            data:
              type: object
              properties:
                entity:
                  type: string
                  enum:
                    - Anomaly
                    - AnomalyIntervention
                    - BoUser
                    - Building
                    - BuildingWork
                    - Comment
                    - Commission
                    - Compliance
                    - Contact
                    - Contract
                    - ContractDocument
                    - Conversation
                    - Diploma
                    - Document
                    - EmailSenderRule
                    - Equipment
                    - EquipmentSpecification
                    - Folder
                    - FormSubmission
                    - FormTemplate
                    - Identity
                    - InboxItem
                    - InboxMail
                    - Intervention
                    - InterventionLink
                    - Label
                    - LibraryAnomaly
                    - LibraryEquipmentSpecification
                    - LibraryLabel
                    - LibraryRole
                    - LibraryRule
                    - LibraryTechnicalInstallation
                    - DocumentExport
                    - Logbook
                    - Notification
                    - NotificationPreference
                    - Organization
                    - Plan
                    - PlanItem
                    - Project
                    - ProjectFolder
                    - Provider
                    - ProviderAccess
                    - PrUser
                    - QrCode
                    - QrCodeGeneration
                    - Report
                    - ReportAnalysis
                    - Responsibility
                    - Role
                    - Routine
                    - Rule
                    - SelectionPerimeter
                    - TagType
                    - TechnicalInstallation
                    - Unit
                    - User
                  x-parser-schema-id: <anonymous-schema-74>
                action:
                  type: string
                  x-parser-schema-id: <anonymous-schema-75>
                id:
                  anyOf:
                    - type: string
                      x-parser-schema-id: <anonymous-schema-77>
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-78>
                  properties: {}
                  x-parser-schema-id: <anonymous-schema-76>
                orgId:
                  type: string
                  x-parser-schema-id: <anonymous-schema-79>
              required:
                - entity
                - action
                - id
                - orgId
              x-parser-schema-id: <anonymous-schema-73>
          required:
            - v
            - id
            - ts
            - type
            - data
          x-parser-schema-id: <anonymous-schema-68>
        title: Entity
        example: |-
          {
            "v": 123,
            "id": "<string>",
            "ts": "<string>",
            "type": "<string>",
            "data": {
              "entity": "<string>",
              "action": "<string>",
              "id": "<string>",
              "orgId": "<string>"
            }
          }
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: entity
    bindings: []
    extensions: &ref_0
      - id: x-parser-unique-object-id
        value: ws
  - &ref_1
    id: receiveFromClient
    title: Receive from client
    type: receive
    messages: []
    bindings: []
    extensions: *ref_0
sendOperations:
  - *ref_1
receiveOperations:
  - *ref_2
sendMessages: []
receiveMessages:
  - *ref_3
  - *ref_4
  - *ref_5
  - *ref_6
extensions:
  - id: x-parser-unique-object-id
    value: ws
securitySchemes: []

````