# This file was auto-generated by Fern from our API Definition.

import enum
import typing

T_Result = typing.TypeVar("T_Result")


class SnykRegion(str, enum.Enum):
    US_REGION_1 = "SNYK-US-01"
    """
    Region Name: SYNK-US-01
    Snyk Login and Web UI URL: https://app.snyk.io
    """

    US_REGION_2 = "SNYK-US-02"
    """
    Region Name: SYNK-US-02
    Snyk Login and Web UI URL: https://app.us.snyk.io/
    """

    EU_REGION_1 = "SNYK-EU-01"
    """
    Region Name: SYNK-EU-01
    Snyk Login and Web UI URL: https://app.eu.snyk.io/
    """

    AU_REGION_1 = "SNYK-AU-01"
    """
    Region Name: SYNK-AU-01
    Snyk Login and Web UI URL: https://app.au.snyk.io/
    """

    _UNKNOWN = "__SNYKREGION_UNKNOWN__"
    """
    This member is used for forward compatibility. If the value is not recognized by the enum, it will be stored here, and the raw value is accessible through `.value`.
    """

    @classmethod
    def _missing_(cls, value: typing.Any) -> "SnykRegion":
        unknown = cls._UNKNOWN
        unknown._value_ = value
        return unknown

    def visit(
        self,
        us_region_1: typing.Callable[[], T_Result],
        us_region_2: typing.Callable[[], T_Result],
        eu_region_1: typing.Callable[[], T_Result],
        au_region_1: typing.Callable[[], T_Result],
        _unknown_member: typing.Callable[[str], T_Result],
    ) -> T_Result:
        if self is SnykRegion.US_REGION_1:
            return us_region_1()
        if self is SnykRegion.US_REGION_2:
            return us_region_2()
        if self is SnykRegion.EU_REGION_1:
            return eu_region_1()
        if self is SnykRegion.AU_REGION_1:
            return au_region_1()
        return _unknown_member(self._value_)
