openapi: 3.2.0 info: version: '3' title: ServiceChannel API - v.3 Email Notifications API description: The ServiceChannel API is a RESTful and stateless API. servers: - url: https://sb2api.servicechannel.com/v3 security: - oauth2: [] tags: - name: Email Notifications paths: /users/current/locations/{locationId}/subscribe: post: tags: - Email Notifications summary: Subscribe to Email Notifications description: 'Subscribe to Email Notification. Available for subscriber usage.' operationId: POSTv3_users_current_locations_{locationId}_subscribe parameters: - name: locationId in: path description: Numeric Id of the Location to perform action with. required: true schema: type: integer format: int32 responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/System.Object' text/json: schema: $ref: '#/components/schemas/System.Object' deprecated: false x-access: Subscribers requestBody: content: application/json: schema: $ref: '#/components/schemas/ServiceChannel.Services.Messaging.Notifications.EmailNotificationSubscriptionRequest' text/json: schema: $ref: '#/components/schemas/ServiceChannel.Services.Messaging.Notifications.EmailNotificationSubscriptionRequest' description: The Subscription Email Notification request. required: true /users/current/locations/{locationId}/email: get: tags: - Email Notifications summary: List existing email subscriptions description: Returns a list of email subscriptions operationId: GETv3_users_current_locations_{locationId}_email parameters: - name: locationId in: path required: true schema: type: integer format: int32 responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/System.Object' text/json: schema: $ref: '#/components/schemas/System.Object' deprecated: false x-access: Subscribers /users/current/unsubscribe: delete: tags: - Email Notifications summary: Unsubscribe from Email Notifications description: 'Unsubscribe from Email Notifications. Available for subscriber usage.' operationId: DELETEv3_users_current_unsubscribe responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/System.Object' text/json: schema: $ref: '#/components/schemas/System.Object' deprecated: false x-access: Subscribers /users/current/locations/{locationId}/unsubscribe: delete: tags: - Email Notifications summary: Unsubscribe from Email Notifications description: 'Unsubscribe from Email Notifications. Available for subscriber usage.' operationId: DELETEv3_users_current_locations_{locationId}_unsubscribe?id={id} parameters: - name: locationId in: path description: Numeric Id of the Location to perform action with. required: true schema: type: integer format: int32 - name: id in: query description: Numeric Id of the Subscription to perform action with. required: false schema: type: integer format: int32 - name: notificationType in: query description: 'Notification type: Check In , ....' required: true schema: type: string enum: - CheckIn - CheckOut - BadgeScanRequired - name: languageCode in: query description: ISO 639-1 two-letter code for the language. required: false schema: type: string - name: notificationRules.rules in: query required: false schema: type: array items: {} responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/System.Object' text/json: schema: $ref: '#/components/schemas/System.Object' deprecated: false x-access: Subscribers components: schemas: ServiceChannel.Services.Messaging.Notifications.EmailNotificationSubscriptionRequest: description: Subscribe Email Notification Request model required: - NotificationType type: object properties: NotificationType: description: 'Notification type: Check In , ....' enum: - CheckIn - CheckOut - BadgeScanRequired type: string LanguageCode: description: ISO 639-1 two-letter code for the language. type: string NotificationRules: $ref: '#/components/schemas/ServiceChannel.Services.Messaging.Notifications.NotificationRulesRequest' description: Filter for Notification Request ServiceChannel.Services.Messaging.Notifications.NotificationRulesRequest: description: Rules for Notification Request model type: object properties: Rules: type: array items: $ref: '#/components/schemas/ServiceChannel.Services.Messaging.Notifications.Rule' System.Object: type: object properties: {} ServiceChannel.Services.Messaging.Notifications.Rule: type: object properties: Field: type: string Value: type: string securitySchemes: oauth2: type: oauth2 flows: authorizationCode: scopes: {} authorizationUrl: https://sb2login.servicechannel.com/oauth/authorize tokenUrl: https://sb2login.servicechannel.com/oauth/token description: OAuth2 Authorization