Navigation API
Control robot movement, set navigation goals, and manage navigation paths.
Get the navigation path of the robot
Retrieve the navigation path of the robot. The path is represented as a series of points with x, y coordinates and theta (orientation in radians).
Response Body
Successful Response
siteRequiredSiteThe site where the path is located.
floorRequiredFloorThe floor where the path is located.
pointsPointsList of points defining the path.
Navigation path not found
Failed to retrieve navigation path
curl -X GET "http://localhost:7242/api/v1/navigation/path"fetch("http://localhost:7242/api/v1/navigation/path")package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/path"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/path"
response = requests.request("GET", url)
print(response.text){
"site": "site",
"floor": "floor",
"points": [
{
"theta": 0,
"x": 0,
"y": 0
},
{
"theta": 1.57,
"x": 1,
"y": 1
}
]
}{
"status_code": 404,
"success": false,
"message": "Navigation path not found",
"error": {
"code": "NAVIGATION_PATH_NOT_FOUND",
"message": "Navigation path not found"
}
}{
"status_code": 500,
"success": false,
"message": "Failed to retrieve navigation path",
"error": {
"code": "NAVIGATION_PATH_ERROR",
"message": "Failed to retrieve navigation path"
}
}Get the navigation path stream of the robot
Retrieve the navigation path stream of the robot. The path is represented as a series of points with x, y coordinates and theta (orientation in radians).
Response Body
Successful Response
siteRequiredSiteThe site where the path is located.
floorRequiredFloorThe floor where the path is located.
pointsPointsList of points defining the path.
Navigation path not found
Failed to retrieve navigation path stream
curl -X GET "http://localhost:7242/api/v1/navigation/path/stream"fetch("http://localhost:7242/api/v1/navigation/path/stream")package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/path/stream"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/path/stream"
response = requests.request("GET", url)
print(response.text){
"site": "site",
"floor": "floor",
"points": [
{
"theta": 0,
"x": 0,
"y": 0
},
{
"theta": 1.57,
"x": 1,
"y": 1
}
]
}{
"status_code": 404,
"success": false,
"message": "Navigation path not found",
"error": {
"code": "NAVIGATION_PATH_NOT_FOUND",
"message": "Navigation path not found"
}
}{
"status_code": 500,
"success": false,
"message": "Failed to retrieve navigation path stream",
"error": {
"code": "NAVIGATION_PATH_STREAM_ERROR",
"message": "Failed to retrieve navigation path stream"
}
}Get the calculated navigation path of the robot to a target
Retrieve the calculated navigation path of the robot to a specified target. The path is represented as a series of points with x, y coordinates and theta (orientation in radians).
Query Parameters
target_uidRequiredTarget UidResponse Body
Successful Response
siteRequiredSiteThe site where the path is located.
floorRequiredFloorThe floor where the path is located.
pointsPointsList of points defining the path.
Navigation path not found
Validation Error
detailDetailFailed to calculate navigation path
curl -X GET "http://localhost:7242/api/v1/navigation/path/calculate?target_uid=string"fetch("http://localhost:7242/api/v1/navigation/path/calculate?target_uid=string")package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/path/calculate?target_uid=string"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/path/calculate?target_uid=string"
response = requests.request("GET", url)
print(response.text){
"site": "site",
"floor": "floor",
"points": [
{
"theta": 0,
"x": 0,
"y": 0
},
{
"theta": 1.57,
"x": 1,
"y": 1
}
]
}{
"status_code": 404,
"success": false,
"message": "Navigation path not found",
"error": {
"code": "NAVIGATION_PATH_NOT_FOUND",
"message": "Navigation path not found"
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}{
"status_code": 500,
"success": false,
"message": "Failed to calculate navigation path",
"error": {
"code": "NAVIGATION_PATH_CALCULATION_ERROR",
"message": "Failed to calculate navigation path"
}
}Get the current position of the robot
Retrieve the current position and velocity of the robot. The position includes x, y coordinates and theta (orientation in radians).
Response Body
Successful Response
positionPositionCurrent position of the robot in the environment.
twistTwistModelCurrent velocity of the robot in the environment.
curl -X GET "http://localhost:7242/api/v1/navigation/position"fetch("http://localhost:7242/api/v1/navigation/position")package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/position"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/position"
response = requests.request("GET", url)
print(response.text){
"position": {
"x": 0,
"y": 0,
"theta": 0
},
"twist": {
"vel_x": 0,
"vel_z": 0
}
}Stream the current position of the robot
Stream the current position and velocity of the robot in real-time. The position includes x, y coordinates and theta (orientation in radians).
Response Body
Successful Response
positionPositionCurrent position of the robot in the environment.
twistTwistModelCurrent velocity of the robot in the environment.
curl -X GET "http://localhost:7242/api/v1/navigation/position/stream"fetch("http://localhost:7242/api/v1/navigation/position/stream")package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/position/stream"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/position/stream"
response = requests.request("GET", url)
print(response.text){
"position": {
"x": 0,
"y": 0,
"theta": 0
},
"twist": {
"vel_x": 0,
"vel_z": 0
}
}Set a navigation goal to a specific pose
Set a navigation goal for the robot to reach a specific position and orientation (theta). The position is defined by x and y coordinates, and theta is the orientation in radians.
Request Body
application/jsonRequiredxXX coordinate in meters.
0yYY coordinate in meters.
0thetaThetaOrientation in radians.
0Response Body
Successful Response
status_codeStatus CodeHTTP status code of the response.
200successSuccessIndicates whether the operation was successful.
truemessageMessageA message providing additional information about the operation.
""dataobject | null | nullerrorobject | null | nullValidation Error
detailDetailcurl -X POST "http://localhost:7242/api/v1/navigation/goal/pose" \
-H "Content-Type: application/json" \
-d '{
"x": 0,
"y": 0,
"theta": 0
}'const body = JSON.stringify({
"x": 0,
"y": 0,
"theta": 0
})
fetch("http://localhost:7242/api/v1/navigation/goal/pose", {
body
})package main
import (
"fmt"
"net/http"
"io/ioutil"
"strings"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/goal/pose"
body := strings.NewReader(`{
"x": 0,
"y": 0,
"theta": 0
}`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/goal/pose"
body = {
"x": 0,
"y": 0,
"theta": 0
}
response = requests.request("POST", url, json = body, headers = {
"Content-Type": "application/json"
})
print(response.text){
"status_code": 200,
"success": true,
"message": "Operation successful",
"data": {
"key": "value"
},
"error": {
"code": "ERROR_CODE",
"message": "An error occurred"
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}Set a navigation goal to a target
Set a navigation goal for the robot to reach a specific target by its unique identifier (UID). The target must exist in the system.
Request Body
application/jsonRequiredtarget_uidTarget UidThe unique identifier of the target to navigate to.
""Response Body
Successful Response
status_codeStatus CodeHTTP status code of the response.
200successSuccessIndicates whether the operation was successful.
truemessageMessageA message providing additional information about the operation.
""dataobject | null | nullerrorobject | null | nullTarget UID is required
Validation Error
detailDetailcurl -X POST "http://localhost:7242/api/v1/navigation/goal/target" \
-H "Content-Type: application/json" \
-d '{
"target_uid": "site_floor_target-1"
}'const body = JSON.stringify({
"target_uid": "site_floor_target-1"
})
fetch("http://localhost:7242/api/v1/navigation/goal/target", {
body
})package main
import (
"fmt"
"net/http"
"io/ioutil"
"strings"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/goal/target"
body := strings.NewReader(`{
"target_uid": "site_floor_target-1"
}`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/goal/target"
body = {
"target_uid": "site_floor_target-1"
}
response = requests.request("POST", url, json = body, headers = {
"Content-Type": "application/json"
})
print(response.text){
"status_code": 200,
"success": true,
"message": "Operation successful",
"data": {
"key": "value"
},
"error": {
"code": "ERROR_CODE",
"message": "An error occurred"
}
}{
"status_code": 400,
"success": false,
"message": "Target UID is required",
"error": {
"code": "BAD_REQUEST",
"message": "Target UID is required"
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}Get the current emergency stop status of the robot
Retrieve the current emergency stop status of the robot. The response indicates whether the emergency stop is enabled or disabled.
Response Body
Successful Response
stopStopIndicates whether the robot should stop or not.
falsecurl -X GET "http://localhost:7242/api/v1/navigation/stop"fetch("http://localhost:7242/api/v1/navigation/stop")package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/stop"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/stop"
response = requests.request("GET", url)
print(response.text){
"stop": true
}Stop the robot
Set the emergency stop status of the robot. This will stop the robot immediately and prevent any further movement until the emergency stop is cleared.
Request Body
application/jsonRequiredstopStopIndicates whether the robot should stop or not.
falseResponse Body
Successful Response
status_codeStatus CodeHTTP status code of the response.
200successSuccessIndicates whether the operation was successful.
truemessageMessageA message providing additional information about the operation.
""dataobject | null | nullerrorobject | null | nullValidation Error
detailDetailcurl -X POST "http://localhost:7242/api/v1/navigation/stop" \
-H "Content-Type: application/json" \
-d '{
"stop": true
}'const body = JSON.stringify({
"stop": true
})
fetch("http://localhost:7242/api/v1/navigation/stop", {
body
})package main
import (
"fmt"
"net/http"
"io/ioutil"
"strings"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/stop"
body := strings.NewReader(`{
"stop": true
}`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/stop"
body = {
"stop": true
}
response = requests.request("POST", url, json = body, headers = {
"Content-Type": "application/json"
})
print(response.text){
"status_code": 200,
"success": true,
"message": "Operation successful",
"data": {
"key": "value"
},
"error": {
"code": "ERROR_CODE",
"message": "An error occurred"
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}Send a safety velocity command to the robot
Send a safety velocity command to the robot. This command is used to control the robot's movement in a safe manner, ensuring it does not exceed safety limits.
Request Body
application/jsonRequiredvel_xVel XLinear velocity in the x direction in meters per second.
0vel_zVel ZAngular velocity around the z axis in radians per second.
0Response Body
Successful Response
status_codeStatus CodeHTTP status code of the response.
200successSuccessIndicates whether the operation was successful.
truemessageMessageA message providing additional information about the operation.
""dataobject | null | nullerrorobject | null | nullValidation Error
detailDetailcurl -X POST "http://localhost:7242/api/v1/navigation/vel/safe" \
-H "Content-Type: application/json" \
-d '{
"vel_x": 0,
"vel_z": 0
}'const body = JSON.stringify({
"vel_x": 0,
"vel_z": 0
})
fetch("http://localhost:7242/api/v1/navigation/vel/safe", {
body
})package main
import (
"fmt"
"net/http"
"io/ioutil"
"strings"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/vel/safe"
body := strings.NewReader(`{
"vel_x": 0,
"vel_z": 0
}`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/vel/safe"
body = {
"vel_x": 0,
"vel_z": 0
}
response = requests.request("POST", url, json = body, headers = {
"Content-Type": "application/json"
})
print(response.text){
"status_code": 200,
"success": true,
"message": "Operation successful",
"data": {
"key": "value"
},
"error": {
"code": "ERROR_CODE",
"message": "An error occurred"
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}Send a velocity command to the robot
Send a velocity command to the robot. This command is used to control the robot's movement by specifying linear and angular velocities.
Request Body
application/jsonRequiredvel_xVel XLinear velocity in the x direction in meters per second.
0vel_zVel ZAngular velocity around the z axis in radians per second.
0Response Body
Successful Response
status_codeStatus CodeHTTP status code of the response.
200successSuccessIndicates whether the operation was successful.
truemessageMessageA message providing additional information about the operation.
""dataobject | null | nullerrorobject | null | nullValidation Error
detailDetailcurl -X POST "http://localhost:7242/api/v1/navigation/vel" \
-H "Content-Type: application/json" \
-d '{
"vel_x": 0,
"vel_z": 0
}'const body = JSON.stringify({
"vel_x": 0,
"vel_z": 0
})
fetch("http://localhost:7242/api/v1/navigation/vel", {
body
})package main
import (
"fmt"
"net/http"
"io/ioutil"
"strings"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/vel"
body := strings.NewReader(`{
"vel_x": 0,
"vel_z": 0
}`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/vel"
body = {
"vel_x": 0,
"vel_z": 0
}
response = requests.request("POST", url, json = body, headers = {
"Content-Type": "application/json"
})
print(response.text){
"status_code": 200,
"success": true,
"message": "Operation successful",
"data": {
"key": "value"
},
"error": {
"code": "ERROR_CODE",
"message": "An error occurred"
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}Start the localization process
Start the localization process for the robot. This endpoint initiates the localization process using the provided site and floor information.
Request Body
application/jsonRequiredsiteSiteThe site where the target is located.
""floorFloorThe floor where the target is located.
""Response Body
Successful Response
status_codeStatus CodeHTTP status code of the response.
200successSuccessIndicates whether the operation was successful.
truemessageMessageA message providing additional information about the operation.
""dataobject | null | nullerrorobject | null | nullFailed to start localization
Validation Error
detailDetailcurl -X POST "http://localhost:7242/api/v1/navigation/localization" \
-H "Content-Type: application/json" \
-d '{
"site": "site",
"floor": "floor"
}'const body = JSON.stringify({
"site": "site",
"floor": "floor"
})
fetch("http://localhost:7242/api/v1/navigation/localization", {
body
})package main
import (
"fmt"
"net/http"
"io/ioutil"
"strings"
)
func main() {
url := "http://localhost:7242/api/v1/navigation/localization"
body := strings.NewReader(`{
"site": "site",
"floor": "floor"
}`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:7242/api/v1/navigation/localization"
body = {
"site": "site",
"floor": "floor"
}
response = requests.request("POST", url, json = body, headers = {
"Content-Type": "application/json"
})
print(response.text){
"status_code": 200,
"success": true,
"message": "Operation successful",
"data": {
"key": "value"
},
"error": {
"code": "ERROR_CODE",
"message": "An error occurred"
}
}{
"status_code": 400,
"success": false,
"message": "Failed to start localization",
"error": {
"code": "LOCALIZATION_ERROR",
"message": "Failed to start localization"
}
}{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}