ballerinax/optirtc.public Ballerina library
This is a generated connector for Optirtc Public API v1.0 OpenAPI specification. The Opti Public API provides a simple, read-only interface to access metadata and the last 3 days of real-time data points of all metrics in an Opti Platform Account:
- Web developers can use the Public API to display real-time metrics from Opti facilities on their own websites - no backend database required.
- Systems integrators can use the Public API to pull data into their own GIS or ETL systems, for example, to connect real-time stormwater conditions to their existing asset management software.
- Analysts can use the Public API to pull data into their analysis scripts for repeated analysis. To learn about how Opti's data-driven products are enhancing community resilience to heavy rainfall across North America, see the Opti Home Page. OptiRTC provides simple examples of using open-source technologies to interact with the OptiRTC Public API. Find out more on our Github page.
Before using this connector in your Ballerina application, complete the following:
To use the Optirtc connector in your Ballerina application, update the .bal file as follows:
Step 1: Import connector
First, import the
ballerinax/optirtc.public module into the Ballerina project.
Step 2: Create a new connector instance
public:ApiKeysConfig with the API key obtained, and initialize the connector with it.
Step 3: Invoke connector operation
Now you can use the operations available within the connector. Note that they are in the form of remote operations.
Following is an example on how to get all DataStreams associated with the passed in key using the connector.
Get all DataStreams associated with the passed in key
bal runcommand to compile and run the Ballerina program.
Released date: 10 months ago
Ballerina version: 2201.4.1
GraalVM compatible: Yes
Current verison: 0