Usage ***** The Bleem Cube API is Web based API, or so-called REST API. Basically user will get a JSON style responses when sending a JSON-style inquiry. All APIs can be called through POST method at this stage, no other methods are available. ======== Endpoint ======== Bleem Cube API has the unique endpoint to access: http://cube.bleemcube.com/ ===== Token ===== Users are required the unique authentication token to access API. User may request their token through email info@bleemsys.com . When accessing API, token should be passed as a HTTP authorization header. The example python code is given in the section below. ========= Call APIs ========= Considering the easy use of the API, the Bleem Cube API currently only can be reached through POST method, no other method available. User may access through any programming languages, as demonstrated below. **Python 3 example** .. code-block:: python import requests, json # Endpoint url cube_url = "http://cube.bleemcube.com" # USer token Token = "f3aa3c11-2817-4a73-993c-db9a62a0ada7" # Body data section includes all information and data for calculation. data = { "Lattice": ["FCCubic"], "Profile": ["C"], "Material": ["Inconel_718"], "cmd" : ["invE_BC"], "TargetE" : [2.21345E+08], "x_lb": [0.004], "x_ub": [0.005], "y_lb": [0.004], "y_ub": [0.005], "z_lb": [0.004], "z_ub": [0.005], "Thk_lb":[0.00001], "Thk_ub":[0.000043] } # connects to API header = {"x-api-key":Token} r = requests.post(cube_url, data = json.dumps(data), headers=header) # convert returned bytes data to string responses = (r.content.decode("utf-8")).replace("\'","\"") # then convert string to dict re = json.loads(temp) print(re) **curl example** User can access to the APIs through the commands line below on Windows OS. .. code-block:: console curl -X POST http://cube.bleemcube.com -H "x-api-key:f3aa3c11-2817-4a73-993c-db9a62a0ada7" -H "Content-Type:application\/json" -d "{\"cmd\": [\"invE\"], \"Profile\": [\"C\"], \"Lattice\": [\"BCStarTet\"], \"Material\": [\"Ti64\"], \"TargetE\": [\"20E+09\"]}"