I'm using GetStream Feeds and stream_feed_flutter_core for building a instagram like app. I'm able to add activity to the feeds and even able to upload files but not able to upload images.
Steps I'm following for setting up the client and user:
final client = StreamFeedClient("apiKey", logLevel: Level.INFO);
- final currentUser = await client.setUser( User( id: user2Id, data: {"name": user1Name, "profile_image": user2Image}), Token(token_2));
Steps for uploading the images:
- Pick an image from gallery as XFile pickedFile
- uploadImage() async{ var imageUrl = await context.feedClient.images.upload(AttachmentFile(path: pickedFile.path)); }
Stream API response:
{
"detail":"token contains an invalid number of segments",
"status_code":403,
"code":17,
"exception":"NotAllowedException",
"duration":"0.00ms",
"more_info":"https://getstream.io/docs/api_error_responses"
}
are you able to
setUser
? what do you get thecontext.feedClient
In my case it is working fine