Skip to content

v0.17.0

Choose a tag to compare

@github-actions github-actions released this 28 Oct 06:28
· 94 commits to main since this release

Form and multipart bodies, with file uploads.

Highlights

form: urlencoded bodies, encoded for you

An endpoint can send application/x-www-form-urlencoded with form. Names and values are encoded after placeholders are resolved, so a password with &, + or = is sent as written. A list repeats the field.

endpoints:
  token:
    method: POST
    path: /oauth/token
    params: { client_id:, client_secret: }
    form:
      grant_type: client_credentials
      client_id: ${client_id}
      client_secret: ${client_secret}

multipart: text fields and file uploads

multipart sends multipart/form-data: text fields, files (file, with optional filename and content_type), and lists, in the order written.

endpoints:
  upload_avatar:
    method: PUT
    path: /api/users/${id}/avatar
    auth: bearer
    params: { id:, avatar: }
    multipart:
      description: Profile picture
      avatar:
        file: ${avatar}
      tags: [profile, public]
steps:
  - call: upload_avatar
    with:
      id: ${userId}
      avatar: ../fixtures/avatar.png
    expect:
      status: 204
  • A relative file path is relative to the file tinyprobe was given: the workflow for run, the API file for call. A workflow runs the same from any directory.
  • Content-Type is set by tinyprobe. A Content-Type in the endpoint's own headers is an error, reported with its location.
  • Recorded requests (-v, ndjson, the VS Code extension) show each file as one line, (file ../fixtures/avatar.png, 79 B), instead of its bytes.
  • Under tinyprobe mcp, files must be inside the server's working directory.
  • inspect --json has form and multipart for each endpoint (new keys, protocol 1). tinyprobe schema describes the new keys, so the extension completes them with no update.

Imports by your AI

tinyprobe guide now translates Postman formdata and urlencoded, OpenAPI multipart/form-data and form bodies, Insomnia, Bruno, HAR form parameters, and curl -F and --data-urlencode, where it used to list them as not translated. Files go in tinyprobe/fixtures/. In the OpenAPI bench, Sonnet converted 11 operations of 11, the avatar upload included.

No breaking changes.

What's Changed

  • Add form and multipart bodies, with file uploads by @kikutano in #24

Full Changelog: v0.16.0...v0.17.0