Defining the calculation API

Note

Before you start this guide read the Calculation API concept documentation.

../_images/pmt-api-variables.png
  1. Open the project and select the “Calculation API” menu entry on the left-hand side.
  2. Click “New Calculation Group” to name and create a calculation group. The id is generated from the name of the calculation group by default. It can be changed later when needed.
  3. If you are using modules select the modules to be imported in the calculation group.
  4. Click “New Calculation” to name and create a calculation. The id is generated from the name of the calculation by default. It can be changed later when needed.
  5. Select input and output variables by clicking “Select” in the boxes on top.
  6. Assign id-s to the variables that will be used by programs calling the API.
  7. Assign mathematical domains to your variables. These will be used for validating inputs and making outputs predictable.
  8. Select the “Documentation” tab and document the calculation. From the calculation documentations we will generate a complete API documentation when you build your project. It can be shared with application developers to help them call your API. See the documentation language reference for details.