Skip to content

Support multipart/form-data request bodies #52

Description

@danielbowne

Problem

Emberfall currently supports text and json body types for requests, but there is no way to send multipart/form-data payloads. This limits smoke testing for APIs that accept file uploads via multipart (e.g., resume processors, document ingest endpoints, image upload APIs).

Proposed Solution

Add a multipart option to the body configuration that supports key-value form fields:

tests:
  - url: http://localhost:3000/api/upload
    method: POST
    body:
      multipart:
        fields:
          name: "document.pdf"
          category: "resume"
    expect:
      status: 202

This would set Content-Type: multipart/form-data with the appropriate boundary and encode the fields as form parts.

Use Case

Testing API endpoints that accept multipart form submissions with metadata fields (without file attachments -- see separate issue for file support).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions