Goophr Concierge is the user-facing component, and it has two responsibilities—to index new documents and to return query results. Informally, we can define the API as follows:
- /api/feeder: This is the API endpoint to upload documents by user
- The POST request adds new documents if the payload is complete and correct
- /api/query: The user searches for phrases or terms that are queried against this API endpoint
- The POST request contains payload with search terms, and a list of documents will be returned
This simple API description is for our understanding. Now let's look at how this would be formulated using the OpenAPI specification:
# openapi/concierge.yamlopenapi: 3.0.0 servers: - url: /api info: title: ...