Message
Send Message
์ฌ์ฉ์๊ฐ ํ ์คํธ ๋ฉ์์ง๋ฅผ ์ฑ๋์ ์ ์กํฉ๋๋ค.
Event
Event Name:
send_message
Header
App-Id
{ app id }
Authorization
{ access token }
Payload
userId
string
๋ฉ์์ง๋ฅผ ๋ณด๋ด๋ ์ฌ์ฉ์ ID
channelId
string
๋ฉ์์ง๊ฐ ์ ์ก๋ ์ฑ๋ ID
message
string
ํ ์คํธ ๋ฉ์์ง ๋ด์ฉ
Response
Retrieve Messages
ํน์ ์ฑ๋์ ๋ฉ์์ง ๋ชฉ๋ก์ ์กฐํํฉ๋๋ค.
Event
Event Name:
retrieve_messages
Header
App-Id
{ app id }
Authorization
{ access token }
Payload
channelID
string
์กฐํํ ์ฑ๋ ID
limit
int
๊ฐ์ ธ์ฌ ๋ฉ์์ง ์ (๊ธฐ๋ณธ๊ฐ: 20)
before
string
ํน์ ๋ฉ์์ง ID ์ด์ ๋ฉ์์ง๋ฅผ ์กฐํ
Response
Receive real-time messages
์น๊ตฌ๊ฐ ๋ฉ์์ง๋ฅผ ๋ณด๋ผ ๋๋ง๋ค ์ค์๊ฐ์ผ๋ก ๋ฉ์์ง๋ฅผ ์์ ํฉ๋๋ค.
Event
Name:
received_message
Header
App-Id
{ app id }
Authorization
{ access token }
Payload
messageId
string
senderId
string
receiverId
string
content
string
ํ
์คํธ ๋ฉ์์ง ๋ด์ฉ (๋ฏธ๋์ด ๋ฉ์์ง์ผ ๊ฒฝ์ฐ null
).
mediaUrl
string
๋ฏธ๋์ด ํ์ผ URL (ํ
์คํธ ๋ฉ์์ง์ผ ๊ฒฝ์ฐ null
).
mediaType
string
๋ฏธ์ด ํ์ผ ํ์ (image/jpeg
, video/mp4
).๋ค
timestamp
string
Response
Last updated