airtasker/spot

Allow to add a dot in query parameters

Thodin3 opened this issue · 2 comments

Dot not allowed in query parameters

Like it's possible to add a dot in HTTP GET parameters, it's allowed in OASv3.
But currently not possible in Spot like:

        {
          name: "postal.code",
          in: "query",
          required: false
        }

Allow it in Query parameters
The extractQueryParamName regex should be extended to .

Additional context
In TS contracts, it will be quoted parameter names :

class EndpointWithQueryParams {
  @request
  request(
    @queryParams
    queryParams: {
      country: String;
      "postal.code"?: String;
    }
  ) {}

@lfportal I can do the pull request for this one.