HOWTO: Writing API Clients - ibmcb/cbtool GitHub Wiki
Write Client code against the tool's API
This toolkit provides API for client programming in 3 different languages using XML-RPC to be used to direct benchmarks and algorithms against the API for maximum flexibility.
Additionally, these bindings also provide accessor methods for retrieving data from the mongodb database which the tool uses to store monitoring data.
Typically, upon starting up the tool, an "API Service" (xmlrpc server) is started on port 7070.
In order to use it, you would choose a language:
- Python: from import api_service_client import *
- Java: import api.*;
- Ruby: require 'api_service_client'
- C++: #include "apl_service_client.hpp";
API Client Examples in each language:
- Python: clients/provision_vm.py, clients/provision_application.py
- Java: clients/ProvisionVM.java, clients/ProvisionAPP.java
- Ruby: clients/provision_vm.rb, clients/provision_application.rb
- C++: clients/provision_vm.cpp, clients/provision_application.cpp, clients/list_regions.cpp
These examples are fairily self-explanatory. If you help or would like bindings written in a new language, don't hesitate to contact us and we'll try to accomodate you.