Add function to call API method

- Add get_api and post_api to call custom API (RPC) method
- This can be used together with Unittest to provide functionality to test Custom API (RPC) methods