from datetime import date, datetime  # noqa: F401
from typing import Dict, List  # noqa: F401

from timestep.api.openai.v1 import util
from timestep.api.openai.v1.models.base_model import Model
from timestep.api.openai.v1.models.submit_tool_outputs_run_request_tool_outputs_inner import \
    SubmitToolOutputsRunRequestToolOutputsInner  # noqa: E501


class SubmitToolOutputsRunRequest(Model):
    """NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).

    Do not edit the class manually.
    """

    def __init__(self, tool_outputs=None, stream=None):  # noqa: E501
        """SubmitToolOutputsRunRequest - a model defined in OpenAPI

        :param tool_outputs: The tool_outputs of this SubmitToolOutputsRunRequest.  # noqa: E501
        :type tool_outputs: List[SubmitToolOutputsRunRequestToolOutputsInner]
        :param stream: The stream of this SubmitToolOutputsRunRequest.  # noqa: E501
        :type stream: bool
        """
        self.openapi_types = {
            'tool_outputs': List[SubmitToolOutputsRunRequestToolOutputsInner],
            'stream': bool
        }

        self.attribute_map = {
            'tool_outputs': 'tool_outputs',
            'stream': 'stream'
        }

        self._tool_outputs = tool_outputs
        self._stream = stream

    @classmethod
    def from_dict(cls, dikt) -> 'SubmitToolOutputsRunRequest':
        """Returns the dict as a model

        :param dikt: A dict.
        :type: dict
        :return: The SubmitToolOutputsRunRequest of this SubmitToolOutputsRunRequest.  # noqa: E501
        :rtype: SubmitToolOutputsRunRequest
        """
        return util.deserialize_model(dikt, cls)

    @property
    def tool_outputs(self) -> List[SubmitToolOutputsRunRequestToolOutputsInner]:
        """Gets the tool_outputs of this SubmitToolOutputsRunRequest.

        A list of tools for which the outputs are being submitted.  # noqa: E501

        :return: The tool_outputs of this SubmitToolOutputsRunRequest.
        :rtype: List[SubmitToolOutputsRunRequestToolOutputsInner]
        """
        return self._tool_outputs

    @tool_outputs.setter
    def tool_outputs(self, tool_outputs: List[SubmitToolOutputsRunRequestToolOutputsInner]):
        """Sets the tool_outputs of this SubmitToolOutputsRunRequest.

        A list of tools for which the outputs are being submitted.  # noqa: E501

        :param tool_outputs: The tool_outputs of this SubmitToolOutputsRunRequest.
        :type tool_outputs: List[SubmitToolOutputsRunRequestToolOutputsInner]
        """
        if tool_outputs is None:
            raise ValueError("Invalid value for `tool_outputs`, must not be `None`")  # noqa: E501

        self._tool_outputs = tool_outputs

    @property
    def stream(self) -> bool:
        """Gets the stream of this SubmitToolOutputsRunRequest.

        If `true`, returns a stream of events that happen during the Run as server-sent events, terminating when the Run enters a terminal state with a `data: [DONE]` message.   # noqa: E501

        :return: The stream of this SubmitToolOutputsRunRequest.
        :rtype: bool
        """
        return self._stream

    @stream.setter
    def stream(self, stream: bool):
        """Sets the stream of this SubmitToolOutputsRunRequest.

        If `true`, returns a stream of events that happen during the Run as server-sent events, terminating when the Run enters a terminal state with a `data: [DONE]` message.   # noqa: E501

        :param stream: The stream of this SubmitToolOutputsRunRequest.
        :type stream: bool
        """

        self._stream = stream
