# Code generated by lark_sdk_gen. DO NOT EDIT.

from pylark.lark_request import RawRequestReq, _new_method_option
import attr
import typing
import io


@attr.s
class GetContactGroupReq(object):
    group_id: str = attr.ib(
        default="", metadata={"req_type": "path"}
    )  # 用户组ID, 示例值："g193821"


@attr.s
class GetContactGroupRespGroup(object):
    id: str = attr.ib(default="", metadata={"req_type": "json"})  # 用户组ID
    name: str = attr.ib(default="", metadata={"req_type": "json"})  # 用户组名字
    description: str = attr.ib(default="", metadata={"req_type": "json"})  # 用户组描述
    member_user_count: int = attr.ib(
        default=0, metadata={"req_type": "json"}
    )  # 用户组成员中用户的数量
    member_department_count: int = attr.ib(
        default=0, metadata={"req_type": "json"}
    )  # 用户组成员中部门的数量


@attr.s
class GetContactGroupResp(object):
    group: GetContactGroupRespGroup = attr.ib(
        default=None, metadata={"req_type": "json"}
    )  # 用户组详情


def _gen_get_contact_group_req(request, options) -> RawRequestReq:
    return RawRequestReq(
        dataclass=GetContactGroupResp,
        scope="Contact",
        api="GetContactGroup",
        method="GET",
        url="https://open.feishu.cn/open-apis/contact/v3/group/:group_id",
        body=request,
        method_option=_new_method_option(options),
        need_tenant_access_token=True,
    )
