Skip to content
Ask Questions

Request Bodies

piespector currently supports these request body types:

  • None
  • Form-Data
  • x-www-form-urlencoded
  • Raw
  • GraphQL
  • Binary

No request body is sent.

Use key/value rows in the Body section.

Supported interaction:

  • j / k to move rows
  • H / L to move between key and value
  • e / Enter to edit
  • a to add a row
  • space to enable or disable a row
  • d to delete a row

Uses the same row-based interaction as Form-Data.

Values are URL-encoded when the request is sent.

Raw supports these subtypes:

  • Text
  • JSON
  • XML
  • HTML
  • JavaScript

Raw is edited from two rows in the Body section:

  • Body Type
  • Raw Format

The actual text then opens in the full text editor.

GraphQL is a dedicated body type with its own editor mode.

The current behavior sends the editor content as a raw GraphQL document with the GraphQL content type.

Binary uses a file path instead of a large text body.

The body field is path-oriented:

  • it edits a filesystem path inline
  • Tab completes matching paths
  • repeated Tab cycles matching files and folders

When sent, piespector reads the file bytes from that path. Relative paths resolve from the current working directory.

piespector validates body text before sending when the selected subtype or effective content type implies a structured format.

  • JSON
  • XML
  • HTML
  • JavaScript
  • GraphQL

Validation is intended to catch structural mistakes before the request goes out.

If you do not set an explicit Content-Type header, piespector infers one from the body:

  • Raw / JSON: application/json
  • Raw / XML: application/xml
  • Raw / HTML: text/html
  • Raw / JavaScript: application/javascript
  • Raw / Text: text/plain
  • GraphQL: application/graphql
  • Binary: application/octet-stream
  • Form-Data: multipart/form-data; boundary=...
  • x-www-form-urlencoded: application/x-www-form-urlencoded

If you add an explicit Content-Type header, that explicit header wins. The inferred auto header can also be disabled from Headers.

Syntax highlighting is available in previews and editors for:

  • JSON
  • XML
  • HTML
  • JavaScript
  • GraphQL

Body editing depends on the active body type:

  • row-based for Form-Data and x-www-form-urlencoded
  • full text editor for raw text-heavy bodies and GraphQL
  • inline path editing for Binary

GET and HEAD requests do not send a body, even if body fields are populated in the editor.