How can i get multiple query params to be recogniz...
# help
t
How can i get multiple query params to be recognized?
I have two mappings, one that is meant to map on
text=json
and the other thats meant to match on
text=json&sortBy=default
when i try pinging the second one, i get the response that's intended for the first
First mapping:
Copy code
{
  "request": {
    "method": "GET",
    "urlPath": "/v2/foo",
    "queryParameters": {
      "text": {
        "equalTo": "json"
      }
    }
  },
  "response": {
    "status": 200,
    "bodyFileName": "responseOne.json",
    "headers": {
      "Content-Type": "application/json"
    }
  }
}
second mapping:
Copy code
{
  "request": {
    "method": "GET",
    "urlPath": "/v2/foo",
    "queryParameters": {
      "text": {
        "equalTo": "json"
      },
      "sort": {
        "equalTo": "default"
      }
    }
  },
  "response": {
    "status": 200,
    "bodyFileName": "responseTwo.json",
    "headers": {
      "Content-Type": "application/json"
    }
  }
}
b
Hey @Tayvon Wright, can you try giving the one with two query parameters higher priority? https://wiremock.org/docs/stubbing/#stub-priority