# coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import copy
import warnings
import sys
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
if sys.version_info >= (3, 11):
    from typing import NotRequired, TypedDict, TypeAlias
else:
    from typing_extensions import NotRequired, TypedDict, TypeAlias
from . import _utilities

__all__ = ['ProviderArgs', 'Provider']

@pulumi.input_type
class ProviderArgs:
    def __init__(__self__, *,
                 url: pulumi.Input[str],
                 insecure: Optional[pulumi.Input[bool]] = None,
                 password: Optional[pulumi.Input[str]] = None,
                 retry_max_time: Optional[pulumi.Input[str]] = None,
                 retry_mode: Optional[pulumi.Input[str]] = None,
                 token: Optional[pulumi.Input[str]] = None,
                 username: Optional[pulumi.Input[str]] = None):
        """
        The set of arguments for constructing a Provider resource.
        :param pulumi.Input[str] url: Hostname of the xoa router. Can be set via the XOA_URL environment variable.
        :param pulumi.Input[bool] insecure: Whether SSL should be verified or not. Can be set via the XOA_INSECURE environment variable.
        :param pulumi.Input[str] password: Password for xoa api. Can be set via the XOA_PASSWORD environment variable.
        :param pulumi.Input[str] retry_max_time: If `retry_mode` is set, this specifies the duration for which the backoff method will continue retries. Can be set via
               the `XOA_RETRY_MAX_TIME` environment variable
        :param pulumi.Input[str] retry_mode: Specifies if retries should be attempted for requests that require eventual . Can be set via the XOA_RETRY_MODE
               environment variable.
        :param pulumi.Input[str] token: Password for xoa api. Can be set via the XOA_TOKEN environment variable.
        :param pulumi.Input[str] username: User account for xoa api. Can be set via the XOA_USER environment variable.
        """
        pulumi.set(__self__, "url", url)
        if insecure is not None:
            pulumi.set(__self__, "insecure", insecure)
        if password is not None:
            pulumi.set(__self__, "password", password)
        if retry_max_time is not None:
            pulumi.set(__self__, "retry_max_time", retry_max_time)
        if retry_mode is not None:
            pulumi.set(__self__, "retry_mode", retry_mode)
        if token is not None:
            pulumi.set(__self__, "token", token)
        if username is not None:
            pulumi.set(__self__, "username", username)

    @property
    @pulumi.getter
    def url(self) -> pulumi.Input[str]:
        """
        Hostname of the xoa router. Can be set via the XOA_URL environment variable.
        """
        return pulumi.get(self, "url")

    @url.setter
    def url(self, value: pulumi.Input[str]):
        pulumi.set(self, "url", value)

    @property
    @pulumi.getter
    def insecure(self) -> Optional[pulumi.Input[bool]]:
        """
        Whether SSL should be verified or not. Can be set via the XOA_INSECURE environment variable.
        """
        return pulumi.get(self, "insecure")

    @insecure.setter
    def insecure(self, value: Optional[pulumi.Input[bool]]):
        pulumi.set(self, "insecure", value)

    @property
    @pulumi.getter
    def password(self) -> Optional[pulumi.Input[str]]:
        """
        Password for xoa api. Can be set via the XOA_PASSWORD environment variable.
        """
        return pulumi.get(self, "password")

    @password.setter
    def password(self, value: Optional[pulumi.Input[str]]):
        pulumi.set(self, "password", value)

    @property
    @pulumi.getter(name="retryMaxTime")
    def retry_max_time(self) -> Optional[pulumi.Input[str]]:
        """
        If `retry_mode` is set, this specifies the duration for which the backoff method will continue retries. Can be set via
        the `XOA_RETRY_MAX_TIME` environment variable
        """
        return pulumi.get(self, "retry_max_time")

    @retry_max_time.setter
    def retry_max_time(self, value: Optional[pulumi.Input[str]]):
        pulumi.set(self, "retry_max_time", value)

    @property
    @pulumi.getter(name="retryMode")
    def retry_mode(self) -> Optional[pulumi.Input[str]]:
        """
        Specifies if retries should be attempted for requests that require eventual . Can be set via the XOA_RETRY_MODE
        environment variable.
        """
        return pulumi.get(self, "retry_mode")

    @retry_mode.setter
    def retry_mode(self, value: Optional[pulumi.Input[str]]):
        pulumi.set(self, "retry_mode", value)

    @property
    @pulumi.getter
    def token(self) -> Optional[pulumi.Input[str]]:
        """
        Password for xoa api. Can be set via the XOA_TOKEN environment variable.
        """
        return pulumi.get(self, "token")

    @token.setter
    def token(self, value: Optional[pulumi.Input[str]]):
        pulumi.set(self, "token", value)

    @property
    @pulumi.getter
    def username(self) -> Optional[pulumi.Input[str]]:
        """
        User account for xoa api. Can be set via the XOA_USER environment variable.
        """
        return pulumi.get(self, "username")

    @username.setter
    def username(self, value: Optional[pulumi.Input[str]]):
        pulumi.set(self, "username", value)


class Provider(pulumi.ProviderResource):
    @overload
    def __init__(__self__,
                 resource_name: str,
                 opts: Optional[pulumi.ResourceOptions] = None,
                 insecure: Optional[pulumi.Input[bool]] = None,
                 password: Optional[pulumi.Input[str]] = None,
                 retry_max_time: Optional[pulumi.Input[str]] = None,
                 retry_mode: Optional[pulumi.Input[str]] = None,
                 token: Optional[pulumi.Input[str]] = None,
                 url: Optional[pulumi.Input[str]] = None,
                 username: Optional[pulumi.Input[str]] = None,
                 __props__=None):
        """
        The provider type for the xenorchestra package. By default, resources use package-wide configuration
        settings, however an explicit `Provider` instance may be created and passed during resource
        construction to achieve fine-grained programmatic control over provider settings. See the
        [documentation](https://www.pulumi.com/docs/reference/programming-model/#providers) for more information.

        :param str resource_name: The name of the resource.
        :param pulumi.ResourceOptions opts: Options for the resource.
        :param pulumi.Input[bool] insecure: Whether SSL should be verified or not. Can be set via the XOA_INSECURE environment variable.
        :param pulumi.Input[str] password: Password for xoa api. Can be set via the XOA_PASSWORD environment variable.
        :param pulumi.Input[str] retry_max_time: If `retry_mode` is set, this specifies the duration for which the backoff method will continue retries. Can be set via
               the `XOA_RETRY_MAX_TIME` environment variable
        :param pulumi.Input[str] retry_mode: Specifies if retries should be attempted for requests that require eventual . Can be set via the XOA_RETRY_MODE
               environment variable.
        :param pulumi.Input[str] token: Password for xoa api. Can be set via the XOA_TOKEN environment variable.
        :param pulumi.Input[str] url: Hostname of the xoa router. Can be set via the XOA_URL environment variable.
        :param pulumi.Input[str] username: User account for xoa api. Can be set via the XOA_USER environment variable.
        """
        ...
    @overload
    def __init__(__self__,
                 resource_name: str,
                 args: ProviderArgs,
                 opts: Optional[pulumi.ResourceOptions] = None):
        """
        The provider type for the xenorchestra package. By default, resources use package-wide configuration
        settings, however an explicit `Provider` instance may be created and passed during resource
        construction to achieve fine-grained programmatic control over provider settings. See the
        [documentation](https://www.pulumi.com/docs/reference/programming-model/#providers) for more information.

        :param str resource_name: The name of the resource.
        :param ProviderArgs args: The arguments to use to populate this resource's properties.
        :param pulumi.ResourceOptions opts: Options for the resource.
        """
        ...
    def __init__(__self__, resource_name: str, *args, **kwargs):
        resource_args, opts = _utilities.get_resource_args_opts(ProviderArgs, pulumi.ResourceOptions, *args, **kwargs)
        if resource_args is not None:
            __self__._internal_init(resource_name, opts, **resource_args.__dict__)
        else:
            __self__._internal_init(resource_name, *args, **kwargs)

    def _internal_init(__self__,
                 resource_name: str,
                 opts: Optional[pulumi.ResourceOptions] = None,
                 insecure: Optional[pulumi.Input[bool]] = None,
                 password: Optional[pulumi.Input[str]] = None,
                 retry_max_time: Optional[pulumi.Input[str]] = None,
                 retry_mode: Optional[pulumi.Input[str]] = None,
                 token: Optional[pulumi.Input[str]] = None,
                 url: Optional[pulumi.Input[str]] = None,
                 username: Optional[pulumi.Input[str]] = None,
                 __props__=None):
        opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
        if not isinstance(opts, pulumi.ResourceOptions):
            raise TypeError('Expected resource options to be a ResourceOptions instance')
        if opts.id is None:
            if __props__ is not None:
                raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
            __props__ = ProviderArgs.__new__(ProviderArgs)

            __props__.__dict__["insecure"] = pulumi.Output.from_input(insecure).apply(pulumi.runtime.to_json) if insecure is not None else None
            __props__.__dict__["password"] = password
            __props__.__dict__["retry_max_time"] = retry_max_time
            __props__.__dict__["retry_mode"] = retry_mode
            __props__.__dict__["token"] = token
            if url is None and not opts.urn:
                raise TypeError("Missing required property 'url'")
            __props__.__dict__["url"] = url
            __props__.__dict__["username"] = username
        super(Provider, __self__).__init__(
            'xenorchestra',
            resource_name,
            __props__,
            opts)

    @property
    @pulumi.getter
    def password(self) -> pulumi.Output[Optional[str]]:
        """
        Password for xoa api. Can be set via the XOA_PASSWORD environment variable.
        """
        return pulumi.get(self, "password")

    @property
    @pulumi.getter(name="retryMaxTime")
    def retry_max_time(self) -> pulumi.Output[Optional[str]]:
        """
        If `retry_mode` is set, this specifies the duration for which the backoff method will continue retries. Can be set via
        the `XOA_RETRY_MAX_TIME` environment variable
        """
        return pulumi.get(self, "retry_max_time")

    @property
    @pulumi.getter(name="retryMode")
    def retry_mode(self) -> pulumi.Output[Optional[str]]:
        """
        Specifies if retries should be attempted for requests that require eventual . Can be set via the XOA_RETRY_MODE
        environment variable.
        """
        return pulumi.get(self, "retry_mode")

    @property
    @pulumi.getter
    def token(self) -> pulumi.Output[Optional[str]]:
        """
        Password for xoa api. Can be set via the XOA_TOKEN environment variable.
        """
        return pulumi.get(self, "token")

    @property
    @pulumi.getter
    def url(self) -> pulumi.Output[str]:
        """
        Hostname of the xoa router. Can be set via the XOA_URL environment variable.
        """
        return pulumi.get(self, "url")

    @property
    @pulumi.getter
    def username(self) -> pulumi.Output[Optional[str]]:
        """
        User account for xoa api. Can be set via the XOA_USER environment variable.
        """
        return pulumi.get(self, "username")

