DEV Community

Gwen (Chen) Shapira
Gwen (Chen) Shapira

Posted on

What I learned about using and building public APIs

I've recently learned about the API Economy concept (A good primer and a contrarian view). After a bit of research, I was pretty amazed at how so much of the stuff you need to build your product already exists out there. I think everyone knows about Stripe, Twilio, Auth0.. but I was surprised to learn about Notarize, which has API for signing and notarizing documents, or FaunaDB which is a database with REST API, or background checks with API, etc, etc.

I learned to never implement anything without checking if someone else already provides that as a service via an API that I could integrate with. I found out that Postman (which also has a nice desktop app for testing APIs) hosts API world where tons of APIs are hosted and it lets you experiment with them online: https://www.postman.com/explore

I also learned about JAMStack, which is a community of FE engineers who are building entire websites without ever building a backend - simply by using other services and filling in the gaps with serverless functions (AWS Lambda and such).

It makes sense for pretty much every service to add public APIs and allow others to integrate. It opens up new use-cases and revenue streams, and for the most part we already have these APIs. OpenAPI makes it pretty easy to define the APIs, and then generate the web interfaces in your language, generate documentation, generate mocks, generate tests, etc... All those generated stuff is super important:

  • Developers will need the documentation to use your API and do the integrations.
  • Mocks will allow them to test the integration without loading your production application. Maybe even try a "mocked MVP" so you can get feedback before building your app.
  • Generated tests will let you continuously validate that you didn't break the APIs (since other developers will rely on their for their applications, it is critical not to break their applications - they won't come back and tell their friends).

https://swagger.io/ has great tools for OpenAPI.

I cover all this with a bunch of examples in a video:

I'm also working on a SaaS-in-a-Box backend service (hopefully with both great APIs and great integrations) to make life simpler for SaaS developers. If you are willing to give me feedback on the MVP, mind sharing your email with me in this form? I promise it won't be used for marketing, I'll just personally connect with you to discuss https://forms.gle/8tW73MwEWdWu4rB27.

Top comments (1)

Collapse
 
gklijs profile image
Gerard Klijs

OpenAPI is great indeed. Somewhere we also used it to work API first for both external and internal API's.