Closed ArthurTech123 closed 5 days ago
def Image_Test():
mastor_id = General.Get_Env("MASTOR_ID") # get line_user_id
base_size = ImagemapBaseSize(width=2500, height=1686)
imagemap_message = ImagemapMessage(
base_url="https://example.com/image",
alt_text="This is an imagemap",
base_size = base_size,
actions=[
MessageImagemapAction(
text="Hello",
area=ImagemapArea(x=0, y=0, width=2500, height=1686)
)
]
)
LineFunction().messaging_api.push_message(
PushMessageRequest(
to=mastor_id,
messages=[imagemap_message]
)
)
I try to use another way to writer and it is work now
I think I lost the MessageImagemapAction
Bad code
When I try the code I got the above: HTTP response body: {"message":"The request body has 1 error(s)","details":[{"message":"May not be empty","property":"messages[0].actions[0].text"}]}
and I still try to use replace the con_text from "text" to TextMessage(text="text"), and still not work