【问题标题】:Rate a YouTube video using API v3使用 API v3 为 YouTube 视频评分
【发布时间】:2015-03-06 08:17:37
【问题描述】:

如何使用 YouTube API v3 在 iOS 中评价(不喜欢/喜欢)其他人在 YouTube 上的视频?

我从the documentation 不明白该怎么做。

【问题讨论】:

    标签: ios youtube-data-api


    【解决方案1】:

    我自己找到了答案,

    -(void) rateVideo
    {
        GTLQueryYouTube *query = [GTLQueryYouTube queryForVideosRateWithIdentifier:videoId rating:@"dislike"]; // rating can be anything "like" or "dislike" etc
    
        [_youTubeService executeQuery:query completionHandler:^(GTLServiceTicket *ticket, GTLYouTubeVideoRating *rate, NSError *error) {
            NSLog(@"err : %@",error);
        }];
    }
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2018-03-14
      • 2015-06-16
      • 2016-09-01
      • 2015-03-03
      • 1970-01-01
      • 2013-11-12
      • 2017-05-09
      • 2018-06-28
      相关资源
      最近更新 更多