import { uploadFileToS3 } from "@intuned/browser";
export default async function handler(params, page, context){
// Basic S3 configuration
const s3Config: S3Configs = {
bucket: "my-app-uploads",
region: "us-east-1",
accessKeyId: "accessKeyId",
secretAccessKey: "SecretAccessKeyId"
};
// Use with file upload
const attachment = await uploadFileToS3({
file: myFile,
configs: s3Config
});
// Use with download and upload operations
const uploadedFile = await saveFileToS3({
page,
trigger: downloadUrl,
configs: s3Config
});
}