v1.0.0


Marki API

A robust, API for tracking real-time Discord presence, activities, and Spotify status.

REST API

Fetch a user's current status via a simple HTTP GET request.

GET https://api.marki.my/v1/users/{user_id}

Response Example

{
  "success": true,
  "data": {
    "discord_user": {
      "username": "Marki",
      "id": "1053571917665280010"
    },
    "discord_status": "online",
    "listening_to_spotify": true,
    "spotify": {
      "song": "Never Gonna Give You Up",
      "artist": "Rick Astley"
    }
  }
}

WebSocket API

Connect for real-time event streaming.

WSS wss://api.marki.my/socket

1. Connection & Handshake (Op 2)

Send this immediately after opening the connection.

{
  "op": 2,
  "d": {
    "subscribe_to_id": "1053571917665280010"
  }
}

2. Heartbeat (Op 3)

The server will send an INIT_STATE payload with a heartbeat_interval. You must send Op 3 periodically.

{
  "op": 3
}