diff --git a/docs/index.html b/docs/index.html index b601b2d..9930df6 100644 --- a/docs/index.html +++ b/docs/index.html @@ -37,8 +37,8 @@
You must have an account before you can access the API. This requirement is in
+You can integrate real time and historic moment data into your own project. To get started, you'll need to request an API key. This is unique to your project and should not be shared.
+All requests should be directed towards the following domain. Do not use the endpoints utilized by this web application, as they are rate limited and intended for this site only.
+https://bereal.devin.rest/
+
+ To use the API, you need to supply an API key with each request. Please include the API key as a query parameter with the key name `api_key`, like so:
+https://bereal.devin.rest/v1/moments/latest?api_key=YOUR_API_KEY
+ Both endpoints accept the GET http method.
+ +This endpoint returns the most recent moments in each region with the following JSON format:
+
+
+{
+ "regions": {
+ "us-central": {
+ "id": "MIB0Amg220yP7m0Te-p9s",
+ "ts": "1677871105",
+ "utc": "2023-03-03 19:18:25"
+ },
+ "europe-west": {
+ "id": "CMDRw4EAAVJbz7LQLt35w",
+ "ts": "1677846583",
+ "utc": "2023-03-03 12:29:43"
+ },
+ "asia-west": {
+ "id": "ZzR8YsOxZ6N-5JIY69UUw",
+ "ts": "1677837621",
+ "utc": "2023-03-03 10:00:21"
+ },
+ "asia-east": {
+ "id": "GSB1g5Ef39pRsdL0VZfPB",
+ "ts": "1677886896",
+ "utc": "2023-03-03 23:41:36"
+ }
+ },
+ "now": {
+ "ts": 1677897828,
+ "utc": "2023-03-04 02:43:48"
+ }
+}
+
+
+ Example Request:
+https://bereal.devin.rest/v1/moments/latest?api_key=YOUR_API_KEY
+
+ This endpoint returns current and previous moments in each region with the following JSON format. While the default limit for returned moments is 90 for each region, you can alter this behavior with the limit GET parameter; For the value, you can provide an integer to limit the moment count for each region, or "none", which removes the limit and will return all moments I have captured in each region.
+
+
+{
+ "regions": {
+ "us-central": [
+ {
+ "id": "MIB0Amg220yP7m0Te-p9s",
+ "ts": "1677871105",
+ "utc": "2023-03-03 19:18:25"
+ },
+ ...
+ ],
+ "europe-west": [
+ {
+ "id": "CMDRw4EAAVJbz7LQLt35w",
+ "ts": "1677846583",
+ "utc": "2023-03-03 12:29:43"
+ },
+ ...
+ ],
+ "asia-west": [
+ {
+ "id": "ZzR8YsOxZ6N-5JIY69UUw",
+ "ts": "1677837621",
+ "utc": "2023-03-03 10:00:21"
+ },
+ ...
+ ],
+ "asia-east": [
+ {
+ "id": "GSB1g5Ef39pRsdL0VZfPB",
+ "ts": "1677886896",
+ "utc": "2023-03-03 23:41:36"
+ },
+ ...
+ ]
+ }
+}
+