Spatial Stream

FREE
By autsia
Updated 20 days ago
Location
5.6/10
Popularity Score
5027ms
Latency
87%
Success Rate

Spatial Stream API Overview

Do you want to create Tinder-like service where you would need to frequently submit coordinates of your users and then find neighbors in a particular radius? Or maybe you have an IOT project with a hive of drones and you also need to keep and update their coordinates, having a possibility to query nearby devices? Then this API will perfectly fit your needs!

Contact API Provider
star-blueRate

Submit several entities.

Entity with ID "000":

curl -X POST --include 'https://spatial-stream.p.rapidapi.com/entity/000' \
  -H 'X-RapidAPI-Host: spatial-stream.p.rapidapi.com' \
  -H 'X-RapidAPI-Key: 'YOUR RAPID API KEY' \
  -H 'Content-Type: application/json' \
  --data-binary '{"latitude":0,"longitude":0}'

Entity with ID "001":

curl -X POST --include 'https://spatial-stream.p.rapidapi.com/entity/001' \
  -H 'X-RapidAPI-Host: spatial-stream.p.rapidapi.com' \
  -H 'X-RapidAPI-Key: 'YOUR RAPID API KEY' \
  -H 'Content-Type: application/json' \
  --data-binary '{"latitude":0.0000001,"longitude":0}'

Entity with ID "002":

curl -X POST --include 'https://spatial-stream.p.rapidapi.com/entity/002' \
  -H 'X-RapidAPI-Host: spatial-stream.p.rapidapi.com' \
  -H 'X-RapidAPI-Key: 'YOUR RAPID API KEY' \
  -H 'Content-Type: application/json' \
  --data-binary '{"latitude":-0.0000001,"longitude":0}'

Get information about entity.

Entity with ID "000":

curl -X GET --include 'https://spatial-stream.p.rapidapi.com/entity/000' \
  -H 'X-RapidAPI-Host: spatial-stream.p.rapidapi.com' \
  -H 'X-RapidAPI-Key: 'YOUR RAPID API KEY' \

Find entities around "000" entity within 1 m radius.

curl -X GET --include 'https://spatial-stream.p.rapidapi.com/near/000?radius=1' \
  -H 'X-RapidAPI-Host: spatial-stream.p.rapidapi.com' \
  -H 'X-RapidAPI-Key: 'YOUR RAPID API KEY' \

Install SDK for NodeJS

Installing

To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request

unirest.get("https://spatial-stream.p.rapidapi.com/entity/0")
.header("X-RapidAPI-Host", "spatial-stream.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication