No project description provided
Project description
RCS-PYDANTIC
Introduce
한국 통신사 rcs 를 위한 pydantic 구조체
Installation
pip install rcs-pydantic
Quick start
from rcs_pydantic import MessageInfo, RcsMessage
message_info = {
"replyId": "B01RDSFR.KcNNLk67ui.FDSAF432153214",
"eventType":"message",
"messageBody": {"textMessage": "안녕하세요?"},
"userContact":"01012341234",
"chatbotId":"0212351235",
"timestamp": "2020-03-03T04:43:55.867+09"
}
rcs = {
"message_base_id": "SCS00000",
"service_type": "RCSSMS",
"header": "0",
"cdr_id": "KT_rcsid",
"body": {
"title": "타이틀",
"description": "일반 RCSSMS 테스트 메시지 입니다."
}
}
rcs_message = RcsMessage(message_info=MessageInfo(**message_info), **rcs)
>>> print(rcs_message.send_info)
common=CommonInfo(
msgId='B01RDSFR.KcNNLk67ui.FDSAF432153214',
userContact='01012341234',
scheduleType=<ScheduleTypeEnum.IMMEDIATE: 0>,
msgGroupId=None,
msgServiceType=<MessageServiceTypeEnum.RCS: 'rcs'>
)
rcs=RcsInfo(
chatbotId='0212351235',
agencyId='ktbizrcs',
messagebaseId='SCS00000',
serviceType=<ServiceTypeEnum.SMS: 'RCSSMS'>,
expiryOption=<ExpiryOptionEnum.AFTER_SETTING_TIMES: 2>,
header=<HeaderEnum.NOT_ADVERTISE: '0'>,
footer=None,
cdrId='KT_rcsid',
copyAllowed=True,
body=RcsSMSBody(title='타이틀', description='일반 RCSSMS 테스트 메시지 입니다.'),
buttons=None,
chipLists=None,
replyId=None
)
>>>
Features
TODO
Contribution
TODO
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
rcs-pydantic-0.1.19.tar.gz
(23.4 kB
view hashes)
Built Distribution
Close
Hashes for rcs_pydantic-0.1.19-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 004d149c2450e43ca100e2db2d181ce7480e88b0b3d80173876ab50434428c7f |
|
MD5 | 4a04e419f56d08da85333180b36e7ed5 |
|
BLAKE2b-256 | 1c33ecbd7ea32fc0a9af68a432ad5249e45dbe46233688cdc7d67308184c67a0 |