Using Wildcards - Mock Server Matching Algorithm

I’m trying to follow the instructions for using wildcards in Mock Server Example URLs as described in the documentation here, but I’m not having any luck:
https://learning.postman.com/docs/postman/mock-servers/matching-algorithm/

I haven’t created an environment variable called “wildcard”.

Example Request URL: {{url}}//agreements/{{wildcard}}/documents
Request URL: {{url}}//agreements/123/documents

Response:
{
“error”: {
“name”: “mockRequestNotFoundError”,
“message”: “Double check your method and the request path and try again.”,
“header”: “No matching requests”
}
}

Please tell me if I’m going about this correctly or not. Thank you.

Hey @maryfatimma,

Welcome to the community!! :rocket:

There was a discussion yesterday in a thread about how certain things can be matched using wildcards.

Might be worth taking a look through this thread and see if it helps, feel free to ping me if you have any questions. :grin:

Hi @danny-dainton,

Thank you very much! My problem was the double slashes in the URLs :woman_facepalming:

{{url}}**//**agreements/{{wildcard}}/documents

1 Like