Microservice API Analysis for Reporting
Work in Progress
This is a work in progress and we will remove this info box when complete.
The OpenLMIS reporting architecture requires an understanding of the service APIs in order to better understand which components of the system should be considered for ingestion. This document is a large scope based on the OpenLMIS v3.3 architecture and includes identifying each microservice, taking a snapshot of the API endpoint, identifying if data changes over time and identifying whether this endpoint needs to be considered for reporting ingestion. Further documentation is available on the components page.
What's included:
All endpoints that have a GET method
What's not included:
Auth Service - The auth service focuses on authenticating users. The reporting stack does not have a clear use case for this information.
Reference UI - The reference UI component does not have endpoints that can be consumed.
Report Service - The report service primarily focuses on building reports for consumption within the Reference UI. There is no clear use case for this information.
Notification Service - The notification service only presents an interface for other microservices to send notifications to users. There is no clear use case for this information.
Endpoints with POST, PUT or DELETE methods will not be included because the reporting stack only consumes data.
Fulfillment Service provides RESTful API endpoints for orders, shipments, and proofs of delivery. It supports fulfillment within OpenLMIS as well as external fulfillment using external ERP warehouse systems.
Resource | Description | Frequency | Consider | Notes |
|---|---|---|---|---|
orderFileTemplates | Get the template of the order file | Rarely | No |
|
orderNumberConfigurations | Get the configuration for the order number | Rarely | No |
|
orders | Get an array of all orders. Minimal order details are presented | Frequently | Yes | This endpoint is used to get a list of orders so we can query each order by id |
orders/requestingFacilities | Return UUIDs of all the available, distinct requesting facilities. | Rarely | No | This may be interesting for streamlined reporting, but if we are consuming each order, we can derive this list in the reporting system. |
orders/{id} | Get chosen order with details | Frequently | Yes | This Entity changes over time as orders change. |
orders/{id}/export | Export order to CSV | Frequently | No |
|
orders/{id}/retry | Manually retry for transferring order file via FTP after updating or checking the FTP transfer properties. | Rarely | No |
|
orders/{id}/print | Print all order line items from an order to a csv or pdf file. | Frequently | No |
|
proofOfDeliveryTemplates | Download proof of delivery report template with jrxml format. | Rarely | No |
|
proofsOfDelivery | Get an array of proofs of delivery. | Frequently | Yes | This endpoint is used to get a list of all proofs of delivery so we can query each proof of delivery by id |
proofsOfDelivery/{id} | Get chosen proof of delivery | Frequently | Yes | This Entity changes over time as proofsOfDelivery change. |
proofsOfDelivery/{id}/auditLog | Returns all or part of the resource's audit log | Frequently | Yes | This will be valuable for seeing how a proof of delivery has changed over time. |
proofsOfDelivery/{id}/print | Print proof of delivery to a pdf file. | Rarely | No |
|
reports/templates/fulfillment | Get an array of all fulfillment report templates | Rarely | Yes | This gets a list of all report templates. This may be useful if we need to display any information to users in a similar way. |
reports/templates/fulfillment/{id} | Get a specific report template | Rarely | Yes |
|
shipmentDrafts | Get an array of all shipment drafts, which are shipment files that have not been submitted. | Frequently | No |
|
shipmentDrafts/{id} | Get a specific shipment draft | Frequently | No |
|
shipments | Get an array of all shipments | Frequently | Yes | This endpoint is used to get a list of all shipments so we can query each shipment by id |
shipments/{id} | Get a specific shipment | Frequently | Yes | This Entity changes over time as shipments change. |
transferProperties/search | Find transfer properties by facility id (transferProperties are used for FTP and local settings that help the system interact with a third party fulfillment service) | Rarely | No |
|
transferProperties/{id} | Get a specific transfer property | Rarely | No |
|