Skip to content

Latest commit

 

History

History
1111 lines (776 loc) · 36.8 KB

NotificationSettingsApi.md

File metadata and controls

1111 lines (776 loc) · 36.8 KB

whylabs_client.NotificationSettingsApi

All URIs are relative to https://api.whylabsapp.com

Method HTTP request Description
add_notification_action POST /v0/notification-settings/{org_id}/actions/{type}/{action_id} Add new notification action
delete_notification_action DELETE /v0/notification-settings/{org_id}/actions/{action_id} Delete notification action
disable_notification_action PUT /v0/notification-settings/{org_id}/actions/{action_id}/disable Disable notification action
enable_notification_action PUT /v0/notification-settings/{org_id}/actions/{action_id}/enable Enable notification action
get_email_notification_action_payload GET /v0/notification-settings/actions/email/payload Get dummy notification action payload
get_notification_action GET /v0/notification-settings/{org_id}/actions/{action_id} Get notification action for id
get_pager_duty_notification_action_payload GET /v0/notification-settings/actions/pagerduty/payload Get dummy notification action payload
get_slack_notification_action_payload GET /v0/notification-settings/actions/slack/payload Get dummy notification action payload
get_teams_notification_action_payload GET /v0/notification-settings/actions/teams/payload Get dummy notification action payload
get_webhook_notification_action_payload GET /v0/notification-settings/actions/webhook/payload Get dummy notification action payload for webhooks
list_notification_actions GET /v0/notification-settings/{org_id}/actions List notification actions for an org
put_notification_action PUT /v0/notification-settings/{org_id}/actions/{type}/{action_id} Add new notification action
test_notification_action POST /v0/notification-settings/{org_id}/actions/{action_id}/test Test a notification action
update_notification_action PATCH /v0/notification-settings/{org_id}/actions/{type}/{action_id} Update notification action

add_notification_action

add_notification_action(org_id, type, action_id, body)

Add new notification action

Add new notification action

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.action_type import ActionType
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    type = ActionType("EMAIL") # ActionType | 
    action_id = "user-action" # str | 
    body = "body_example" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Add new notification action
        api_instance.add_notification_action(org_id, type, action_id, body)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->add_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
type ActionType
action_id str
body str

Return type

void (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: Not defined

HTTP response details

Status code Description Response headers
200 AddNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_notification_action

delete_notification_action(org_id, action_id)

Delete notification action

Delete notification action

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    action_id = "user-action" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Delete notification action
        api_instance.delete_notification_action(org_id, action_id)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->delete_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
action_id str

Return type

void (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
200 DeleteNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

disable_notification_action

disable_notification_action(org_id, action_id)

Disable notification action

Disable notification action

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    action_id = "user-action" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Disable notification action
        api_instance.disable_notification_action(org_id, action_id)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->disable_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
action_id str

Return type

void (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
200 DisableNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

enable_notification_action

enable_notification_action(org_id, action_id)

Enable notification action

Enable notification action

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    action_id = "user-action" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Enable notification action
        api_instance.enable_notification_action(org_id, action_id)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->enable_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
action_id str

Return type

void (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
200 EnableNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_email_notification_action_payload

EmailNotificationAction get_email_notification_action_payload()

Get dummy notification action payload

Get dummy notification action payload

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.email_notification_action import EmailNotificationAction
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)

    # example, this endpoint has no required or optional parameters
    try:
        # Get dummy notification action payload
        api_response = api_instance.get_email_notification_action_payload()
        pprint(api_response)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->get_email_notification_action_payload: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

EmailNotificationAction

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 getEmailNotificationActionPayload 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_notification_action

NotificationAction get_notification_action(org_id, action_id)

Get notification action for id

Get notification action for id

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.notification_action import NotificationAction
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    action_id = "user-action" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Get notification action for id
        api_response = api_instance.get_notification_action(org_id, action_id)
        pprint(api_response)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->get_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
action_id str

Return type

NotificationAction

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 GetNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_pager_duty_notification_action_payload

PagerDutyNotificationAction get_pager_duty_notification_action_payload()

Get dummy notification action payload

Get dummy notification action payload

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.pager_duty_notification_action import PagerDutyNotificationAction
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)

    # example, this endpoint has no required or optional parameters
    try:
        # Get dummy notification action payload
        api_response = api_instance.get_pager_duty_notification_action_payload()
        pprint(api_response)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->get_pager_duty_notification_action_payload: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

PagerDutyNotificationAction

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 getPagerDutyNotificationActionPayload 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_slack_notification_action_payload

SlackNotificationAction get_slack_notification_action_payload()

Get dummy notification action payload

Get dummy notification action payload

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.slack_notification_action import SlackNotificationAction
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)

    # example, this endpoint has no required or optional parameters
    try:
        # Get dummy notification action payload
        api_response = api_instance.get_slack_notification_action_payload()
        pprint(api_response)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->get_slack_notification_action_payload: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

SlackNotificationAction

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 getSlackNotificationActionPayload 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_teams_notification_action_payload

TeamsNotificationAction get_teams_notification_action_payload()

Get dummy notification action payload

Get dummy notification action payload

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.teams_notification_action import TeamsNotificationAction
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)

    # example, this endpoint has no required or optional parameters
    try:
        # Get dummy notification action payload
        api_response = api_instance.get_teams_notification_action_payload()
        pprint(api_response)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->get_teams_notification_action_payload: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

