Skip to content

dataFormat and compression work as query parameters for POST but are not declared in OpenAPI #1834

Description

@corneliusroemer

My Claude tripped over ?limit=1 not being accepted by POST requests while ?dataFormat and ?compression are.

OpenAPI documents no accepted query params for POST. So to be consistent the 2 existing ones (dataFormat and compression) should be documented or not accepted.

Repro:

dataFormat is read and honored

# body {} only, dataFormat passed in the query string on a POST: honoured
curl -sD - -o /dev/null -X POST 'https://lapis.pathoplexus.org/mpox/sample/aggregated?compression=gzip' \
     -H 'Content-Type: application/json' -d '{}' | grep -i content-type
# -> content-type: application/gzip

clade isn't:

# filter in the query string on POST: dropped, whole-database count, HTTP 200
curl -s -X POST 'https://lapis.pathoplexus.org/mpox/sample/aggregated?clade=Ia' \
     -H 'Content-Type: application/json' -d '{}'
# -> {"data":[{"count":17395}], ...}

# same filter in the body
curl -s -X POST 'https://lapis.pathoplexus.org/mpox/sample/aggregated' \
     -H 'Content-Type: application/json' -d '{"clade":"Ia"}'
# -> {"data":[{"count":2088}], ...}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions