Serving Multiple OpenAPI Documents Test Error

Hello -
I’m trying to get the Serving Multiple OpenAPI Documents demo (https://meta.stoplight.io/docs/prism/docs/guides/multiple-documents.md ) working.

Running example curl requests result with this response:

{“type”:“https://stoplight.io/prism/errors#NO_PATH_MATCHED_ERROR",“title”:"Route not resolved, no path matched”,“status”:404,“detail”:“The route /app_1/pets hasn’t been found in the specification file”}

Response is the same for both app_1 and app_2.
Those curl commands in the Testing the cluster section are missing the http:// prefix.
Any ideas?
Thanks!
Marin

Thanks for spotting that, and letting us know!

Can you confirm this is what you meant? https://github.com/stoplightio/prism/pull/1385

Sadly that’s not it. The http prefix was just a note I added, not the issue I was facing.

The problem is that the curl requests in Testing the cluster section are throwing this error:
{"type":"https://stoplight.io/prism/errors#NO_PATH_MATCHED_ERROR","title":"Route not resolved, no path matched","status":404,"detail":"The route /app_2/pets hasn't been found in the specification file"}

Ah, right, thanks Marin. I’ll get one of the Prism folks on this.

1 Like

The guide is indeed missing the strip prefix part. Here’s the updated one: https://github.com/stoplightio/prism/pull/1387

1 Like

Yep, it works now. Thank you.

@vncz @philsturgeon
Hey guys,

While further playing with this example, I tried mocking an API document that I have on my pc, but I keep getting this error:

prism_1_1 | [9:02:02 AM] › [CLI] … awaiting Starting Prism…
prism_1_1 | [9:02:03 AM] › [CLI] :heavy_multiplication_x: fatal Error opening file “/usr/src/prism/packages/cli/petstore.yaml”
prism_1_1 | ENOENT: no such file or directory, open ‘/usr/src/prism/packages/cli/petstore.yaml’

Could you help me figure out how to mock local API files inside the multiple OpenAPI Document example setup.

And also you forgot to add the strip prefix part to the 3rd api that is added at the end of the Adding More Documents section.

If you want to use documents that are on your local computer — you need to mount the files in the respective containers. You can find more informations on the docker compose file reference


I’ve fixed the documentation also!