TeamsNotificationAction

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 getTeamsNotificationActionPayload 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_webhook_notification_action_payload

WebhookNotificationAction get_webhook_notification_action_payload()

Get dummy notification action payload for webhooks

Get dummy notification action payload for webhooks

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.webhook_notification_action import WebhookNotificationAction
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)

    # example, this endpoint has no required or optional parameters
    try:
        # Get dummy notification action payload for webhooks
        api_response = api_instance.get_webhook_notification_action_payload()
        pprint(api_response)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->get_webhook_notification_action_payload: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

WebhookNotificationAction

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 getWebhookNotificationActionPayload 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

list_notification_actions

[NotificationAction] list_notification_actions(org_id)

List notification actions for an org

Get notification actions for an org

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.notification_action import NotificationAction
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 

    # example passing only required values which don't have defaults set
    try:
        # List notification actions for an org
        api_response = api_instance.list_notification_actions(org_id)
        pprint(api_response)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->list_notification_actions: %s\n" % e)

Parameters

Name Type Description Notes
org_id str

Return type

[NotificationAction]

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 ListNotificationActions 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

put_notification_action

put_notification_action(org_id, type, action_id, body)

Add new notification action

Add new notification action

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.action_type import ActionType
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    type = ActionType("EMAIL") # ActionType | 
    action_id = "user-action" # str | 
    body = "body_example" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Add new notification action
        api_instance.put_notification_action(org_id, type, action_id, body)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->put_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
type ActionType
action_id str
body str

Return type

void (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: Not defined

HTTP response details

Status code Description Response headers
200 PutNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

test_notification_action

test_notification_action(org_id, action_id)

Test a notification action

Test a notification action

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    action_id = "user-action" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Test a notification action
        api_instance.test_notification_action(org_id, action_id)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->test_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
action_id str

Return type

void (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

HTTP response details

Status code Description Response headers
200 TestNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_notification_action

update_notification_action(org_id, type, action_id, body)

Update notification action

Update notification action

Example

  • Api Key Authentication (ApiKeyAuth):
import time
import whylabs_client
from whylabs_client.api import notification_settings_api
from whylabs_client.model.action_type import ActionType
from pprint import pprint
# Defining the host is optional and defaults to https://api.whylabsapp.com
# See configuration.py for a list of all supported configuration parameters.
configuration = whylabs_client.Configuration(
    host = "https://api.whylabsapp.com"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: ApiKeyAuth
configuration.api_key['ApiKeyAuth'] = 'YOUR_API_KEY'

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['ApiKeyAuth'] = 'Bearer'

# Enter a context with an instance of the API client
with whylabs_client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = notification_settings_api.NotificationSettingsApi(api_client)
    org_id = "org-123" # str | 
    type = ActionType("EMAIL") # ActionType | 
    action_id = "user-action" # str | 
    body = "body_example" # str | 

    # example passing only required values which don't have defaults set
    try:
        # Update notification action
        api_instance.update_notification_action(org_id, type, action_id, body)
    except whylabs_client.ApiException as e:
        print("Exception when calling NotificationSettingsApi->update_notification_action: %s\n" % e)

Parameters

Name Type Description Notes
org_id str
type ActionType
action_id str
body str

Return type

void (empty response body)

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: Not defined

HTTP response details

Status code Description Response headers
200 UpdateNotificationAction 200 response -

[Back to top] [Back to API list] [Back to Model list] [Back to README]