LocationSendMessage
location_message = LocationSendMessage(
title='my location',
address='Tokyo',
latitude(緯度)=35.65910807942215,
longitude(經度)=139.70372892916203
)
顯示地圖title跟address是我們打什麼就會顯示什麼,而經緯度我們可以利用Google地圖尋找
Location message
type
String Required
location
最多只能有100字
title
String Required
Title
Max character limit: 100
同上
address
String Required
Address
Max character limit: 100
latitude
Decimal Required
Latitude
longitude
Decimal Required
Longitude
ImagemapSendMessage
imagemap_message = ImagemapSendMessage(
base_url='https://example.com/base',圖片來源URL
alt_text='this is an imagemap',副標題
base_size=BaseSize(height=1040, width=1040),圖片範圍大小
我們在圖片中也可以放入影片
video=Video(
original_content_url='https://example.com/video.mp4',
preview_image_url='https://example.com/video_preview.jpg',
area=ImagemapArea(
x=0, y=0, width=1040, height=585
),
external_link=ExternalLink(
影片點開後右上角會有一個小標籤供點擊
link_uri='https://example.com/see_more.html',
label='See More',
),
),
當圖片按鈕按下去後的動作
actions=[
URIImagemapAction(
link_uri='https://example.com/',
area=ImagemapArea(
x=0, y=0, width=520, height=1040
)
),
MessageImagemapAction(
text='hello',
area=ImagemapArea(
x=520, y=0, width=520, height=1040
)
)
]
)
明天會再講的更詳細一些