Speedchecker LinkedIn

Quick start API tutorial

Following steps will describe how to use our API to run a PING measurement from USA to www.google.com.

  1. Each API call needs to have an API key. To get a trial access to our API, please contact us to get your API key.

    Full documentation for the API can be found here.

  2. All of the methods which execute measurements on your behalf follow two-request API model.

    In Start method (e..g StartPingTest) you specify test parameters which control what should be tested and how. Also, within test parameters are object properties such as ProbeInfoProperties, which define how the output should look like. Probe API allows to return many properties of the test as well as the information about the probe itself. To save bandwidth we output only properties that you ask for. You can explicitly define what information you would like to get back by specifying list of properties as a list in ProbeInfoProperties (e.g. "ProbeInfoProperties": ["CountryCode", "ASN"]).

    Sample method call to start test

    HTTP request (POST)
    https://kong.speedcheckerapi.com:8443/ProbeAPIv2/StartPingTest
    HTTP headers
    Accept: application/json
    Content-Type: application/json
    apikey: {insert_your_api_key}
    HTTP body (JSON)
    { "testSettings": { "TestCount":1, "Sources":[ { "CountryCode":"US" } ], "Destinations":[ "www.google.com" ], "PingType": "ICMP", "ProbeInfoProperties":["CountryCode","ASN"] } }

    In the example above we have specified we want to run ICMP ping only from 1 probe located in the USA. That probe should make ICMP to www.google.com. We specified we want to know the ASN and countryCode (US) of the probe.

    Following screenshot shows constructed HTTP POST in ARC Chrome app (see more):

    ProbeAPI Start Ping Test screen

    If API call has been successful, you should get TestID in the API response.

    HTTP response
    { "StartPingTestResult": {"Status": {"StatusCode": null,"StatusText": null},"TestID": "d1445ae3-d668-40b6-93bb-cd066f220d02"} }
  3. You can now call a GetPingResults method to retrieve results of your measurements. You will need to pass your API key as well as TestID.

    If you call the GetPingResults too early, API response status code and text will explain you may need to wait. If you request multiple probes for your measurement, it is possible some of them may already tested and sent back the results to the API. In such a case we will indicate that partial results are available, in case you would want to use them before whole test is completed.

    Sample method to retrieve test result

    HTTP request (GET)
    https://kong.speedcheckerapi.com:8443/ProbeAPIv2/GetPingResults?apikey={INSERT_API_KEY_HERE}&testID={INSERT_ID_FROM_START_CALL}

    Since GetResults methods are called using GET, it is easy to retrieve results also within your web browser by navigating to correct URL incl. apikey and testID which can be specified also in the querystring.