All Questions
114
questions
0
votes
0
answers
15
views
How to Get File Type passed into multipart form-data with Multer When Uploading to S3 in Node.js?
I'm using Multer to handle file uploads in my Node.js application, and I'm uploading files to an S3 bucket. I need to get the type I pass into multi-part formdata before uploading. How can I achieve ...
0
votes
0
answers
26
views
How to unit test oversized files between multer and s3 with the v3 sdk?
I'm trying to test different scenarios for file uploads. Obviously, I don't want to actually upload to s3 so I'm mocking that using aws-sdk-client-mock. The scenario that I'm stuck on is testing the ...
1
vote
2
answers
53
views
Request to Express endpoint won't stop loading, even if I set response status (Multer and Express issues)
I'm on the process of making a filter based off evaluating a file's signature obtained via a file's buffer provided by Multer. I know Multer provides the MIME type, but I also have to check wether the ...
0
votes
2
answers
94
views
Property 'location' does not exist on type 'File'
I have changed multer to multer-s3. Changing in controllers for that. I will store "location" instead of "filename". But I am getting typescript error.
I am using Localstack for ...
0
votes
1
answer
76
views
Why won't my multer file uploads to AWS s3 work?
I was able to get my files to upload locally but am struggling to get it on AWS S3 Buckets. I'm receiving generic Cannot set headers after they are sent to the client errors after submitting a request....
0
votes
0
answers
102
views
I want to make a post request on postman to upload a file but I get this error: ErrorCaptureStackTrace(err); TypeError [ERR_INVALID_ARG_TYPE]:
I work with nodejs on a social network project I am on the part of the image upload for the profile photo and to do this I installed the multer module more precisely, version 2.0.0-rc.1.So I set up a ...
1
vote
0
answers
148
views
Uploading multiple files to aws-s3 using Multer (Object with an other array of objects inside)
I'm trying to upload multiple images to my aws-s3 using multer.
The problem I'm facing is I managed to upload the first backgroundImage which is outside the second array what I mean.
Here is my ...
1
vote
0
answers
317
views
Is there a way to stream back upload progress when using multer, multer-s3, and express?
My current implementation for letting a user upload a file to s3 through my server looks like this.
import express from 'express';
import "dotenv/config";
import { S3Client } from '@aws-sdk/...
1
vote
0
answers
278
views
File does not uploads to S3 using multer S3 if filename is absent in request object
I am using a third party service which pushes data to my expressjs endpoint to with a file. I have used multer and multer S3 to upload the file on S3 bucket and it works well when I try using postman.
...
0
votes
1
answer
386
views
Nuxt3 multer-S3 send formData
I've been stuck for days now.
In Nuxt3, I am going to upload an image to aws bucket using multer S3 as formdata.
However, there is no operation in the code below.
Can you tell me what I missed?
The ...
1
vote
0
answers
183
views
Why am I getting this error? CredentialsError: Missing credentials in config, if using AWS_CONFIG_FILE, set AWS_SDK_LOAD_CONFIG=1
I have built an app in Nodejs which uploads file to the DigitalOcean Spaces. I am using multer for the same. When I run it locally on my device, it successfully uploads on DigitalOcean but when I try ...
1
vote
1
answer
548
views
how to check if the request have contains file
I'm trying to create a route that save the user information along with the image and the route working with the file but in this case the image is a optional one. without the file in the request its ...
1
vote
0
answers
117
views
How to upload client files directly from express to minio ? ( nodejs )
im using express framework and i want to have a middleware to be able to upload files directly from clients to minio s3, how is that possible ?
i tried using multer-s3 package but it gave me error, ...
4
votes
1
answer
6k
views
Type 'S3' is missing the following properties from type 'S3Client': destroy, middlewareStack, sendts(2739)
I am getting this error while working on a node backend using typescript and this is the function for file upload to aws S3. Im new to using typescript so can anyone help me on this.
import AWS from &...
1
vote
1
answer
477
views
Mock Multer.single() Jest/Typescript
Trying to mock my 'FileService'.
FileService:
class FileService() {
public uploadToS3SingleFile = (bucketName: string, formDataKey: string) =>
multer({
storage: multerS3({
s3: ...