stranded-in-python / movix-notification-worker

Movix notification service
0 stars 0 forks source link

API сервиса нотификаций #3

Closed SBKubric closed 1 year ago

SBKubric commented 1 year ago
SBKubric commented 1 year ago

Контакты пользователя получаются через вот этот endpoint:

openapi: 3.0.0
info:
  version: 1.0.0
  title: User Notification API
  description: API to manage user notifications
servers:
  - url: https://api.example.com/v1
paths:
  /users/notifications:
    get:
      summary: Get user notification channels
      description: Returns a list of user's notification channels
      responses:
        '200':
          description: Successful operation
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/UserChannels'
components:
  schemas:
    UserChannels:
      type: object
      properties:
        id:
          type: string
          description: ID of the user
        channels:
          type: array
          description: Notification channels
          items: $ref: '#/components/schemas/NotificationChannel'
    NotificationChannel:
      type: object
      properties:
        type:
          type: string
          description: Type of the notification channel (e.g., email, sms)
        value:
          type: string
          description: Value of the notification channel (e.g., email address or phone number)
SBKubric commented 1 year ago

Модели БД описаны в https://github.com/stranded-in-python/movix-admin/tree/feat/notifications