|
4 | 4 | summary: The public Globalping API.
|
5 | 5 | description: |
|
6 | 6 | Monitor, debug, and benchmark your internet infrastructure from a globally distributed network of probes.
|
7 |
| - |
| 7 | +
|
8 | 8 | ## Client guidelines
|
9 |
| - |
| 9 | +
|
10 | 10 | If you implement an application interacting with the API, please consider the "client guidelines"
|
11 | 11 | section of each endpoint below to provide the best UX and reduce the chance of your application breaking in the future.
|
12 |
| - |
| 12 | +
|
13 | 13 | ### General guidelines for non-browser based apps:
|
14 | 14 |
|
15 | 15 | - Set a `User-Agent` header. The recommended format and approach is [as here](https://github.com/jsdelivr/data.jsdelivr.com/blob/60c5154d26c403ba9dd403a8ddc5e42a31931f0d/config/default.js#L9).
|
16 | 16 | - Set an `Accept-Encoding` header with a value of either `br` (preferred) or `gzip`, depending on what your client can support. The compression has a significant impact on the response size.
|
17 | 17 | - When requesting the measurement status, implement ETag-based client-side caching using the `ETag`/`If-None-Match` headers.
|
18 |
| - |
| 18 | +
|
19 | 19 | ## Endpoints
|
20 |
| - |
| 20 | +
|
21 | 21 | https://api.globalping.io/v1/
|
22 | 22 | version: 1.0.0
|
23 | 23 | termsOfService: https://github.com/jsdelivr/globalping
|
24 | 24 | contact:
|
25 | 25 | url: https://github.com/jsdelivr/globalping/issues
|
26 |
| - email: dak@prospectone.io |
| 26 | + email: d@jsdelivr.com |
27 | 27 | license:
|
28 | 28 | name: Open Software License 3.0
|
29 | 29 | identifier: OSL-3.0
|
|
42 | 42 | Creates a new measurement with the configured parameters.
|
43 | 43 | The measurement runs asynchronously and its current state can be retrieved
|
44 | 44 | at the URL returned in the `Location` header.
|
45 |
| - |
| 45 | +
|
46 | 46 | ### Client guidelines
|
47 | 47 |
|
48 | 48 | - Set the `inProgressUpdates` option to `true` if the application is running in interactive mode so that the user sees the results right away.
|
|
82 | 82 | Retrieves data of an existing measurement.
|
83 | 83 | A link to this endpoint is returned in the `Location` response header when creating the measurement.
|
84 | 84 | The measurement is typically available for up to 7 days after creation.
|
85 |
| - |
| 85 | +
|
86 | 86 | ### Client guidelines
|
87 |
| - |
| 87 | +
|
88 | 88 | - Use the following algorithm for measurement result pooling:
|
89 | 89 | 1. Request the measurement status.
|
90 | 90 | 2. If the status is `in-progress`, wait 500 ms and repeat from step 1. Note that it is important to wait 500 ms *after* receiving the response, instead of simply using an "every 500 ms" interval. For large measurements, the request itself may take a few hundred milliseconds to complete.
|
|
0 commit comments