-
Notifications
You must be signed in to change notification settings - Fork 143
Open
Description
As you can see I'm taking a direct stream model and passing it to the api with an updated deleted field.
Code calling update:
- (void)deleteButtonTapped:(id)sender {
UIButton *deleteButton = (UIButton*)sender;
NSInteger index = deleteButton.tag;
**KFStream *stream = self.streams[index];**
stream.deleted = YES;
[[KFAPIClient sharedClient] updateMetadataForStream:stream callbackBlock:^(KFStream *updatedStream, NSError *error) {
if (nil != error) {
NSLog(@"Error deleting video");
}
}];
}
outgoing jsonString:
{
"state" : null,
**"stream_id" : "ba50d609-6efb-46c3-9c44-628c01e134d5",**
"time_started" : "05\/13\/2016 17:44:48",
"kickflip_url" : "https:\/\/kickflip.io\/ba50d609-6efb-46c3-9c44-628c01e134d5",
"end_lat" : null,
"thumbnail_url" : "http:\/\/kick-us-east-1.s3.amazonaws.com\/voterockit\/gyoulcexzyje\/ba50d609-6efb-46c3-9c44-628c01e134d5\/thumb.jpg",
"deleted" : true,
"stream_url" : "https:\/\/d3mf59dq42lc44.cloudfront.net\/voterockit\/gyoulcexzyje\/ba50d609-6efb-46c3-9c44-628c01e134d5\/vod.m3u8",
"city" : null,
"start_lat" : null,
"stream_type" : null,
"end_lon" : null,
"time_finished" : "05\/13\/2016 17:44:52",
"user_username" : "gyoulcexzyje",
"start_lon" : null,
"country" : null
}
Error:
{success=false, reason=Not a valid stream. Make sure you supply a correct 'stream_id'., code=301}
Metadata
Metadata
Assignees
Labels
No labels