Skip to main content
POST
/
heartbeats
Send heartbeat
curl --request POST \
  --url https://clob.polymarket.com/heartbeats \
  --header 'POLY_ADDRESS: <api-key>' \
  --header 'POLY_API_KEY: <api-key>' \
  --header 'POLY_PASSPHRASE: <api-key>' \
  --header 'POLY_SIGNATURE: <api-key>' \
  --header 'POLY_TIMESTAMP: <api-key>'
import requests

url = "https://clob.polymarket.com/heartbeats"

headers = {
"POLY_API_KEY": "<api-key>",
"POLY_ADDRESS": "<api-key>",
"POLY_SIGNATURE": "<api-key>",
"POLY_PASSPHRASE": "<api-key>",
"POLY_TIMESTAMP": "<api-key>"
}

response = requests.post(url, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {
POLY_API_KEY: '<api-key>',
POLY_ADDRESS: '<api-key>',
POLY_SIGNATURE: '<api-key>',
POLY_PASSPHRASE: '<api-key>',
POLY_TIMESTAMP: '<api-key>'
}
};

fetch('https://clob.polymarket.com/heartbeats', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://clob.polymarket.com/heartbeats",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"POLY_ADDRESS: <api-key>",
"POLY_API_KEY: <api-key>",
"POLY_PASSPHRASE: <api-key>",
"POLY_SIGNATURE: <api-key>",
"POLY_TIMESTAMP: <api-key>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://clob.polymarket.com/heartbeats"

req, _ := http.NewRequest("POST", url, nil)

req.Header.Add("POLY_API_KEY", "<api-key>")
req.Header.Add("POLY_ADDRESS", "<api-key>")
req.Header.Add("POLY_SIGNATURE", "<api-key>")
req.Header.Add("POLY_PASSPHRASE", "<api-key>")
req.Header.Add("POLY_TIMESTAMP", "<api-key>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://clob.polymarket.com/heartbeats")
.header("POLY_API_KEY", "<api-key>")
.header("POLY_ADDRESS", "<api-key>")
.header("POLY_SIGNATURE", "<api-key>")
.header("POLY_PASSPHRASE", "<api-key>")
.header("POLY_TIMESTAMP", "<api-key>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://clob.polymarket.com/heartbeats")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["POLY_API_KEY"] = '<api-key>'
request["POLY_ADDRESS"] = '<api-key>'
request["POLY_SIGNATURE"] = '<api-key>'
request["POLY_PASSPHRASE"] = '<api-key>'
request["POLY_TIMESTAMP"] = '<api-key>'

response = http.request(request)
puts response.read_body
{
  "status": "ok"
}
{
"error": "Invalid API key"
}
{
"error": "Internal server error"
}

Authorizations

POLY_API_KEY
string
header
required

Your API key

POLY_ADDRESS
string
header
required

Ethereum address associated with the API key

POLY_SIGNATURE
string
header
required

HMAC signature of the request

POLY_PASSPHRASE
string
header
required

API key passphrase

POLY_TIMESTAMP
string
header
required

Unix timestamp of the request

Response

Heartbeat acknowledged

Response for heartbeat request

status
string
required

Status of the heartbeat acknowledgment

Example:

"ok"