메인 콘텐츠로 건너뛰기
이 가이드에서는 두 가지 실제 시나리오를 안내합니다. 모든 코드 블록은 복사, 붙여넣기, 실행이 가능합니다 — YOUR_API_KEY를 실제 키로 교체하기만 하면 됩니다.

시나리오: OpenAI가 새 채용을 올릴 때 모니터링

OpenAI가 채용 공고를 올렸을 때 즉시 알림을 받고 — 엔지니어링 리더십의 연락처를 자동으로 얻고 싶은 경우입니다.

모니터 생성

curl -X POST https://api.pubrio.com/monitors/create \
  -H "Content-Type: application/json" \
  -H "pubrio-api-key: YOUR_API_KEY" \
  -d '{
    "name": "OpenAI Job Tracker",
    "detection_mode": "company_first",
    "signal_types": ["jobs"],
    "signal_filters": [
      {
        "signal_type": "jobs",
        "filters": {
          "locations": ["US"]
        }
      }
    ],
    "companies": [
      "67c4696b-b7b0-46b5-b2af-9f434543661e"
    ],
    "is_company_enrichment": true,
    "is_people_enrichment": true,
    "people_enrichment_configs": [
      {
        "max_people_to_return": 5,
        "people_contact_types": ["email-work"],
        "filters": {
          "management_levels": ["director", "vp"],
          "departments": ["master_engineering"]
        }
      }
    ],
    "destination_type": "webhook",
    "destination_config": {
      "webhook_url": "https://usewebhook.com/YOUR_WEBHOOK_ID",
      "headers": {
        "Authorization": "Bearer your-secret-token"
      }
    },
    "max_records_per_trigger": 5,
    "profile_id": 1
  }'
import requests

response = requests.post(
    "https://api.pubrio.com/monitors/create",
    headers={
        "Content-Type": "application/json",
        "pubrio-api-key": "YOUR_API_KEY"
    },
    json={
        "name": "OpenAI Job Tracker",
        "detection_mode": "company_first",
        "signal_types": ["jobs"],
        "signal_filters": [
            {
                "signal_type": "jobs",
                "filters": {
                    "locations": ["US"]
                }
            }
        ],
        "companies": [
            "67c4696b-b7b0-46b5-b2af-9f434543661e"
        ],
        "is_company_enrichment": True,
        "is_people_enrichment": True,
        "people_enrichment_configs": [
            {
                "max_people_to_return": 5,
                "people_contact_types": ["email-work"],
                "filters": {
                    "management_levels": ["director", "vp"],
                    "departments": ["master_engineering"]
                }
            }
        ],
        "destination_type": "webhook",
        "destination_config": {
            "webhook_url": "https://usewebhook.com/YOUR_WEBHOOK_ID",
            "headers": {
                "Authorization": "Bearer your-secret-token"
            }
        },
        "max_records_per_trigger": 5,
        "profile_id": 1
    }
)

data = response.json()
print(f"Monitor created: {data['data']['monitor_id']}")
print(f"Signature: {data['data']['signature']}")
const response = await fetch("https://api.pubrio.com/monitors/create", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "pubrio-api-key": "YOUR_API_KEY"
  },
  body: JSON.stringify({
    name: "OpenAI Job Tracker",
    detection_mode: "company_first",
    signal_types: ["jobs"],
    signal_filters: [
      {
        signal_type: "jobs",
        filters: {
          locations: ["US"]
        }
      }
    ],
    companies: [
      "67c4696b-b7b0-46b5-b2af-9f434543661e"
    ],
    is_company_enrichment: true,
    is_people_enrichment: true,
    people_enrichment_configs: [
      {
        max_people_to_return: 5,
        people_contact_types: ["email-work"],
        filters: {
          management_levels: ["director", "vp"],
          departments: ["master_engineering"]
        }
      }
    ],
    destination_type: "webhook",
    destination_config: {
      webhook_url: "https://usewebhook.com/YOUR_WEBHOOK_ID",
      headers: {
        Authorization: "Bearer your-secret-token"
      }
    },
    max_records_per_trigger: 5,
    profile_id: 1
  })
});

const data = await response.json();
console.log("Monitor created:", data.data.monitor_id);
console.log("Signature:", data.data.signature);
동작 설명:
  • OpenAI(companies에 도메인 또는 LinkedIn URL로 지정)의 미국 신규 채용 공고를 모니터링
  • 기업 데이터를 보강하고 최대 5명의 디렉터/VP급 엔지니어링 담당자를 검색
  • 트리거당 최대 5개 레코드를 webhook으로 전달
  • 기타 모든 설정은 합리적인 기본값 사용(실시간 빈도, 일일 500회 상한 등)
company_first 모드에서는 일반적으로 companies와 신호 필터만 필요합니다. company_filters는 선택 사항입니다 — 관심 목록을 더 넓은 기업 기준과 결합하고 싶을 때 두 번째 필터링 레이어를 추가합니다.

즉시 테스트

예약된 스캔을 기다리지 마세요 — 수동 실행을 트리거하여 모든 것이 정상 작동하는지 확인하세요. tried_at에 과거 타임스탬프를 사용하여 데이터가 있는지 확인합니다(현재 시간을 사용하면 아직 새로운 신호가 나타나지 않아 0개 결과가 반환될 수 있습니다):
curl -X POST https://api.pubrio.com/monitors/process/try \
  -H "Content-Type: application/json" \
  -H "pubrio-api-key: YOUR_API_KEY" \
  -d '{
    "monitor_id": "YOUR_MONITOR_ID",
    "tried_at": "2026-01-01T00:00:00.000Z",
    "profile_id": 1
  }'
수동 트리거는 예약 트리거와 마찬가지로 크레딧을 소비합니다. 테스트를 위한 대표적인 결과를 얻으려면 tried_at에 최근 과거 날짜를 사용하세요.

결과 확인

몇 초 후, usewebhook.com에서 webhook URL을 확인하여 페이로드를 확인하세요. 로그를 통해서도 검증할 수 있습니다:
curl -X POST https://api.pubrio.com/monitors/statistics/logs \
  -H "Content-Type: application/json" \
  -H "pubrio-api-key: YOUR_API_KEY" \
  -d '{
    "profile_id": 1,
    "monitor_id": "YOUR_MONITOR_ID",
    "page": 1,
    "per_page": 5
  }'
각 로그 항목에는 상태, 신호/기업/인물 수, 크레딧 사용량, 처리 시간이 표시됩니다.

실패한 전달 재시도

특정 트리거가 실패한 경우(예: webhook이 일시적으로 다운), 전체 스캔을 다시 실행하지 않고 재시도할 수 있습니다:
curl -X POST https://api.pubrio.com/monitors/process/retry \
  -H "Content-Type: application/json" \
  -H "pubrio-api-key: YOUR_API_KEY" \
  -d '{
    "monitor_id": "YOUR_MONITOR_ID",
    "monitor_log_id": "THE_FAILED_LOG_ID",
    "profile_id": 1
  }'
통계 로그를 쿼리하고 "status": "failed" 항목을 필터링하여 monitor_log_id를 찾으세요.

다음 단계

모범 사례

빈도, 크레딧, 재시도, 스케일링.

Webhook 설정

상세한 webhook 구성 및 서명 검증.