Skip to content

Document GET requests also supported #39

@dolfs

Description

@dolfs

When experimenting with the varserver I did not fully read the documentation and, on autopilot, used GET requests to get things done. I see the example code uses POST requests, as does cgi. Coming from a lot of REST experience, I would expect to retrieve values using GET and change values using POST or PUT. The documentation does not suggest that varserver is a REST API, so this is all minor.

pypvs is just a wrapper (but also uses POST exclusively), and as such, hides this detail.

What I did find, using GET requests, where the parameters are encoded as query variables is that there is an issue with properly encoded parameter values.

Many of the parameter values will need slashes in them, and they are properly encoded us %2F, but if/when you do that, the API rejects the request. If you leave the slashes alone, everything will work.

So, I would suggest:

  • Fix the code (in varserver) to properly decode percent encoded query parameters
  • Document the GET requests can also be used

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