CreateProjectNotification Method

Description

Creates a new project notification.

HTTP Request

POST https://api.skeddly.com/api/Projects/<id>/Notifications

Body

The body is a JSON structure with the following properties.

amazonSnsSettings

Email settings for the notification. Required when notificationMethod is amazon-sns.

Type: ProjectNotificationAmazonSnsSettings object

Required: Conditional

emailSettings

Email settings for the notification. Required when notificationMethod is email.

Type: ProjectNotificationEmailSettings object

Required: Conditional

notificationLevel

Level of notification.

Type: string

Allowed Values:

  • all

  • errors-only

Required: Yes

notificationMethod

Method of notification.

Type: string

Allowed Values:

  • email

  • slack

  • amazon-sns

Required: Yes

slackSettings

Slack settings for the notification. Required when notificationMethod is slack.

Type: ProjectNotificationSlackSettings object

Required: Conditional

Returns

A ProjectNotification object.

Sample Request

POST /api/Projects/proj-12345678/Notifications HTTP/1.1
Host: api.skeddly.com
Authorization: AccessKey <api key>
Content-Type: application/json

{
    "notificationLevel": "errors-only",
    "notificationMethod": "email",
    "emailSettings": {
        "emailAddresses": [
            "user1@example.com"
        ]
    }
}

Sample Response

{
    "notificationId": "pn-12345678",
    "createdDate": "2023-01-26T12:00:00:Z",
    "lastModifiedDate": "2023-01-26T12:00:00:Z",
    "lastModifiedBy": "u-12345678",
    
    "notificationLevel": "errors-only",
    "notificationMethod": "email",
    "emailSettings": {
        "emailAddresses": [
            "user1@example.com"
        ]
    }
}

Last updated