# The Okta software accompanied by this notice is provided pursuant to the following terms:
# Copyright © 2025-Present, Okta, Inc.
# Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the
# License.
# You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
# Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS
# IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and limitations under the License.
# coding: utf-8

"""
Okta Admin Management

Allows customers to easily access the Okta Management APIs

The version of the OpenAPI document: 5.1.0
Contact: devex-public@okta.com
Generated by OpenAPI Generator (https://openapi-generator.tech)

Do not edit the class manually.
"""  # noqa: E501

from __future__ import annotations

import json
from enum import Enum

from typing_extensions import Self


class IdentityProviderType(str, Enum):
    """
    The IdP object's `type` property identifies the social or enterprise IdP used for authentication. Each IdP uses a
    specific protocol, therefore the `protocol` object must correspond with the IdP `type`. If the protocol is OAuth
    2.0-based, the `protocol` object's `scopes` property must also correspond with the scopes supported by the IdP `type`.
    For policy actions supported by each IdP type, see [IdP type policy actions](
    https://developer.okta.com/docs/api/openapi/okta-management/management/tag/IdentityProvider/#tag/IdentityProvider
    /operation/createIdentityProvider!path=policy&t=request).  | Type               | Description
                                                                                                                   |
    Corresponding protocol | Corresponding protocol scopes                                         | | ------------------ |
    -----------------------------------------------------------------------------------------------------------------------------------------------------
    | ---------------------- | --------------------------------------------------------------------  | | `AMAZON`
    | [Amazon](https://developer.amazon.com/settings/console/registration?return_to=/)&nbsp;as the IdP
                     | OpenID Connect         | `profile`, `profile:user_id`                                          | |
                     `APPLE`            | [Apple](https://developer.apple.com/sign-in-with-apple/)&nbsp;as the IdP
                                                                          | OpenID Connect         | `names`, `email`,
                                                                          `openid`
                                                                           | | `DISCORD`          | [Discord](
                                                                           https://discord.com/login)&nbsp;as the IdP
    | OAuth 2.0              | `identify`, `email`                                                   | | `FACEBOOK`
    | [Facebook](https://developers.facebook.com)&nbsp;as the IdP
                     | OAuth 2.0              | `public_profile`, `email`                                             | |
                     `GITHUB`           | [GitHub](https://github.com/join)&nbsp;as the IdP
                                                                          | OAuth 2.0              | `user`
                                                                                                                        |
    | `GITLAB`           | [GitLab](https://gitlab.com/users/sign_in)&nbsp;as the IdP
                                          | OpenID Connect         | `openid`, `read_user`, `profile`, `email`
                                                        | | `GOOGLE`           | [Google](
                                                        https://accounts.google.com/signup)&nbsp;as the IdP
    | OpenID Connect    | `openid`, `email`, `profile`                                          | | `IDV_PERSONA`      | [
    Persona](https://app.withpersona.com/dashboard/login)&nbsp;as the IDV IdP
                  | ID verification        |                                                                       | |
                  `IDV_CLEAR`        | [CLEAR Verified](https://www.clearme.com/)&nbsp;as the IDV IdP
                                                                    | ID verification        | `openid`, `profile`,
                                                                    `identity_assurance`                             | |
                                                                    `IDV_INCODE`       | [Incode](
                                                                    https://incode.com/)&nbsp;as the IDV IdP
                                                                                                                                          | ID verification        | `openid`, `profile`, `identity_assurance`                             | | `IDV_STANDARD` | Custom IDV&nbsp;as the IDV IdP                                                                                       | ID verification        | `openid`, `profile`, `identity_assurance`                             | | `LINKEDIN`         | [LinkedIn](https://developer.linkedin.com/)&nbsp;as the IdP                                                                             | OAuth 2.0              | `r_emailaddress`, `r_liteprofile`                                     | | `LOGINGOV`         | [Login.gov](https://developers.login.gov/)&nbsp;as the IdP                                                                              | OpenID Connect         | `email`, `profile`, `profile:name`                                    | | `LOGINGOV_SANDBOX` | [Login.gov's identity sandbox](https://developers.login.gov/testing/)&nbsp;as the IdP                                                   | OpenID Connect         | `email`, `profile`, `profile:name`                                    | | `MICROSOFT`        | [Microsoft Enterprise SSO](https://azure.microsoft.com/)&nbsp;as the IdP                                                                | OpenID Connect         | `openid`, `email`, `profile`, `https://graph.microsoft.com/User.Read` | | `OIDC`             | IdP that supports [OpenID Connect](https://openid.net/specs/openid-connect-core-1_0.html)                                               | OpenID Connect         | `openid`, `email`, `profile`                                          | | `PAYPAL`           | [Paypal](https://www.paypal.com/signin)&nbsp;as the IdP                                                                                 | OpenID Connect         | `openid`, `email`, `profile`                                          | | `PAYPAL_SANDBOX`   | [Paypal Sandbox](https://developer.paypal.com/tools/sandbox/)&nbsp;as the IdP                                                           | OpenID Connect         | `openid`, `email`, `profile`                                          | | `SALESFORCE`       | [SalesForce](https://login.salesforce.com/)&nbsp;as the IdP                                                                             | OAuth 2.0              | `id`, `email`, `profile`                                              | | `SAML2`            | Enterprise IdP that supports the [SAML 2.0 Web Browser SSO Profile](https://docs.oasis-open.org/security/saml/v2.0/saml-profiles-2.0-os.pdf)| SAML 2.0  |                                                                                | | `SPOTIFY`          | [Spotify](https://developer.spotify.com/)&nbsp;as the IdP                                                                               | OpenID Connect         | `user-read-email`, `user-read-private`                                | | `X509`             | [Smart Card IdP](https://tools.ietf.org/html/rfc5280)                                                                                   | Mutual TLS             |                                                                       | | `XERO`             | [Xero](https://www.xero.com/us/signup/api/)&nbsp;as the IdP                                                                             | OpenID Connect         | `openid`, `profile`, `email`                                          | | `YAHOO`            | [Yahoo](https://login.yahoo.com/)&nbsp;as the IdP                                                                                       | OpenID Connect         | `openid`, `profile`, `email`                                          | | `YAHOOJP`          | [Yahoo Japan](https://login.yahoo.co.jp/config/login)&nbsp;as the IdP                                                                   | OpenID Connect         | `openid`, `profile`, `email`                                          | | `OKTA_INTEGRATION`             | IdP that supports the [OpenID Connect](https://openid.net/specs/openid-connect-core-1_0.html) Org2Org IdP                                               | OpenID Connect         | `openid`, `email`, `profile`                                          | # noqa: E501
    """

    """
    allowed enum values
    """
    AMAZON = "AMAZON"
    APPLE = "APPLE"
    DISCORD = "DISCORD"
    FACEBOOK = "FACEBOOK"
    GITHUB = "GITHUB"
    GITLAB = "GITLAB"
    GOOGLE = "GOOGLE"
    IDV_CLEAR = "IDV_CLEAR"
    IDV_INCODE = "IDV_INCODE"
    IDV_PERSONA = "IDV_PERSONA"
    IDV_STANDARD = "IDV_STANDARD"
    LINKEDIN = "LINKEDIN"
    LOGINGOV = "LOGINGOV"
    LOGINGOV_SANDBOX = "LOGINGOV_SANDBOX"
    MICROSOFT = "MICROSOFT"
    OIDC = "OIDC"
    OKTA_INTEGRATION = "OKTA_INTEGRATION"
    PAYPAL = "PAYPAL"
    PAYPAL_SANDBOX = "PAYPAL_SANDBOX"
    SALESFORCE = "SALESFORCE"
    SAML2 = "SAML2"
    SPOTIFY = "SPOTIFY"
    X509 = "X509"
    XERO = "XERO"
    YAHOO = "YAHOO"
    YAHOOJP = "YAHOOJP"

    @classmethod
    def from_json(cls, json_str: str) -> Self:
        """Create an instance of IdentityProviderType from a JSON string"""
        return cls(json.loads(json_str))
