J Jagalayar
API Reference

🔌 Jagalayar API

REST-ish JSON API untuk integrasi monitoring domain TrustPositif/Komdigi, smart rotator anti-blokir, dan AI keyword sniffer. Cocok untuk integrasi dengan custom dashboard, automation tool, atau aplikasi pihak ketiga.

Base URL: https://jagalayar.com/api Format: JSON Version: v1.4

🔐 Authentication

Semua endpoint kecuali public rotator (/api/go.php) butuh API key di header:

HTTP Header
Authorization: Bearer YOUR_API_KEY

Generate API key di Dashboard → API Shop. Key bersifat akun-spesifik dan tidak bisa di-share.

⚠️ Keamanan

Jangan hardcode API key di client-side JavaScript. Gunakan backend proxy untuk panggil API ini, atau pakai server-side script (PHP/Node/Python).

📋 Rate Limiting

Limit per akun, scaling sesuai paket aktif:

TierLimit HarianRate Per Menit
Free10010
Starter50030
Pro2.00060
Sultan10.000120

Setiap response include header rate limit:

HTTP Header
X-RateLimit-Limit: 2000
X-RateLimit-Remaining: 1872
X-RateLimit-Reset: 1714521600

Kalau lewat limit → response 429 Too Many Requests.

📦 Response Format

Success Response

JSON Response 200
{
  "ok": true,
  "data": { ... },
  "meta": { "ts": "2026-04-21T12:34:56+07:00" }
}

Error Response

JSON Response 4xx/5xx
{
  "ok": false,
  "error": {
    "code": "INVALID_DOMAIN",
    "message": "Format domain tidak valid"
  }
}

🛡️ Endpoints

GET 1. Check Nawala Status

Cek apakah domain kena blokir TrustPositif/Komdigi.

Endpoint: https://jagalayar.com/api/nawala_check.php?domain=example.com

Request:

cURL
curl -H "Authorization: Bearer YOUR_KEY" \
     "https://jagalayar.com/api/nawala_check.php?domain=example.com"

Response 200:

JSON
{
  "ok": true,
  "data": {
    "domain": "example.com",
    "status": "SAFE",
    "checked_at": "2026-04-21T12:34:56+07:00",
    "request_id": "REQ-a3f9b1c2"
  }
}

Status values:

  • SAFE — tidak di blocklist
  • BLOCKED — kena Nawala/TrustPositif
  • ERROR — cek gagal (network/timeout issue)

GET 2. Rotator Redirect (Public)

Public endpoint (tanpa auth). Redirect ke URL target sesuai Smart Rules anda.

Endpoint: https://jagalayar.com/api/go.php?s={slug}

📝 Query Parameter

s — slug rotator (8 char alphanumeric).

Response:

  • 302 Found dengan Location: header ke target URL
  • Atau HTML interstitial kalau aktif FB/TikTok pixel

Cloaking Behavior:

  • Bot (UA mengandung bot, crawler, facebookexternal) → redirect ke safe_url
  • Human → ikuti Smart Rules (ISP/time/lang/weight)

POST 3. AI Keyword Sniffer

Analisa domain kompetitor — output top 3 keyword + sample ad copy via AI (LLM).

Endpoint: https://jagalayar.com/api/sniff_keywords.php

Request body:

JSON
{
  "domain": "competitor.com"
}

Response 200:

JSON
{
  "ok": true,
  "data": {
    "domain": "competitor.com",
    "keywords": [
      "keyword 1",
      "keyword 2",
      "keyword 3"
    ],
    "ad_copy": "Sample ad headline yg di-generate AI...",
    "confidence": 0.87
  }
}
⚠️ Cost

Endpoint ini consume credit AI (LLM call). Cek balance kredit sebelum bulk request. Rate-limited lebih ketat: 10 req/jam/akun.

⚠️ Error Codes

HTTPCodeArti
200OK
400INVALID_INPUTFormat request salah (domain invalid, body malformed)
401INVALID_API_KEYAPI key kosong/salah/expired
403QUOTA_EXCEEDEDLimit harian habis (upgrade plan)
404NOT_FOUNDResource tidak ditemukan
429RATE_LIMITEDLewat rate per menit
500SERVER_ERRORInternal error (laporkan ke support)

💻 SDK & Code Examples

PHP

PHP
$apiKey = 'YOUR_API_KEY';
$ch = curl_init('https://jagalayar.com/api/nawala_check.php?domain=example.com');
curl_setopt_array($ch, [
    CURLOPT_HTTPHEADER     => ['Authorization: Bearer ' . $apiKey],
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_TIMEOUT        => 10,
]);
$res = json_decode(curl_exec($ch), true);
curl_close($ch);

if ($res['ok'] ?? false) {
    echo "Status: " . $res['data']['status'];
}

Python

Python
import requests

api_key = 'YOUR_API_KEY'
r = requests.get(
    'https://jagalayar.com/api/nawala_check.php',
    headers={'Authorization': f'Bearer {api_key}'},
    params={'domain': 'example.com'},
    timeout=10,
)
data = r.json()
if data.get('ok'):
    print('Status:', data['data']['status'])

Node.js

JavaScript / Node.js
const apiKey = 'YOUR_API_KEY';
const res = await fetch(
    'https://jagalayar.com/api/nawala_check.php?domain=example.com',
    { headers: { 'Authorization': `Bearer ${apiKey}` } }
);
const data = await res.json();
if (data.ok) {
    console.log('Status:', data.data.status);
}

📝 Changelog

VersionDateChanges
v1.42026-04-21AI Keyword Sniffer endpoint baru
v1.32026-03-15Rate limit headers ditambah
v1.22026-02-01Smart Rotator dengan cloaking
v1.12026-01-10Bearer auth (sebelumnya query string)
v1.02025-12-01Initial release — Nawala check