youtube.liveChatMessages().insert
返回400
错误代码,原因unexpectedPart
。
这是在 Google API 浏览器上收到的相同响应。
def send_message(youtube):
send_message_response = youtube.liveChatMessages().insert (
part = "snippet",
body = dict (
snippet = dict(
liveChatId = result_chatId,
type = "textMessageEvent",
textMessageDetails = dict(
messageText = "hello world"
)
),
authorDetails = dict(
displayName = "blabla"
)
)
).execute()
print "%s" % (send_message_response)
收到错误响应。