Skip to content

Missing boundary in Content-Type when multipart/form-data #633

Closed
@AchrafAmil

Description

@AchrafAmil

Describe the bug

The interactive Prism console for upload endpoint doesn't seem to make the right call for endpoints with content-type multipart/form-data

Expected behavior

Expects the call made from the console to specify a boundary
(otherwise the server receiving the request fails with a legit java.io.IOException: Failed to parse multipart: Content-Type's boundary parameter is missing).

Current behavior

The request it makes when hitting the "send api request" seems malformatted.

Possible solution

Specify the boundary, e.g. content-type: multipart/form-data; boundary=------WebKitFormBoundaryF6sSRjfPR0gJB7xK

Steps to reproduce

  1. Go to https://docs.nabla.com/server/copilot-listen-from-file
  2. (you don't care about having a working api key or even about specifying correct values for the rest of the fields)
  3. Drag & drop a random file, and inspect the network request it makes.
  4. The request body is multi-part and has a boundary but it's not specified in the content-type header.

Screenshots

image

Untitled

Your Environment

  • Version used:
    "@asyncapi/generator": "^1.10.9",
    "@docusaurus/core": "^2.4.1",
    "@docusaurus/preset-classic": "^2.4.1",
    "@mdx-js/react": "^1.6.22",
    "clsx": "^1.1.1",
    "docusaurus-plugin-openapi-docs": "^2.0.0-beta.3",
    "docusaurus-theme-openapi-docs": "^2.0.0-beta.3",
    "prism-react-renderer": "^1.3.1",
    "react": "^18.2.0",
    "react-dom": "^18.2.0",
    "html-loader": "^4.2.0"
  • Environment name and version Chrome 117.0.5938.92 arm64
  • Operating System and version: macOS Ventura 13.3.1
  • Link to your project: docs.nabla.com

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingreviewing 👀Undergoing manual audit to determine if issue should still be active

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions