nimblehq / nimble-survey-web

Nimble Survey API for Mobile Challenge and Certification
0 stars 3 forks source link

Add Prism to create mocking server #88

Closed suho closed 1 year ago

suho commented 1 year ago

What happened 👀

Add service prism to docker-compose

Insight 📝

We are going to use https://github.com/stoplightio/prism to support mocking server in a different port (4010)

Proof Of Work 📹

Screenshot 2023-06-08 at 16 53 15
olivierobert commented 1 year ago

Why introducing Stoplight when the team already started using Mockoon?

suho commented 1 year ago

Why introducing Stoplight when the team already started using Mockoon?

@olivierobert That's really a good question. Technically, Mockoon is more for local running and for the mobile side. Each mobile member needs to set up to run Mockoon by themself.

When working more on the API side and doing some research about OpenAPI, I figured out that the web team could use https://github.com/stoplightio/prism to create a mock server (deploy to Heroku, or with another port of the staging sever) that could be used for all members in the squad.

If we add https://github.com/stoplightio/prism to all our web templates, we can easily deploy a mock server with an openapi.yml file. So another scenario will be added to this page (e.g., The API is NOT developed currently but has a configured mock server).

What do you think?

olivierobert commented 1 year ago

@suho I recommend you to work with @minhnimble on this. We should aim to limit the number of tools used by the team. If Stoplight can do the same or better than Mockoon then we need to pick up one over the other.

suho commented 1 year ago

@olivierobert After discussing with @minhnimble, prism could do the same and even better than Mockoon (e.g., online mock server, dynamic responses) and can do the same with Postman Mock Server without any issues. I will prepare more docs for this and bring prism to Compass.