Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multipart/form-data boundary property is not supported #14

Open
Alexandre-Fernandez opened this issue May 2, 2023 · 1 comment
Open
Labels

Comments

@Alexandre-Fernandez
Copy link

Alexandre-Fernandez commented May 2, 2023

The content-type "multipart/form-data; boundary=--------------------------580848852863824060235695" is not supported. 
Supported MIME types are "application/json", "application/x-json", "text/xml", "application/xml", "application/x-xml", "application/x-www-form-urlencoded", "multipart/form-data".

I get this error when trying to post a file with VSCode's thunder client.

image

This is the DTO :

final class FormDataDto implements InputInterface
{
    #[Assert\NotBlank]
    private string $id;

    private string $type; 

    #[Assert\File(
        maxSize: '5120k',
        extensions: ['pdf'],
        extensionsMessage: 'Please upload a valid PDF',
    )]
    private ?File $attachement = null;
    
    // getters and setters ...
}
@Alexandre-Fernandez Alexandre-Fernandez changed the title multipart/form-data boundary property is not supported multipart/form-data boundary property is not supported May 4, 2023
@sfmok
Copy link
Owner

sfmok commented Mar 18, 2024

Thanks for reporting. Unfortunately, that content type is not supported yet due to file upload. Feel free to push a PR to support that type.

@sfmok sfmok added the On hold label Mar 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants