In the follwing, it is explained, how to use Apodini when building a swift web app and automatically creating the corresponding client SDK with OpenAPISpecification 3.0. It's acutally a 10-step plan:
- Create a swift project with Apodini as dependency
- Implement game logic
- Define Apodini handlers, i.e., endpoints of the web app
- Compose web app using Apodini (sub-)components
- Enrich endpoints with OAS modifiers.
- Add descriptions to handlers
- Add tags to handlers
- Configure web app
- HTTP: set URL
- OAS: format, OAS endpoint, Swagger-UI endpoint
- Run Apodini backend
- Inspect generated OAS
- Explore web app via Swagger-UI
- Run shell script to generate client SDK
- Work on FE and finetune style, can only be a matter of weeks…
- Start using the web app
Imagine the following example:
You want to build a web application for your favorite card game.
Certainly, we want an endpoint returning a game when given a specific identifier as path parameter, i.e., something like a “getGame” endpoint.
This example is used thoughout the following step-by-step image manual. The getGame
endpoint is always highlighted with a red rectangle.
next: Step 1 |
---|