Closed brylie closed 5 years ago
I am having difficulty getting past the auth stage. How should we set up or disable authentication for this mock-server?
You could use some kind of simple pseudo-authentication. Say, you have endpoints that require a "login token" for the user to be passed as a header. Your mock server could then still require that but it just checks it against a hard-coded valid token, e.g., "X-MaaS-User-Token: test-token".
Here is the security configuration for the Bookings API:
So, it looks like you recommend using this approach? https://connexion.readthedocs.io/en/latest/security.html#apikey-authentication
Ah, I just removed the security definition, since this is a mock-api to serve as a reference.
@nighthawk I would like to keep the scope of this PR relatively small, so we can work in parallel on mock-data functions. Would you mind reviewing and, if permissible, signing-off on this PR?
We agreed to provide a proof-of-concept server to provide mock data that can be used by developers. This PR is the initial effort to set up the mock server.