@KZ400 (Shoot You)

Are you sure you want to delete the question?

If your question is resolved, you may close it.

Leaving a resolved question undeleted may help others!

We hope you find it useful!

PythonでLineNotifyを使ったファイルの中の最新の画像の送信の方法

pythonでLine Notifyを使った画像の送信方法

ファイルの中で更新日付が最も新しい画像をLine Notifyで送信する方法を教えてくれい

プログラム

def main():
    message = format("画像を送信します")
    payload = {"message" : message}
    files = {"imageFile": open("画像のパス", "rb")}
    r = requests.post(url ,headers = headers ,params=payload, files=files)

該当するソースコード

open("画像のパス", "rb")}

自分で思ったこと

送信に必要なurlやtoken,headersは別場所に書いています。(qiitaに載せてない)
おそらくだけど、自分はopen()の中身を変えたらいいと思っている。ネットで色々調べたけど見つからなかった。python初心者なので詳しく知りたい!

0 likes

No Answers yet.

Your answer might help someone💌