Skip to content

Latest commit

 

History

History
104 lines (73 loc) · 7.01 KB

README.md

File metadata and controls

104 lines (73 loc) · 7.01 KB

Authentication

(subscribers.authentication)

Overview

Available Operations

chat_access_oauth_call_back

Handle providers oauth redirect

Example Usage

from novu_py import Novu
import os

with Novu(
    secret_key=os.getenv("NOVU_SECRET_KEY", ""),
) as novu:

    res = novu.subscribers.authentication.chat_access_oauth_call_back(request={
        "subscriber_id": "<id>",
        "provider_id": "<id>",
        "hmac_hash": "<value>",
        "environment_id": "<id>",
        "code": "<value>",
    })

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
request models.SubscribersV1ControllerChatOauthCallbackRequest ✔️ The request object to use for the request.
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.SubscribersV1ControllerChatOauthCallbackResponse

Errors

Error Type Status Code Content Type
models.ErrorDto 414 application/json
models.ErrorDto 400, 401, 403, 404, 405, 409, 413, 415 application/json
models.ValidationErrorDto 422 application/json
models.ErrorDto 500 application/json
models.APIError 4XX, 5XX */*

chat_access_oauth

Handle chat oauth

Example Usage

from novu_py import Novu
import os

with Novu(
    secret_key=os.getenv("NOVU_SECRET_KEY", ""),
) as novu:

    res = novu.subscribers.authentication.chat_access_oauth(request={
        "subscriber_id": "<id>",
        "provider_id": "<id>",
        "hmac_hash": "<value>",
        "environment_id": "<id>",
    })

    # Handle response
    print(res)

Parameters

Parameter Type Required Description
request models.SubscribersV1ControllerChatAccessOauthRequest ✔️ The request object to use for the request.
retries Optional[utils.RetryConfig] Configuration to override the default retry behavior of the client.

Response

models.SubscribersV1ControllerChatAccessOauthResponse

Errors

Error Type Status Code Content Type
models.ErrorDto 414 application/json
models.ErrorDto 400, 401, 403, 404, 405, 409, 413, 415 application/json
models.ValidationErrorDto 422 application/json
models.ErrorDto 500 application/json
models.APIError 4XX, 5XX */*