0

エラーは返ってきませんが、YouTube上に表示されません。

なお、レスポンスとしては2022-06-21T22:45:25.332 の様なタイムスタンプが返ってきます。

現在のコード

import datetime
import requests

seq = 0
while True:
    word = "テスト"
    content = datetime.datetime.utcnow().strftime('%Y-%m-%dT%H:%M:%S.%f')[:-3] + ' region:reg1#cue1\n' + word + '\n'
    print(post_fields)
    seq = seq + 1
    url = "http://upload.youtube.com/closedcaption?cid=(cid)&seq="+str(seq)
    r = requests.post(url, data=content.encode('utf-8'), headers={"content-type": "text/plain"})
    print(r.text)
0

0

この質問に回答するには、ログインする必要があります。

のタグが付いた他の質問を参照する。