3 ms·
Yes, the tooling around OpenAPI spec is not great. However we've worked around it. We write most of our spec by hand. We thought it would be horrible but it's
by amne 3y ago
Yes, the tooling around OpenAPI spec is not great.
However we've worked around it. We write most of our spec by hand. We thought it would be horrible but it's not.
All our APIs accept and respond with JSON so the OpenAPI payloads are pretty much JSON schemas which means we can parse and load them up in our functional tests and automate the schema validation as part of a functional test suite. We catch a lot of unintended changes to API contract with this approach (customer is now customer_id because serializer decided so and stuff like that).
- ushakov 3y agoYou can also use your OpenAPI spec to generate tests for the API eg. with Step CI (https://stepci.com https://stepci.com): https://docs.stepci.com/import/openapi.html https://docs.stepci.com/import/openapi.html