awslabs / amplify-video

An open source Category Plugin for the AWS Amplify-CLI that makes it easy to deploy live and file based streaming video services and integrate them into your Amplify applications.
https://www.npmjs.com/package/amplify-category-video
Apache License 2.0
267 stars 56 forks source link

How to upload a video to the "Input" bucket via swift in my iOS project #178

Closed babylon2017 closed 3 years ago

babylon2017 commented 3 years ago

Note: If your question is regarding the AWS Amplify Console service, please log it in the official AWS Amplify Console forum

Which Category is your question related to? AWS Amplify Video

What AWS Services are you utilizing? AWS Amplify Video

Provide additional details e.g. code snippets I have an IOS project using Amplify as a backend. I have also incorporated Amplify Video in the hope of supporting video-on-demand. After adding Amplify Video to the project, an "Input" and "Output" bucket is generated. These appear outside of my project environment when visualised via the Amplify Console. They can only be accessed via navigating to AWS S3 console. My questions is, how do I upload my videos via swift to the "Input" bucket using Amplify (or don't I)?

The code I have below uploads the video to the S3 bucket within the project environment (and not to the input bucket) let key = "myKey" Amplify.Storage.uploadData(key: key, data: vidData) { (progress) in print(progress.fractionCompleted) } resultListener: { (result) in switch result{ case .success(_ ): print("upload success!") case .failure(let error): print(error.errorDescription) } }

AakashPat commented 3 years ago

Facing a similar question!

wizage commented 3 years ago

Talking with the team. that does Amplify iOS will follow up when I get an answer

wizage commented 3 years ago

After reaching out and talking with the Amplify iOS team they asked you to add a :+1: to this ticket:

https://github.com/aws-amplify/amplify-ios/issues/916

wizage commented 3 years ago

Closing due to inactivity