-
Notifications
You must be signed in to change notification settings - Fork 89
Expand file tree
/
Copy pathcreate_batch_send_request.py
More file actions
44 lines (33 loc) · 1.43 KB
/
create_batch_send_request.py
File metadata and controls
44 lines (33 loc) · 1.43 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# Code generated by Lark OpenAPI.
from typing import Optional
from lark_oapi.core.enum import AccessTokenType, HttpMethod
from lark_oapi.core.model import BaseRequest
from utils.feishu.message.v4.model.create_batch_send_request_body import (
CreateBatchSendRequestBody,
)
class CreateBatchSendRequest(BaseRequest):
def __init__(self) -> None:
super().__init__()
self.receive_id_type: Optional[str] = None
self.request_body: Optional[CreateBatchSendRequestBody] = None
@staticmethod
def builder() -> "CreateBatchSendRequestBuilder":
return CreateBatchSendRequestBuilder()
class CreateBatchSendRequestBuilder(object):
def __init__(self) -> None:
create_message_request = CreateBatchSendRequest()
create_message_request.http_method = HttpMethod.POST
create_message_request.uri = "/open-apis/message/v4/batch_send"
create_message_request.token_types = {
AccessTokenType.TENANT,
AccessTokenType.USER,
}
self._create_message_request: CreateBatchSendRequest = create_message_request
def request_body(
self, request_body: CreateBatchSendRequestBody
) -> "CreateBatchSendRequestBuilder":
self._create_message_request.request_body = request_body
self._create_message_request.body = request_body
return self
def build(self) -> CreateBatchSendRequest:
return self._create_message_request