我在 iOS 应用程序中使用 YouTube API 2.0,我提出了这样的请求:
POST http://uploads.gdata.youtube.com/resumable/feeds/api/users/default/uploads
Authorization = "Bearer <acess_token>";
"Content-Length" = 516;
"Content-Type" = "application/atom+xml; charset=UTF-8";
"GData-Version" = 2;
Slug = "testVideo.mov";
"X-GData-Key" = "key=<api_key>";
与身体:
<?xml version="1.0"?>
<entry xmlns="http://www.w3.org/2005/Atom"
xmlns:media="http://search.yahoo.com/mrss/"
xmlns:yt="http://gdata.youtube.com/schemas/2007">
<media:group>
<media:title type="plain">My title</media:title>
<media:description type="plain">My description</media:description>
<media:category scheme="http://gdata.youtube.com/schemas/2007/categories.cat">Entertainment</media:category>
<media:keywords>mediawork</media:keywords>
</media:group>
</entry>
但是服务器响应出现错误 500,并且没有带有解释的 XML 正文。我应该怎么办?它在一个月前工作。