Clarus Microservices
Getting Started Guide
- Microservices provide easy to use cloud-hosted analytics
- You can try these in the API Reference Page
- Then use from the language of your choice (Python, Perl, R, Julia, …)
1. Go to the API Reference Page and Login
With your email and password.
Then use the vertical menu on the left to browse the available microservices.
2. Parameter Descriptions and Try it now
Each microservice is documented for you to understand the functionality and the parameters available.
Advanced parameters can be selected once you are logged in.
Code snippets are provided in different languages for you to browse and copy.
Python code snippets provide a Try it now button to run the code within the browser.
You can also edit the code in-place and re-run.
The Form(POST) also provides a form to capture parameter inputs and submit.
3. Sandbox
A top-level menu provides access to a Sandbox for more advanced python examples.
This provides a secure hosted python environment purely in the browser.
You can view and use sample Data files in a variety of formats e.g. CRIF, FpML, LCH, CME, etc.
You can also upload your own data files and code examples to run in the sandbox.
4. Margin for CME or LCH
You will not be able to use Margin models for CME or LCH. We first need to validate that your firm is a clearing member or client clears at one or both of these. Please email us with your details to request this.
5. API Keys
When you are ready to move to your desktop, you will first need to get an API Key and Secret.
Use the top-right user menu and select the Manage API Keys option
Then use the button to Create a new API Key and copy and paste this and the Secret for future use. Please note this is a one-time operation, so if you lose the Secret, you will need to create a new Key.
We will authenticate against this API Key, so it is important that you keep it secure as it carry’s specific privileges as to which services are available. You should not share your API key with others.
6. Python Module
We provide a Clarus package for python, which you can install using “pip install clarus”.
Then in your python module, insert your API key and Secret that you obtained in step 5.
import clarusclarus.ApiConfig.api_key = "your key"clarus.ApiConfig.api_secret = "your secretclarus.ApiConfig.resource_path= 'your folder with test data' # if you use clarus.read()
7. Read Our Blogs
We regularly write blogs on Microservices and suggest you read the following:
All our current blogs on this topic can be accessed using the category: Microservices.
8. Need Help or Questions?
Please email us at [email protected]