API Overview
https://crispres.com/wp-json/
Callback
MU_Activity_Logger::api_get_logs
Example Response
GET EXAMPLE:
[
{
"timestamp": "2026-02-12 00:36:20",
"called_from": "backend",
"user_id": 0,
"username": "Guest",
"description": "user performed a test request"
}
]
PUT EXAMPLE:
Variables needed:
1) called_from - eg. backend, frontend, app, watch, ar, other default is set to backend
2) description - a short description of the action
Response:
{
"status": "success",
"message": "Log added"
}
Callback
MU_Activity_Logger::api_get_logs_by_date
Callback
im_get_incidents
Example Response
GET EXAMPLE:
[
{
"id": "15",
"title": "Warehouse Fire",
"status": "active",
"type": "fire",
"location": {
"latitude": 37.98,
"longitude": 23.72
},
"description": "Large fire",
"teams": [],
"tasks": [{
"id": "task_abc123",
"title": "string",
"status": "string",
"createdOn": "2026-05-13 10:00:00",
"completedOn": "2026-05-13 11:00:00",
"assignees": [
{ "name": "string", "team": "string" }
]
}],
"photos": [{ "id": "456", "url": "https://crispres.com/wp-content/uploads/..." }]
}
]
POST EXAMPLE:
{
"title": "Chemical Leak",
"status": "active",
"type": "chemical",
"description": "Leak in sector 3",
"location": {
"latitude": 37.9838,
"longitude": 23.7275
},
"tasks": [
{
"title": "Evacuate Floor",
"status": "in-progress",
"assignees": [
{
"id": 10,
"name": "John",
"team": "Alpha"
},
{
"id": 25,
"name": "Maria",
"team": "Pyro"
}
]
},
{
"title": "Contain Leak",
"status": "need-assistance",
"assignees": [
{
"id": 41,
"name": "Nikos",
"team": "Robot"
}
]
}
]
}
Callback
im_get_incident
Example Response
GET EXAMPLE:
[
{
"id": "15",
"title": "Warehouse Fire",
"status": "active",
"type": "fire",
"location": {
"latitude": 37.98,
"longitude": 23.72
},
"description": "Large fire",
"teams": [],
"tasks": [],
"photos": []
}
]
PATCH /incidents/{id}
DELETE /incidents/{id}
Callback
im_complete_incident
Example Response
* An empty POST request will set the current incident as "completed" with the timestamp
EXAMPLE:
{
"status": "completed",
"completedOn": "timestamp"
}
Callback
im_get_tasks_endpoint
Example Response
* Gets or Sets incidents
GET EXAMPLE:
[
{
"title": "Evacuate Floor",
"status": "in-progress",
"assignees": [
{
"id": 10,
"name": "John",
"team": "Alpha"
},
{
"id": 25,
"name": "Maria",
"team": "Pyro"
}
],
"id": "task_69fb1788eefef",
"createdOn": "2026-05-06 10:27:20"
},
{
"title": "Contain Leak",
"status": "need-assistance",
"assignees": [
{
"id": 41,
"name": "Nikos",
"team": "Robot"
}
],
"id": "task_69fb1788ef00d",
"createdOn": "2026-05-06 10:27:20"
}
]
POST EXAMPLE:
{
"title": "Secure perimeter",
"status": "in-progress",
"assignees": [
{
"id": 1,
"name": "John",
"team": "Alpha"
}
]
}
Callback
im_update_task
Callback
im_complete_task
Callback
im_upload_incident_media
Example Response
POST * At least one file or a link should be provided.
Callback
Anonymous or Closure
Example Response
GET Request body:
JWT Bearer: {the token we got from /auth endpoint}
Success Response (200):
{
"id": 1,
"email": "test@telesto.gr",
"phoneNumber": "",
"username": "test",
"firstName": "TestName",
"surname": "TestSurname",
"teams": [1,2]
}
Callback
Anonymous or Closure
Example Response
* Fully RFC-7946 compliant GeoJSON
* Full SimpleStyle support (in accordance with Mapbox more: https://github.com/mapbox/simplestyle-spec/tree/master/1.1.0)
* GeoJSON file can be tested on geojson.io
* All data are [longitude, latitude]
* Scroll down for examples per each geometry type
--------------------------------------------
GET EXAMPLE:
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"id": "feature_6994dac99fc5a3.42572521",
"geometry": {
"type": "Point",
"coordinates": [
23.72,
37.98
]
},
"properties": {
"name": "Athens"
}
}
]
}
--------------------------------------------
PUT EXAMPLE: (all properties except name are optional):
{
"geometry": {
"type": "Point",
"coordinates": [23.72, 37.94]
},
"properties": {
"name": "Athens",
"marker-color": "#f77373",
"marker-size": "medium",
"marker-symbol": "attraction"
}
}
SHOULD RETURN:
{
"type": "Feature",
"id": "feature_6994e962295902.59834322",
"geometry": {
"type": "Point",
"coordinates": [
23.72,
37.94
]
},
"properties": {
"name": "Athens",
"marker-color": "#fefefe",
"marker-size": "medium",
"marker-symbol": "attraction"
}
}
--------------------------------------------
/{$id}
--------------------------------------------
PATCH EXAMPLE:
{
"geometry": {
"type": "Point",
"coordinates": [23.72, 37.98]
},
"properties": {
"name": "Athens"
}
}
SHOULD RETURN:
{
"success": true
}
--------------------------------------------
DELETE RETURNS:
{
"deleted": "feature_6994d968644b57.57029541"
}
--------------------------------------------
GEOMETRY TYPES EXAMPLE:
--------------------------------------------
Point:
{
"geometry": {
"type": "Point",
"coordinates": [23.7348, 37.9755]
},
"properties": {
"name": "Syntagma Square",
"category": "Landmark"
}
}
Multipoint:
{
"geometry": {
"type": "MultiPoint",
"coordinates": [
[23.7348, 37.9755],
[23.7275, 37.9715],
[23.7295, 37.9680]
]
},
"properties": {
"name": "Central Athens Points",
"description": "Syntagma, Monastiraki, Acropolis area"
}
}
LineString:
{
"geometry": {
"type": "LineString",
"coordinates": [
[23.7330, 37.9730],
[23.7320, 37.9725],
[23.7310, 37.9720],
[23.7300, 37.9715]
]
},
"properties": {
"name": "Plaka Walking Route"
}
}
MultiLineString:
{
"geometry": {
"type": "MultiLineString",
"coordinates": [
[
[23.7330, 37.9730],
[23.7320, 37.9725],
[23.7310, 37.9720]
],
[
[23.7280, 37.9705],
[23.7270, 37.9695],
[23.7260, 37.9685]
]
]
},
"properties": {
"name": "Multiple Walking Paths"
}
}
Polygon:
⚠ Important: First and last coordinate must be identical (closed ring).
{
"geometry": {
"type": "Polygon",
"coordinates": [
[
[23.7295, 37.9685],
[23.7315, 37.9685],
[23.7315, 37.9705],
[23.7295, 37.9705],
[23.7295, 37.9685]
]
]
},
"properties": {
"name": "Acropolis Buffer Zone"
}
}
MultiPolygon:
{
"geometry": {
"type": "MultiPolygon",
"coordinates": [
[
[
[23.7295, 37.9685],
[23.7315, 37.9685],
[23.7315, 37.9705],
[23.7295, 37.9705],
[23.7295, 37.9685]
]
],
[
[
[23.7355, 37.9750],
[23.7370, 37.9750],
[23.7370, 37.9765],
[23.7355, 37.9765],
[23.7355, 37.9750]
]
]
]
},
"properties": {
"name": "Two Protected Areas"
}
}
GeometryCollection (mixed types):
{
"geometry": {
"type": "GeometryCollection",
"geometries": [
{
"type": "Point",
"coordinates": [23.7348, 37.9755]
},
{
"type": "LineString",
"coordinates": [
[23.7330, 37.9730],
[23.7310, 37.9720]
]
}
]
},
"properties": {
"name": "Mixed Geometry Example"
}
}
Callback
MU_Map_Manager::api_modify
Callback
MU_Map_Manager::api_distance
Example Response
* Distance between two geolocations (using Haversine formula)
* Result is in meters and km
--------------------------------------------
GET EXAMPLE:
https://crispres.com/wp-json/map-manager/v1/distance?lat1=37.98&lon1=23.72&lat2=37.99&lon2=23.74
Response: {
"distance_meters": 2075.76,
"distance_km": 2.076
}
Callback
MU_Map_Manager::api_nearby
Example Response
* Find nearby elements on the map
* If the POI is not a point it uses the minimum distance from the input location to the geometry type
* Can set to search only for POIs (points) using poi_only=1 otherwise it searches through all geometry types (polygons, lines etc.)
* If distance is empty, it searches in 500m radius otherwise we can set it using radius=X
* Counts the number of findings in the JSON response
--------------------------------------------
GET EXAMPLE (with optional poi_only=1):
https://crispres.com/wp-json/map-manager/v1/nearby?lat=37.98&lon=23.72&radius=1000&poi_only=1
Response:
{
"center": {
"lat": 37.98,
"lon": 23.72
},
"radius_meters": 1000,
"poi_only": true,
"count": 1,
"features": [
{
"type": "Feature",
"id": "feature_6994dac99fc5a3.42572521",
"geometry": {
"type": "Point",
"coordinates": [
23.72,
37.98
]
},
"properties": {
"name": "Athens",
"type": "victim"
},
"distance_meters": 0
}
]
}
Callback
mqtt_store_latest_message
Example Response
* Acts as a broker for MQTT gets all data from a python script and exposes them on a GET API
ROS2 -> MQTT -> [Python Broker] -> Wordpress API -> [Data]
GET REQUEST:
https://crispres.com/wp-json/mqtt/v1/latest
GET EXAMPLE:
{
"message": {
"header": {
"stamp": {
"sec": 772,
"nanosec": 63000000
},
"frame_id": "b2/base_link"
},
"roll": -0.0007367624784819782,
"pitch": 5.776180644900819e-10,
"yaw": -2.1450254917144775,
"latitude": 49.72630430444614,
"longitude": 13.351475442373582,
"battery_temperature": 0,
"power_voltage": 0,
"power_current": 0,
"temperature_ntc1": 0,
"temperature_ntc2": 0,
"mode": 0,
"commander": "none",
"behavior": "IDLE",
"action_command": "{}"
},
"topic": "/b2/ugv_status_from_ros2",
"time": "2026-04-15 11:15:16"
}
# ========================
# CONFIGURATION
# ========================
BROKER = "188.245.65.20" # without mqtt://
PORT = 1883
USERNAME = "authenticated_user"
PASSWORD = "Qgg15J8UaUQ41Qxd"
TOPIC = "/b2/ugv_status_from_ros2"
WP_ENDPOINT = "https://crispres.com/wp-json/mqtt/v1/latest"
API_KEY = "triffid123!"
Callback
Observer_Sync_Status_MU::get_status
Example Response
GET EXAMPLE:
{
"last_update": "2026-02-12 13:40:49",
"fe_updated": 1,
"mobile_updated": 0,
"ar_updated": 0
}
PATCH EXAMPLE (using secret key):
{
"success": true,
"data": {
"last_update": "2026-02-12 13:40:49",
"fe_updated": 1,
"mobile_updated": 0,
"ar_updated": 0
}
}
Callback
handle_lost_password_request
Example Response
* Verification codes expire after 10 minutes
* Unique 6-digit numeric codes
* Email verification required
* Invalid email addresses are rejected
--------------------------------------------
POST Request body:
{
"email": "user@example.com"
}
Success Response (200):
{
"reset_code": "123456"
}
Error Response (404):
{
"error": "Email not found."
}
Callback
validate_reset_code
Example Response
POST Request body:
{
"email": "user@example.com",
"code": "123456"
}
Success Response (200):
{
"status": "approved"
}
Error Response (403):
{
"status": "not approved",
"error": "Code expired."
}
Callback
reset_user_password
Example Response
POST Request body:
{
"email": "user@example.com",
"code": "123456",
"new_password": "your-new-password"
}
Success Response (200):
{
"status": "password reset successfully"
}
Error Response (403):
{
"status": "not approved"
}
Callback
handle_sos_alert
Example Response
* POST an SOS alert
POST EXAMPLE:
{
"name": "Fivos",
"lat": 37.9838,
"lon": 23.7275
}
Callback
get_latest_sos
Example Response
* GET the latest SOS alert
GET EXAMPLE:
{
"status": "ok",
"data": {
"name": "Fivos",
"lat": 37.9838,
"lon": 23.7275,
"time": "2026-04-17 23:43:12"
},
"map_url": "https:\/\/www.google.com\/maps?q=37.9838,23.7275"
Callback
Anonymous or Closure
Example Response
Count the total users, users that are in a team and the users that are not in a team. Avoid duplicate counting (eg. if a person is in two or more teams).
GET example response:
{
"total_users": 7,
"users_in_teams": 6,
"users_without_team": 1
}
Callback
Anonymous or Closure
Example Response
* GET the teams with their corresponding colors.
[
{
"id": 1,
"name": "Alpha",
"type": "Officers",
"color": "#5fbf77"
},
{
"id": 2,
"name": "Beta",
"type": "Police",
"color": "#9585d5"
},
{
"id": 3,
"name": "Pyro",
"type": "Firefighters",
"color": "#94e08f"
},
{
"id": 4,
"name": "Medics",
"type": "Medics",
"color": "#9fe830"
},
{
"id": 5,
"name": "Robot",
"type": "Robot",
"color": "#c6c4d9"
},
{
"id": 6,
"name": "FR",
"type": "First Responders",
"color": "#ade5ff"
},
{
"id": 7,
"name": "Admins",
"type": "Administrators",
"color": "#ffadce"
}
]
Callback
Anonymous or Closure
Example Response
* GETS the list of users for a specific team.
GET EXAMPLE:
[
{
"id": 1,
"login": "fivos",
"email": "fivos@telesto.gr"
},
{
"id": 13,
"login": "jiml32",
"email": "dlappas@telesto.gr"
},
{
"id": 14,
"login": "dmoustakas",
"email": "dmoustakas@telesto.gr"
}
]
Parameters
- context — Scope under which the request is made; determines fields present in response.
- page — Current page of the collection.
- per_page — Maximum number of items to be returned in result set.
- search — Limit results to those matching a string.
- exclude — Ensure result set excludes specific IDs.
- include — Limit result set to specific IDs.
- offset — Offset the result set by a specific number of items.
- order — Order sort attribute ascending or descending.
- orderby — Sort collection by user attribute.
- slug — Limit result set to users with one or more specific slugs.
- roles — Limit result set to users matching at least one specific role provided. Accepts csv list or single role.
- capabilities — Limit result set to users matching at least one specific capability provided. Accepts csv list or single capability.
- who — Limit result set to users who are considered authors.
- has_published_posts — Limit result set to users who have published posts.
- search_columns — Array of column names to be searched.
Callback
WP_REST_Users_Controller::get_items
Example Response
{"id":0,"username":"string","name":"string","first_name":"string","last_name":"string","email":"user@example.com","url":"http:\/\/example.com","description":"string","link":"http:\/\/example.com","locale":"","nickname":"string","slug":"string","registered_date":"2019-08-24T14:15:22Z","roles":["string"],"password":"string","capabilities":[],"extra_capabilities":[],"meta":{"persisted_preferences":[]},"online_status":"on"}
Parameters
- id — Unique identifier for the user.
- context — Scope under which the request is made; determines fields present in response.
Callback
WP_REST_Users_Controller::get_item
Parameters
- context — Scope under which the request is made; determines fields present in response.
Callback
WP_REST_Users_Controller::get_current_item
Example Response
{"id":0,"username":"string","name":"string","first_name":"string","last_name":"string","email":"user@example.com","url":"http:\/\/example.com","description":"string","link":"http:\/\/example.com","locale":"","nickname":"string","slug":"string","registered_date":"2019-08-24T14:15:22Z","roles":["string"],"password":"string","capabilities":[],"extra_capabilities":[],"meta":{"persisted_preferences":[]},"online_status":"on"}