Back to Collection Items
; This example assumes the Chilkat API to have been previously unlocked.
; See Global Unlock Sample for sample code.
$oHttp = ObjCreate("Chilkat.Http")
Local $bSuccess
$oQueryParams = ObjCreate("Chilkat.JsonObject")
$oQueryParams.UpdateString("underlying","")
$oHttp.SetRequestHeader "Content-Type","application/json"
Local $oResp = $oHttp.QuickRequestParams("GET","https://domain.com/eapi/v1/index",$oQueryParams)
If ($oHttp.LastMethodSuccess = False) Then
ConsoleWrite($oHttp.LastErrorText & @CRLF)
Exit
EndIf
ConsoleWrite($oResp.StatusCode & @CRLF)
ConsoleWrite($oResp.BodyStr & @CRLF)
Curl Command
curl -G -d "underlying="
-H "Content-Type: application/json"
https://domain.com/eapi/v1/index
Postman Collection Item JSON
{
"name": "Symbol Price Ticker",
"request": {
"method": "GET",
"header": [
{
"key": "Content-Type",
"type": "text",
"value": "application/json"
}
],
"url": {
"raw": "{{url}}/eapi/v1/index?underlying=",
"host": [
"{{url}}"
],
"path": [
"eapi",
"v1",
"index"
],
"query": [
{
"key": "underlying",
"value": "",
"description": "Spot pair(Option contract underlying asset)"
}
]
},
"description": "Get spot index price for option underlying."
},
"response": [
]
}