# Code generated by Lark OpenAPI.

from typing import Any, Optional, Union, Dict, List, Set, IO, Callable, Type
from lark_oapi.core.model import BaseRequest
from lark_oapi.core.enum import HttpMethod, AccessTokenType
from .search_enum_request_body import SearchEnumRequestBody


class SearchEnumRequest(BaseRequest):
    def __init__(self) -> None:
        super().__init__()
        self.request_body: Optional[SearchEnumRequestBody] = None

    @staticmethod
    def builder() -> "SearchEnumRequestBuilder":
        return SearchEnumRequestBuilder()


class SearchEnumRequestBuilder(object):

    def __init__(self) -> None:
        search_enum_request = SearchEnumRequest()
        search_enum_request.http_method = HttpMethod.POST
        search_enum_request.uri = "/open-apis/corehr/v2/enums/search"
        search_enum_request.token_types = {AccessTokenType.TENANT}
        self._search_enum_request: SearchEnumRequest = search_enum_request

    def request_body(self, request_body: SearchEnumRequestBody) -> "SearchEnumRequestBuilder":
        self._search_enum_request.request_body = request_body
        self._search_enum_request.body = request_body
        return self

    def build(self) -> SearchEnumRequest:
        return self._search_enum_request
