Skip to content

Marti API Compatibility

MAGK provides a TAK Server-compatible API surface at /Marti/api/* so that ATAK, iTAK, and WinTAK clients can interact with the platform using their native protocol. These endpoints are served through Nginx with mTLS on port 8443 (client certificate required) and through the enrollment port 8446 (Let's Encrypt certificate, no client cert).

Response Format

All Marti-compatible endpoints return the TAK protocol response envelope:

interface MartiResponse<T> {
  version: '3'
  type: string    // e.g. "com.bbn.marti.remote.ClientEndpoint"
  data: T[]       // Always an array
  nodeId: 'magk'  // Server identifier
}

Example response:

{
  "version": "3",
  "type": "com.bbn.marti.remote.Contact",
  "data": [
    {
      "uid": "ANDROID-a1b2c3d4",
      "callsign": "ALPHA-1",
      "lastEventTime": "2025-01-15T14:30:00.000Z",
      "lastStatus": "Connected"
    }
  ],
  "nodeId": "magk"
}

Authentication

Marti API endpoints use mTLS client certificate authentication. TAK clients present a certificate issued by the MAGK CA during the TLS handshake. Nginx validates the client certificate and proxies the request to the application server.

Port Certificate Client Cert Required Purpose
8443 MAGK CA (mTLS) Yes Full Marti API access
8446 Let's Encrypt No Certificate enrollment only

Client Endpoints

GET /Marti/api/clientEndPoints

List connected TAK clients (end-user devices). ATAK calls this to discover other connected clients.

Query Parameters:

Parameter Type Description
secAgo integer Only return clients seen within the last N seconds

Response type: com.bbn.marti.remote.ClientEndpoint

{
  "version": "3",
  "type": "com.bbn.marti.remote.ClientEndpoint",
  "data": [
    {
      "uid": "ANDROID-a1b2c3d4",
      "callsign": "ALPHA-1",
      "lastEventTime": "2025-01-15T14:30:00.000Z",
      "lastStatus": "Connected",
      "groups": ["Blue Platoon", "Alpha Squad"]
    }
  ],
  "nodeId": "magk"
}

Contacts

GET /Marti/api/contacts/all

List all known contacts with device metadata. Used by ATAK to populate the contacts list.

Response type: com.bbn.marti.remote.Contact

{
  "version": "3",
  "type": "com.bbn.marti.remote.Contact",
  "data": [
    {
      "uid": "ANDROID-a1b2c3d4",
      "callsign": "ALPHA-1",
      "lastEventTime": "2025-01-15T14:30:00.000Z",
      "lastStatus": "Connected",
      "platform": "ATAK-CIV",
      "version": "4.10.0",
      "deviceType": "Android"
    }
  ],
  "nodeId": "magk"
}

Missions

GET /Marti/api/missions/

List all missions.

Response type: Mission

{
  "version": "3",
  "type": "Mission",
  "data": [
    {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "name": "Operation Nightfall",
      "description": "Night reconnaissance mission",
      "eventId": "660e8400-e29b-41d4-a716-446655440000"
    }
  ],
  "nodeId": "magk"
}

GET /Marti/api/missions/$missionName

Get a single mission by name.

POST /Marti/api/missions/

Create a new mission.

PUT /Marti/api/missions/$missionName

Update a mission by name.

DELETE /Marti/api/missions/$missionName

Delete a mission by name.

GET /Marti/api/missions/$missionName/contents

List content items (data packages, CoT markers) attached to a mission.

PUT /Marti/api/missions/$missionName/contents

Add content to a mission.

GET /Marti/api/missions/$missionName/changes

Get the change log for a mission. Used by TAK clients to sync mission updates.

PUT /Marti/api/missions/$missionName/subscription

Subscribe the current client to mission change notifications.

DELETE /Marti/api/missions/$missionName/subscription

Unsubscribe from mission change notifications.

Groups

GET /Marti/api/groups/all

List all groups. Returns group names and membership info in TAK format.

Response type: Group

{
  "version": "3",
  "type": "Group",
  "data": [
    {
      "id": "770e8400-e29b-41d4-a716-446655440000",
      "name": "Blue Platoon",
      "type": "platoon"
    }
  ],
  "nodeId": "magk"
}

Data Packages (Sync)

GET /Marti/api/sync/search

Search for data packages by keyword, hash, or metadata.

GET /Marti/api/sync/content

Download a data package by hash. Returns the binary file content.

GET /Marti/api/sync/metadata/$hash/tool

Get the metadata URL for a data package by its content hash. Used by TAK clients during mission sync.

Files

GET /Marti/api/files/metadata

List file metadata for uploaded resources.

TLS & Certificate Enrollment

GET /Marti/api/tls/config

Get the TLS configuration for TAK client connections. Returns CA certificate info and connection parameters.

POST /Marti/api/tls/signClient/

Sign a client certificate signing request (CSR). The TAK client submits a CSR and receives a signed certificate.

POST /Marti/api/tls/signClient/v2

V2 certificate signing endpoint with extended metadata support.

GET /Marti/api/tls/profile/enrollment

Download a certificate enrollment data package (.zip). Contains the signed client certificate, CA trust chain, and server connection profile. This is the primary endpoint used by ATAK/iTAK for automatic enrollment.

Enrollment Port

Certificate enrollment endpoints are served on port 8446 with a Let's Encrypt certificate (no client cert required), since the client does not yet have a certificate at enrollment time.

Device Profile

GET /Marti/api/device/profile/connection

Get the device connection profile. Returns server connection parameters that TAK clients use to configure their server connection.

Version

GET /Marti/api/version/config

Get the server version and configuration. TAK clients call this on connection to verify server compatibility.