문서
문서 둘러보기

Analytics REST API

The Privatus analytics REST API: add .json to any app URL and send a token. Read the conventions and a reference of every operation, generated from the code.

Markdown으로 보기

Every page and action in Privatus is also an API endpoint. There's no separate /api/v1: add .json to a URL and send an API token.

sh
curl https://privatusanalytics.com/sites/pa_7Q2K9XH3AB/stats/aggregate.json?period=7d \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
json
{
  "data": {
    "period": { "from": "2026-09-23T00:00:00Z", "to": "2026-09-30T00:00:00Z" },
    "metrics": {
      "visitors": 1840, "visits": 2310, "pageviews": 5122,
      "views_per_visit": 2.22, "bounce_rate": 41.3,
      "visit_duration": 48000, "revenue": 129900
    }
  }
}

The reference below lists every operation with its method, path, permission, input schema and response schema. It's generated from the running code, as is the OpenAPI 3.1 document, so neither can drift from what the server does. The same operations are MCP tools.

Conventions#

Base URL https://privatusanalytics.com
Format JSON. Add .json to the path (or send Accept: application/json)
Auth Authorization: Bearer pat_… (Authentication)
Ids Public ids with a prefix: ws_… workspaces, pa_… sites, seg_… segments, wh_… webhooks
Reads GET with query parameters
Writes POST, PATCH, DELETE with a JSON body of flat fields
Success { "data": … }, plus "meta" for lists
Errors { "error": { "code", "message", "details" } } (Errors)
Lists page and per_page (max 100) (Pagination)
Times ISO 8601 in UTC. Date parameters (from, to) are days in the site's timezone
Money Minor units (cents) in the site currency, e.g. revenue: 129900 = 1,299.00
Durations Milliseconds

Common tasks#

Task Operation
List workspaces GET /workspaces.json
List sites GET /workspaces/{workspace_id}/sites.json
Headline metrics GET /sites/{site_id}/stats/aggregate.json
Chart data GET /sites/{site_id}/stats/timeseries.json
Top pages, sources, countries… GET /sites/{site_id}/breakdown/{dimension}.json
Everything on the Overview GET /sites/{site_id}/overview.json
Live visitors GET /sites/{site_id}/live.json
Add a note (e.g. a deploy) POST /sites/{site_id}/notes.json

See Stats endpoints and Examples.

In this section#

Authentication · Errors · Pagination · Rate limits · Filters · Stats endpoints · Examples · Webhooks · Changelog and deprecation

Sending data in is a different API: see Server-side ingest.

모든 작업

인증

Authorization: Bearer pat_…를 보내세요. 토큰은 워크스페이스 설정의 API 토큰에서 만듭니다. 인증 가이드.

어디서나 JSON

어떤 경로에든 .json을 붙이세요. 응답은 { "data": … } 형식이고 오류는 { "error": { "code", "message" } } 형식입니다. 오류.

MCP

같은 토큰으로 https://privatusanalytics.com/mcp에 JSON-RPC를 POST하세요. 아래의 각 작업이 하나의 도구입니다. MCP 가이드.

openapi.json 다운로드 · 작업 279개

API 토큰

POST /workspaces/:workspace_id/api_tokens.json API 토큰 만들기 (토큰은 한 번만 반환됩니다) api_tokens_create

권한: member

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/api_tokens.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "토큰을 구분할 수 있는 이름",
      "examples": [
        "CI deploys"
      ]
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "analytics.read",
          "analytics.export",
          "content.write",
          "sites.manage",
          "uptime.manage",
          "members.manage",
          "tokens.manage",
          "billing.manage",
          "workspace.manage"
        ]
      },
      "description": "권한 (생략하면 본인의 모든 권한, 빈 목록은 거부됨)"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이 사이트 ID로 제한 (pa_…). 비우면 전체",
      "default": []
    },
    "expires_at": {
      "type": "string",
      "format": "date-time",
      "description": "만료 시각 (ISO 8601). 비우면 만료 없음"
    },
    "allowed_ips": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이 IP/CIDR에서 온 요청만 허용",
      "default": []
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "name": {
      "type": "string"
    },
    "token": {
      "anyOf": [
        {
          "type": "string",
          "description": "토큰 자체: 생성될 때만 반환됨"
        },
        {
          "type": "null"
        }
      ]
    },
    "token_prefix": {
      "type": "string",
      "description": "토큰을 알아볼 수 있는 앞부분 문자"
    },
    "owner": {
      "type": "string",
      "description": "소유한 멤버의 이메일"
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이 사이트로 제한됨 (비어 있으면 전체)"
    },
    "allowed_ips": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "oauth_client": {
      "anyOf": [
        {
          "type": "string",
          "description": "토큰을 받은 MCP 클라이언트"
        },
        {
          "type": "null"
        }
      ]
    },
    "status": {
      "type": "string",
      "description": "active, expired 또는 revoked"
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_used_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "revoked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /workspaces/:workspace_id/api_tokens/:id.json API 토큰 폐기 api_tokens_delete

권한: member

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:workspace_id/api_tokens/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "name": {
      "type": "string"
    },
    "token": {
      "anyOf": [
        {
          "type": "string",
          "description": "토큰 자체: 생성될 때만 반환됨"
        },
        {
          "type": "null"
        }
      ]
    },
    "token_prefix": {
      "type": "string",
      "description": "토큰을 알아볼 수 있는 앞부분 문자"
    },
    "owner": {
      "type": "string",
      "description": "소유한 멤버의 이메일"
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이 사이트로 제한됨 (비어 있으면 전체)"
    },
    "allowed_ips": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "oauth_client": {
      "anyOf": [
        {
          "type": "string",
          "description": "토큰을 받은 MCP 클라이언트"
        },
        {
          "type": "null"
        }
      ]
    },
    "status": {
      "type": "string",
      "description": "active, expired 또는 revoked"
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_used_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "revoked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/api_tokens.json API 토큰 목록 보기 api_tokens_list

권한: member

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/api_tokens.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "include_revoked": {
      "type": "boolean",
      "description": "폐기되었거나 만료된 토큰도 함께 표시",
      "default": false
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid"
      },
      "name": {
        "type": "string"
      },
      "token": {
        "anyOf": [
          {
            "type": "string",
            "description": "토큰 자체: 생성될 때만 반환됨"
          },
          {
            "type": "null"
          }
        ]
      },
      "token_prefix": {
        "type": "string",
        "description": "토큰을 알아볼 수 있는 앞부분 문자"
      },
      "owner": {
        "type": "string",
        "description": "소유한 멤버의 이메일"
      },
      "permissions": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "site_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "이 사이트로 제한됨 (비어 있으면 전체)"
      },
      "allowed_ips": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "oauth_client": {
        "anyOf": [
          {
            "type": "string",
            "description": "토큰을 받은 MCP 클라이언트"
          },
          {
            "type": "null"
          }
        ]
      },
      "status": {
        "type": "string",
        "description": "active, expired 또는 revoked"
      },
      "expires_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_used_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "revoked_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}

SCIM

POST /scim/v2/Users.json 사용자 프로비저닝 scim_users_create

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/scim/v2/Users.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "userName": {
      "type": "string",
      "description": "이메일 주소"
    },
    "name": {
      "type": "object",
      "additionalProperties": true,
      "description": "givenName, familyName, formatted",
      "default": {}
    },
    "active": {
      "type": "boolean",
      "description": "워크스페이스의 멤버",
      "default": true
    }
  },
  "required": [
    "userName"
  ]
}
응답 데이터
{
  "type": "object"
}
DELETE /scim/v2/Users/:id.json 사용자 프로비저닝 해제 scim_users_delete

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X DELETE https://privatusanalytics.com/scim/v2/Users/:id.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /scim/v2/Users.json 프로비저닝된 사용자 목록 보기 scim_users_list

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/scim/v2/Users.json
입력
{
  "type": "object",
  "properties": {
    "scim_filter": {
      "type": "string",
      "description": "SCIM 필터 (쿼리 매개변수 `filter`), 예: userName eq \"[email protected]\""
    },
    "startIndex": {
      "type": "integer",
      "description": "첫 번째 결과의 1부터 시작하는 인덱스",
      "default": 1
    },
    "count": {
      "type": "integer",
      "description": "페이지 크기 (최대 200)",
      "default": 100
    }
  },
  "required": []
}
응답 데이터
{
  "type": "object"
}
GET /scim/v2/Users/:id.json 프로비저닝된 사용자 조회 scim_users_get

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/scim/v2/Users/:id.json
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object"
}
PATCH /scim/v2/Users/:id.json 사용자 수정 (PATCH active, name) scim_users_update

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X PATCH https://privatusanalytics.com/scim/v2/Users/:id.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "Operations": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true
      },
      "description": "SCIM PatchOp 작업"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "Operations",
    "id"
  ]
}
응답 데이터
{
  "type": "object"
}

SSO

POST /workspaces/:workspace_id/sso/activate.json 테스트를 마친 SSO 구성 활성화 sso_activate

권한: workspace.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/sso/activate.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "protocol": {
      "type": "string",
      "description": "saml 또는 oidc"
    },
    "status": {
      "type": "string",
      "description": "draft, testing, tested 또는 active"
    },
    "enforced": {
      "type": "boolean",
      "description": "SSO가 유일한 로그인 방법 (소유자 제외)"
    },
    "domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "인증된 이메일 도메인"
    },
    "idp_sso_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_entity_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_cert_present": {
      "type": "boolean"
    },
    "oidc_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_secret_present": {
      "type": "boolean"
    },
    "default_role": {
      "type": "string"
    },
    "jit_provisioning": {
      "type": "boolean"
    },
    "scim_enabled": {
      "type": "boolean"
    }
  }
}
POST /workspaces/:workspace_id/sso/deactivate.json SSO 끄기 (초안으로 되돌림) sso_deactivate

권한: workspace.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/sso/deactivate.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "protocol": {
      "type": "string",
      "description": "saml 또는 oidc"
    },
    "status": {
      "type": "string",
      "description": "draft, testing, tested 또는 active"
    },
    "enforced": {
      "type": "boolean",
      "description": "SSO가 유일한 로그인 방법 (소유자 제외)"
    },
    "domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "인증된 이메일 도메인"
    },
    "idp_sso_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_entity_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_cert_present": {
      "type": "boolean"
    },
    "oidc_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_secret_present": {
      "type": "boolean"
    },
    "default_role": {
      "type": "string"
    },
    "jit_provisioning": {
      "type": "boolean"
    },
    "scim_enabled": {
      "type": "boolean"
    }
  }
}
POST /workspaces/:workspace_id/sso/scim_token.json 새 SCIM 토큰 생성 (한 번만 표시됨) sso_scim_token

권한: workspace.manage · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/sso/scim_token.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /workspaces/:workspace_id/sso.json SSO 설정 조회 sso_get

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/sso.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "protocol": {
      "type": "string",
      "description": "saml 또는 oidc"
    },
    "status": {
      "type": "string",
      "description": "draft, testing, tested 또는 active"
    },
    "enforced": {
      "type": "boolean",
      "description": "SSO가 유일한 로그인 방법 (소유자 제외)"
    },
    "domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "인증된 이메일 도메인"
    },
    "idp_sso_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_entity_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_cert_present": {
      "type": "boolean"
    },
    "oidc_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_secret_present": {
      "type": "boolean"
    },
    "default_role": {
      "type": "string"
    },
    "jit_provisioning": {
      "type": "boolean"
    },
    "scim_enabled": {
      "type": "boolean"
    }
  }
}
PATCH /workspaces/:workspace_id/sso.json SSO 설정 만들기 또는 수정 sso_update

권한: workspace.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/sso.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "protocol": {
      "type": "string",
      "description": "saml 또는 oidc",
      "enum": [
        "saml",
        "oidc"
      ]
    },
    "idp_sso_url": {
      "type": "string",
      "description": "SAML: IdP 싱글 사인온 URL"
    },
    "idp_entity_id": {
      "type": "string",
      "description": "SAML: IdP 엔터티 ID (발급자)"
    },
    "idp_cert": {
      "type": "string",
      "description": "SAML: IdP X.509 서명 인증서 (PEM)"
    },
    "oidc_issuer": {
      "type": "string",
      "description": "OIDC: 발급자 URL (디스커버리)"
    },
    "oidc_client_id": {
      "type": "string",
      "description": "OIDC: 클라이언트 ID"
    },
    "oidc_client_secret": {
      "type": "string",
      "description": "OIDC: 클라이언트 시크릿 (쓰기 전용)"
    },
    "domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이 SSO를 사용하는 인증된 이메일 도메인"
    },
    "default_role": {
      "type": "string",
      "description": "JIT 또는 SCIM으로 만든 멤버의 역할",
      "enum": [
        "admin",
        "editor",
        "analyst",
        "viewer",
        "billing"
      ]
    },
    "jit_provisioning": {
      "type": "boolean",
      "description": "첫 SSO 로그인 시 멤버 생성"
    },
    "enforced": {
      "type": "boolean",
      "description": "SSO 로그인만 허용 (활성 구성 필요)"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "protocol": {
      "type": "string",
      "description": "saml 또는 oidc"
    },
    "status": {
      "type": "string",
      "description": "draft, testing, tested 또는 active"
    },
    "enforced": {
      "type": "boolean",
      "description": "SSO가 유일한 로그인 방법 (소유자 제외)"
    },
    "domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "인증된 이메일 도메인"
    },
    "idp_sso_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_entity_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idp_cert_present": {
      "type": "boolean"
    },
    "oidc_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "oidc_client_secret_present": {
      "type": "boolean"
    },
    "default_role": {
      "type": "string"
    },
    "jit_provisioning": {
      "type": "boolean"
    },
    "scim_enabled": {
      "type": "boolean"
    }
  }
}

가동 시간

POST /sites/:site_id/uptime.json 사이트에 가동 시간 검사 추가 uptime_checks_create

권한: uptime.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/uptime.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "표시 이름 (기본값은 대상)"
    },
    "kind": {
      "type": "string",
      "description": "http (상태 코드), keyword (본문에 포함), tcp (host:port) 또는 dns (이름 확인)",
      "enum": [
        "http",
        "keyword",
        "tcp",
        "dns"
      ],
      "default": "http"
    },
    "url": {
      "type": "string",
      "description": "http/keyword 검사용 URL",
      "examples": [
        "https://example.com/health"
      ]
    },
    "host": {
      "type": "string",
      "description": "tcp/dns 검사용 호스트명"
    },
    "port": {
      "type": "integer",
      "description": "tcp 검사용 TCP 포트"
    },
    "keyword": {
      "type": "string",
      "description": "응답 본문에 포함되어야 하는 텍스트 (keyword)"
    },
    "expected_status": {
      "type": "integer",
      "description": "예상 HTTP 상태 코드",
      "default": 200
    },
    "http_method": {
      "type": "string",
      "description": "HTTP 메서드",
      "enum": [
        "GET",
        "HEAD"
      ],
      "default": "GET"
    },
    "interval_seconds": {
      "type": "integer",
      "description": "검사 간격 (초, 요금제 최솟값 적용, 기본값 300 또는 최솟값)"
    },
    "timeout_seconds": {
      "type": "integer",
      "description": "프로브가 시간 초과되기까지의 시간 (초, 1-30)",
      "default": 20
    },
    "public": {
      "type": "boolean",
      "description": "공개 상태 페이지에 표시될 수 있음",
      "default": false
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "검사 ID (upc_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "검사가 속한 사이트"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "http, keyword, tcp 또는 dns"
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "host": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "port": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "keyword": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expected_status": {
      "type": "integer"
    },
    "http_method": {
      "type": "string"
    },
    "interval_seconds": {
      "type": "integer"
    },
    "timeout_seconds": {
      "type": "integer"
    },
    "status": {
      "type": "string",
      "description": "up, down, pending 또는 paused"
    },
    "enabled": {
      "type": "boolean"
    },
    "public": {
      "type": "boolean",
      "description": "상태 페이지에 표시될 수 있음"
    },
    "last_checked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_check_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_response_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "domain_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /uptime/checks/:id.json 가동 시간 검사와 기록 삭제 uptime_checks_delete

권한: uptime.manage

예시
curl -X DELETE https://privatusanalytics.com/uptime/checks/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "검사 ID (upc_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "검사가 속한 사이트"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "http, keyword, tcp 또는 dns"
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "host": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "port": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "keyword": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expected_status": {
      "type": "integer"
    },
    "http_method": {
      "type": "string"
    },
    "interval_seconds": {
      "type": "integer"
    },
    "timeout_seconds": {
      "type": "integer"
    },
    "status": {
      "type": "string",
      "description": "up, down, pending 또는 paused"
    },
    "enabled": {
      "type": "boolean"
    },
    "public": {
      "type": "boolean",
      "description": "상태 페이지에 표시될 수 있음"
    },
    "last_checked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_check_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_response_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "domain_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/uptime.json 사이트의 가동 시간 검사 목록 보기 uptime_checks_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/uptime.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "이 상태의 검사만",
      "enum": [
        "up",
        "down",
        "pending",
        "paused"
      ]
    },
    "query": {
      "type": "string",
      "description": "이름 또는 대상으로 필터링"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "검사 ID (upc_…)"
      },
      "workspace_id": {
        "type": "string"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "검사가 속한 사이트"
          },
          {
            "type": "null"
          }
        ]
      },
      "name": {
        "type": "string"
      },
      "kind": {
        "type": "string",
        "description": "http, keyword, tcp 또는 dns"
      },
      "url": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "host": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "port": {
        "anyOf": [
          {
            "type": "integer"
          },
          {
            "type": "null"
          }
        ]
      },
      "keyword": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "expected_status": {
        "type": "integer"
      },
      "http_method": {
        "type": "string"
      },
      "interval_seconds": {
        "type": "integer"
      },
      "timeout_seconds": {
        "type": "integer"
      },
      "status": {
        "type": "string",
        "description": "up, down, pending 또는 paused"
      },
      "enabled": {
        "type": "boolean"
      },
      "public": {
        "type": "boolean",
        "description": "상태 페이지에 표시될 수 있음"
      },
      "last_checked_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "next_check_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_response_ms": {
        "anyOf": [
          {
            "type": "integer"
          },
          {
            "type": "null"
          }
        ]
      },
      "ssl_expires_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "ssl_issuer": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "domain_expires_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /uptime/checks/:id/pause.json 가동 시간 검사 일시 중지 uptime_checks_pause

권한: uptime.manage

예시
curl -X POST https://privatusanalytics.com/uptime/checks/:id/pause.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "검사 ID (upc_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "검사가 속한 사이트"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "http, keyword, tcp 또는 dns"
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "host": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "port": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "keyword": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expected_status": {
      "type": "integer"
    },
    "http_method": {
      "type": "string"
    },
    "interval_seconds": {
      "type": "integer"
    },
    "timeout_seconds": {
      "type": "integer"
    },
    "status": {
      "type": "string",
      "description": "up, down, pending 또는 paused"
    },
    "enabled": {
      "type": "boolean"
    },
    "public": {
      "type": "boolean",
      "description": "상태 페이지에 표시될 수 있음"
    },
    "last_checked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_check_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_response_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "domain_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /uptime/checks/:id/resume.json 일시 중지된 가동 시간 검사 재개 uptime_checks_resume

권한: uptime.manage

예시
curl -X POST https://privatusanalytics.com/uptime/checks/:id/resume.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "검사 ID (upc_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "검사가 속한 사이트"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "http, keyword, tcp 또는 dns"
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "host": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "port": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "keyword": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expected_status": {
      "type": "integer"
    },
    "http_method": {
      "type": "string"
    },
    "interval_seconds": {
      "type": "integer"
    },
    "timeout_seconds": {
      "type": "integer"
    },
    "status": {
      "type": "string",
      "description": "up, down, pending 또는 paused"
    },
    "enabled": {
      "type": "boolean"
    },
    "public": {
      "type": "boolean",
      "description": "상태 페이지에 표시될 수 있음"
    },
    "last_checked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_check_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_response_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "domain_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /uptime/checks/:id.json 가동 시간 검사 조회: 24시간, 7일, 30일 가동률, 응답 시간, 인시던트 uptime_checks_get

권한: analytics.read

예시
curl https://privatusanalytics.com/uptime/checks/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "range": {
      "type": "string",
      "description": "응답 시간 차트의 구간",
      "enum": [
        "24h",
        "7d",
        "30d"
      ],
      "default": "24h"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "check": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "검사 ID (upc_…)"
        },
        "workspace_id": {
          "type": "string"
        },
        "site_id": {
          "anyOf": [
            {
              "type": "string",
              "description": "검사가 속한 사이트"
            },
            {
              "type": "null"
            }
          ]
        },
        "name": {
          "type": "string"
        },
        "kind": {
          "type": "string",
          "description": "http, keyword, tcp 또는 dns"
        },
        "url": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "host": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "port": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ]
        },
        "keyword": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "expected_status": {
          "type": "integer"
        },
        "http_method": {
          "type": "string"
        },
        "interval_seconds": {
          "type": "integer"
        },
        "timeout_seconds": {
          "type": "integer"
        },
        "status": {
          "type": "string",
          "description": "up, down, pending 또는 paused"
        },
        "enabled": {
          "type": "boolean"
        },
        "public": {
          "type": "boolean",
          "description": "상태 페이지에 표시될 수 있음"
        },
        "last_checked_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time"
            },
            {
              "type": "null"
            }
          ]
        },
        "next_check_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time"
            },
            {
              "type": "null"
            }
          ]
        },
        "last_response_ms": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ]
        },
        "ssl_expires_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time"
            },
            {
              "type": "null"
            }
          ]
        },
        "ssl_issuer": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "domain_expires_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time"
            },
            {
              "type": "null"
            }
          ]
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        }
      }
    },
    "uptime": {
      "type": "object",
      "description": "24시간, 7일, 30일 가동률 (%)"
    },
    "range": {
      "type": "string",
      "description": "response_times의 구간"
    },
    "response_times": {
      "type": "object",
      "description": "구간별 평균 응답 시간 (ms): {unit, labels, series: {location: [ms…]}}"
    },
    "incidents": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "started_at": {
            "type": "string",
            "format": "date-time"
          },
          "resolved_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ]
          },
          "duration_seconds": {
            "type": "integer",
            "description": "아직 진행 중이면 현재까지의 시간"
          },
          "cause": {
            "anyOf": [
              {
                "type": "string",
                "description": "가장 흔한 오류, 예: timeout 또는 status_503"
              },
              {
                "type": "null"
              }
            ]
          },
          "failed_locations": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      }
    }
  }
}
PATCH /uptime/checks/:id.json 가동 시간 검사 변경 uptime_checks_update

권한: uptime.manage

예시
curl -X PATCH https://privatusanalytics.com/uptime/checks/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "표시 이름 (기본값은 대상)"
    },
    "kind": {
      "type": "string",
      "description": "http (상태 코드), keyword (본문에 포함), tcp (host:port) 또는 dns (이름 확인)",
      "enum": [
        "http",
        "keyword",
        "tcp",
        "dns"
      ]
    },
    "url": {
      "type": "string",
      "description": "http/keyword 검사용 URL",
      "examples": [
        "https://example.com/health"
      ]
    },
    "host": {
      "type": "string",
      "description": "tcp/dns 검사용 호스트명"
    },
    "port": {
      "type": "integer",
      "description": "tcp 검사용 TCP 포트"
    },
    "keyword": {
      "type": "string",
      "description": "응답 본문에 포함되어야 하는 텍스트 (keyword)"
    },
    "expected_status": {
      "type": "integer",
      "description": "예상 HTTP 상태 코드"
    },
    "http_method": {
      "type": "string",
      "description": "HTTP 메서드",
      "enum": [
        "GET",
        "HEAD"
      ]
    },
    "interval_seconds": {
      "type": "integer",
      "description": "검사 간격 (초, 요금제 최솟값 적용, 기본값 300 또는 최솟값)"
    },
    "timeout_seconds": {
      "type": "integer",
      "description": "프로브가 시간 초과되기까지의 시간 (초, 1-30)"
    },
    "public": {
      "type": "boolean",
      "description": "공개 상태 페이지에 표시될 수 있음"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "검사 ID (upc_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "검사가 속한 사이트"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "http, keyword, tcp 또는 dns"
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "host": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "port": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "keyword": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expected_status": {
      "type": "integer"
    },
    "http_method": {
      "type": "string"
    },
    "interval_seconds": {
      "type": "integer"
    },
    "timeout_seconds": {
      "type": "integer"
    },
    "status": {
      "type": "string",
      "description": "up, down, pending 또는 paused"
    },
    "enabled": {
      "type": "boolean"
    },
    "public": {
      "type": "boolean",
      "description": "상태 페이지에 표시될 수 있음"
    },
    "last_checked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_check_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_response_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "domain_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /uptime/probes.json 프로브 데이터센터, User-Agent, 송신 IP 범위 (가동 시간 프로브를 허용 목록에 추가할 때 사용) uptime_probes_list

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/uptime/probes.json
입력
{
  "type": "object",
  "properties": {},
  "required": []
}
응답 데이터
{
  "type": "object"
}
POST /uptime/probes/results.json 외부 프로브 에이전트의 결과 제출 (Bearer 가동 시간 프로브 토큰) uptime_probes_results

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/uptime/probes/results.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "results": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "check_id": {
            "type": "string"
          },
          "location": {
            "type": "string"
          },
          "ok": {
            "type": "boolean"
          },
          "status_code": {
            "type": "integer"
          },
          "response_ms": {
            "type": "integer"
          },
          "error": {
            "type": "string"
          },
          "checked_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "description": "프로브 결과: [{check_id, location, ok, status_code, response_ms, error, checked_at}]"
    }
  },
  "required": [
    "results"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /workspaces/:workspace_id/uptime.json 워크스페이스 가동 시간 검사 추가 (사이트에 연결되지 않음) workspace_uptime_checks_create

권한: uptime.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/uptime.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "표시 이름 (기본값은 대상)"
    },
    "kind": {
      "type": "string",
      "description": "http (상태 코드), keyword (본문에 포함), tcp (host:port) 또는 dns (이름 확인)",
      "enum": [
        "http",
        "keyword",
        "tcp",
        "dns"
      ],
      "default": "http"
    },
    "url": {
      "type": "string",
      "description": "http/keyword 검사용 URL",
      "examples": [
        "https://example.com/health"
      ]
    },
    "host": {
      "type": "string",
      "description": "tcp/dns 검사용 호스트명"
    },
    "port": {
      "type": "integer",
      "description": "tcp 검사용 TCP 포트"
    },
    "keyword": {
      "type": "string",
      "description": "응답 본문에 포함되어야 하는 텍스트 (keyword)"
    },
    "expected_status": {
      "type": "integer",
      "description": "예상 HTTP 상태 코드",
      "default": 200
    },
    "http_method": {
      "type": "string",
      "description": "HTTP 메서드",
      "enum": [
        "GET",
        "HEAD"
      ],
      "default": "GET"
    },
    "interval_seconds": {
      "type": "integer",
      "description": "검사 간격 (초, 요금제 최솟값 적용, 기본값 300 또는 최솟값)"
    },
    "timeout_seconds": {
      "type": "integer",
      "description": "프로브가 시간 초과되기까지의 시간 (초, 1-30)",
      "default": 20
    },
    "public": {
      "type": "boolean",
      "description": "공개 상태 페이지에 표시될 수 있음",
      "default": false
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "검사 ID (upc_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "검사가 속한 사이트"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "http, keyword, tcp 또는 dns"
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "host": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "port": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "keyword": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expected_status": {
      "type": "integer"
    },
    "http_method": {
      "type": "string"
    },
    "interval_seconds": {
      "type": "integer"
    },
    "timeout_seconds": {
      "type": "integer"
    },
    "status": {
      "type": "string",
      "description": "up, down, pending 또는 paused"
    },
    "enabled": {
      "type": "boolean"
    },
    "public": {
      "type": "boolean",
      "description": "상태 페이지에 표시될 수 있음"
    },
    "last_checked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_check_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_response_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "ssl_issuer": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "domain_expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/uptime.json 워크스페이스의 모든 가동 시간 검사 목록 보기 workspace_uptime_checks_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/uptime.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "이 상태의 검사만",
      "enum": [
        "up",
        "down",
        "pending",
        "paused"
      ]
    },
    "query": {
      "type": "string",
      "description": "이름 또는 대상으로 필터링"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "검사 ID (upc_…)"
      },
      "workspace_id": {
        "type": "string"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "검사가 속한 사이트"
          },
          {
            "type": "null"
          }
        ]
      },
      "name": {
        "type": "string"
      },
      "kind": {
        "type": "string",
        "description": "http, keyword, tcp 또는 dns"
      },
      "url": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "host": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "port": {
        "anyOf": [
          {
            "type": "integer"
          },
          {
            "type": "null"
          }
        ]
      },
      "keyword": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "expected_status": {
        "type": "integer"
      },
      "http_method": {
        "type": "string"
      },
      "interval_seconds": {
        "type": "integer"
      },
      "timeout_seconds": {
        "type": "integer"
      },
      "status": {
        "type": "string",
        "description": "up, down, pending 또는 paused"
      },
      "enabled": {
        "type": "boolean"
      },
      "public": {
        "type": "boolean",
        "description": "상태 페이지에 표시될 수 있음"
      },
      "last_checked_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "next_check_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_response_ms": {
        "anyOf": [
          {
            "type": "integer"
          },
          {
            "type": "null"
          }
        ]
      },
      "ssl_expires_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "ssl_issuer": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "domain_expires_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}

가져오기

GET /sites/:site_id/imports/google/properties.json 가져올 수 있는 Google Analytics 4 속성 목록 보기 imports_google_properties

권한: sites.manage

예시
curl https://privatusanalytics.com/sites/:site_id/imports/google/properties.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /sites/:site_id/imports.json 가져오기 시작 (GA4 속성 또는 CSV 업로드) imports_create

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/imports.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "source": {
      "type": "string",
      "description": "ga4 (Google Analytics 4 API) 또는 CSV 내보내기를 업로드하는 도구",
      "enum": [
        "ga4",
        "universal_analytics",
        "fathom",
        "simple_analytics",
        "plausible",
        "matomo",
        "umami",
        "clicky"
      ]
    },
    "property_id": {
      "type": "string",
      "description": "GA4 속성, 예: properties/123 (imports_google_properties 참고). ga4에 필수",
      "examples": [
        "properties/123456789"
      ]
    },
    "date_from": {
      "type": "string",
      "format": "date",
      "description": "가져올 첫째 날. ga4에 필수. 날짜 열이 없는 CSV 파일은 모든 행이 이 날짜로 기록됨"
    },
    "date_to": {
      "type": "string",
      "format": "date",
      "description": "가져올 마지막 날 (ga4는 첫 추적 이벤트 전날 또는 어제가 기본값)"
    },
    "file": {
      "type": "string",
      "format": "binary",
      "description": "CSV 내보내기 (멀티파트 업로드, 최대 50 MB). CSV 소스에 필수"
    },
    "dimension": {
      "type": "string",
      "description": "CSV 행이 세부 분석하는 대상 (감지를 덮어씀, Matomo \"Label\" 내보내기에 필요)",
      "enum": [
        "total",
        "page",
        "source",
        "country",
        "device",
        "browser",
        "os"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "source",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "가져오기 ID"
    },
    "site_id": {
      "type": "string"
    },
    "source": {
      "type": "string",
      "description": "ga4, universal_analytics, fathom, simple_analytics, plausible, matomo, umami 또는 clicky"
    },
    "status": {
      "type": "string",
      "description": "queued, running, complete 또는 failed"
    },
    "date_from": {
      "anyOf": [
        {
          "type": "string",
          "format": "date",
          "description": "가져온 첫째 날"
        },
        {
          "type": "null"
        }
      ]
    },
    "date_to": {
      "anyOf": [
        {
          "type": "string",
          "format": "date",
          "description": "가져온 마지막 날"
        },
        {
          "type": "null"
        }
      ]
    },
    "rows_imported": {
      "type": "integer",
      "description": "저장된 일별 행"
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "가져오기가 실패한 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "completed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/imports/:id.json 가져오기와 가져온 모든 데이터 삭제 imports_delete

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/imports/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "가져오기 ID"
    },
    "site_id": {
      "type": "string"
    },
    "source": {
      "type": "string",
      "description": "ga4, universal_analytics, fathom, simple_analytics, plausible, matomo, umami 또는 clicky"
    },
    "status": {
      "type": "string",
      "description": "queued, running, complete 또는 failed"
    },
    "date_from": {
      "anyOf": [
        {
          "type": "string",
          "format": "date",
          "description": "가져온 첫째 날"
        },
        {
          "type": "null"
        }
      ]
    },
    "date_to": {
      "anyOf": [
        {
          "type": "string",
          "format": "date",
          "description": "가져온 마지막 날"
        },
        {
          "type": "null"
        }
      ]
    },
    "rows_imported": {
      "type": "integer",
      "description": "저장된 일별 행"
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "가져오기가 실패한 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "completed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/imports.json 사이트의 가져오기 목록 보기 imports_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/imports.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "이 상태의 가져오기만",
      "enum": [
        "queued",
        "running",
        "complete",
        "failed"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "가져오기 ID"
      },
      "site_id": {
        "type": "string"
      },
      "source": {
        "type": "string",
        "description": "ga4, universal_analytics, fathom, simple_analytics, plausible, matomo, umami 또는 clicky"
      },
      "status": {
        "type": "string",
        "description": "queued, running, complete 또는 failed"
      },
      "date_from": {
        "anyOf": [
          {
            "type": "string",
            "format": "date",
            "description": "가져온 첫째 날"
          },
          {
            "type": "null"
          }
        ]
      },
      "date_to": {
        "anyOf": [
          {
            "type": "string",
            "format": "date",
            "description": "가져온 마지막 날"
          },
          {
            "type": "null"
          }
        ]
      },
      "rows_imported": {
        "type": "integer",
        "description": "저장된 일별 행"
      },
      "error": {
        "anyOf": [
          {
            "type": "string",
            "description": "가져오기가 실패한 이유"
          },
          {
            "type": "null"
          }
        ]
      },
      "completed_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /sites/:site_id/imports/:id.json 가져오기와 상태 조회 imports_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/imports/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "가져오기 ID"
    },
    "site_id": {
      "type": "string"
    },
    "source": {
      "type": "string",
      "description": "ga4, universal_analytics, fathom, simple_analytics, plausible, matomo, umami 또는 clicky"
    },
    "status": {
      "type": "string",
      "description": "queued, running, complete 또는 failed"
    },
    "date_from": {
      "anyOf": [
        {
          "type": "string",
          "format": "date",
          "description": "가져온 첫째 날"
        },
        {
          "type": "null"
        }
      ]
    },
    "date_to": {
      "anyOf": [
        {
          "type": "string",
          "format": "date",
          "description": "가져온 마지막 날"
        },
        {
          "type": "null"
        }
      ]
    },
    "rows_imported": {
      "type": "integer",
      "description": "저장된 일별 행"
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "가져오기가 실패한 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "completed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

감사 로그

GET /workspaces/:workspace_id/audit_log.json 감사 로그 항목 목록 보기 (.csv를 붙여 내보내기) audit_logs_get

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/audit_log.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "actor": {
      "type": "string",
      "description": "이 멤버(이메일)가 한 변경만"
    },
    "item_type": {
      "type": "string",
      "description": "이 종류의 레코드만, 예: Site"
    },
    "event": {
      "type": "string",
      "description": "이 작업만",
      "enum": [
        "create",
        "update",
        "destroy"
      ]
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "시작 날짜 (포함)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "종료 날짜 (포함)"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid"
      },
      "created_at": {
        "type": "string",
        "format": "date-time",
        "description": "시각"
      },
      "event": {
        "type": "string",
        "description": "create, update 또는 destroy"
      },
      "item_type": {
        "type": "string",
        "description": "레코드 종류, 예: Site"
      },
      "item_id": {
        "type": "string",
        "format": "uuid"
      },
      "target": {
        "type": "string",
        "description": "알려진 경우 이름으로 표시한 레코드"
      },
      "actor_email": {
        "anyOf": [
          {
            "type": "string",
            "description": "변경한 멤버"
          },
          {
            "type": "null"
          }
        ]
      },
      "actor_name": {
        "type": "string"
      },
      "token_name": {
        "anyOf": [
          {
            "type": "string",
            "description": "사용한 API 토큰 (있는 경우)"
          },
          {
            "type": "null"
          }
        ]
      },
      "changes": {
        "type": "object",
        "description": "변경된 필드: { field: [before, after] }"
      },
      "ip": {
        "anyOf": [
          {
            "type": "string",
            "description": "멤버의 IP 주소"
          },
          {
            "type": "null"
          }
        ]
      }
    }
  }
}

검색

GET /sites/:site_id/search.json 검색 리포트: 클릭, 노출, CTR, 순위, 상위 검색어 및 페이지, 방문 페이지, 기회 search_report

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/search.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "provider": {
      "type": "string",
      "description": "google (Search Console) 또는 bing",
      "enum": [
        "google",
        "bing"
      ],
      "default": "google"
    },
    "limit": {
      "type": "integer",
      "description": "표당 행 수 (최대 100)",
      "default": 25
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /sites/:site_id/search/connections.json Search Console 속성 또는 Bing 사이트 연결 search_connect

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/search/connections.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "provider": {
      "type": "string",
      "description": "google 또는 bing",
      "enum": [
        "google",
        "bing"
      ],
      "default": "google"
    },
    "property": {
      "type": "string",
      "description": "Search Console 속성 (예: sc-domain:example.com) 또는 Bing 사이트 URL",
      "examples": [
        "sc-domain:example.com"
      ]
    },
    "bing_api_key": {
      "type": "string",
      "description": "본인의 Bing Webmaster Tools API 키 (Settings > API access). provider가 bing일 때 필수입니다. 암호화하여 저장하며 다시 반환하지 않습니다."
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "property",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "provider": {
      "type": "string",
      "description": "google 또는 bing"
    },
    "property": {
      "type": "string",
      "description": "Search Console 속성 또는 Bing 사이트 URL"
    },
    "status": {
      "type": "string",
      "description": "active 또는 error"
    },
    "last_synced_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/search/connections/:provider.json Search Console 또는 Bing 연결 해제 및 데이터 삭제 search_disconnect

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/search/connections/:provider.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "provider": {
      "type": "string",
      "description": "리소스의 Provider"
    }
  },
  "required": [
    "site_id",
    "provider"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "provider": {
      "type": "string",
      "description": "google 또는 bing"
    },
    "property": {
      "type": "string",
      "description": "Search Console 속성 또는 Bing 사이트 URL"
    },
    "status": {
      "type": "string",
      "description": "active 또는 error"
    },
    "last_synced_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/search/properties.json 연결할 수 있는 속성 목록 보기 (Search Console은 브라우저에서 Google 권한 부여 필요) search_properties

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/search/properties.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "provider": {
      "type": "string",
      "description": "google 또는 bing",
      "enum": [
        "google",
        "bing"
      ],
      "default": "google"
    },
    "bing_api_key": {
      "type": "string",
      "description": "본인의 Bing Webmaster Tools API 키 (Settings > API access). provider가 bing일 때 필수입니다. 키로 볼 수 있는 사이트 목록을 가져오는 데만 사용합니다."
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /sites/:site_id/search/sync.json 지금 검색 데이터 가져오기 search_sync

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/search/sync.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "provider": {
      "type": "string",
      "description": "google 또는 bing",
      "enum": [
        "google",
        "bing"
      ],
      "default": "google"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "provider": {
      "type": "string",
      "description": "google 또는 bing"
    },
    "property": {
      "type": "string",
      "description": "Search Console 속성 또는 Bing 사이트 URL"
    },
    "status": {
      "type": "string",
      "description": "active 또는 error"
    },
    "last_synced_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

결제

POST /workspaces/:workspace_id/billing/badge.json 배지 보너스 사용 여부 설정 (무료 요금제) billing_badge

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/badge.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "enabled": {
      "type": "boolean",
      "description": "배지를 인증하고 보너스를 받으려면 true"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "enabled",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "유료 티어의 월간 이벤트 수"
    },
    "allowance": {
      "type": "integer",
      "description": "배지 보너스를 포함한 월간 이벤트 수"
    },
    "billing_interval": {
      "anyOf": [
        {
          "type": "string",
          "description": "month 또는 year"
        },
        {
          "type": "null"
        }
      ]
    },
    "price": {
      "anyOf": [
        {
          "type": "integer",
          "description": "결제 주기당 USD"
        },
        {
          "type": "null"
        }
      ]
    },
    "subscription_status": {
      "type": "string",
      "description": "none, trialing, active, past_due, paused 또는 canceled"
    },
    "current_period_ends_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "갱신 또는 종료 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "canceled_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "auto_upgrade": {
      "type": "boolean"
    },
    "discount": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "program": {
              "type": "string",
              "description": "nonprofit, education, open_source, open_source_free 또는 agency"
            },
            "status": {
              "type": "string",
              "description": "pending, approved (아직 구독에 적용되지 않음), active, rejected 또는 revoked"
            },
            "percent": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "Pro와 Business 할인율 (무료 오픈 소스 프로그램은 null)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "comp_events": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "월간 무료 이벤트 (무료 오픈 소스 프로그램만)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "organization_name": {
              "type": "string",
              "description": "단체, 학교, 프로젝트 또는 에이전시 이름"
            },
            "website": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "웹사이트"
                },
                {
                  "type": "null"
                }
              ]
            },
            "proof_url": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "증빙 링크 또는 저장소 URL"
                },
                {
                  "type": "null"
                }
              ]
            },
            "license": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "OSI 라이선스 (오픈 소스)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "note": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "심사를 위한 메모"
                },
                {
                  "type": "null"
                }
              ]
            },
            "rejection_reason": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "신청이 승인되지 않은 이유"
                },
                {
                  "type": "null"
                }
              ]
            },
            "created_at": {
              "type": "string",
              "format": "date-time",
              "description": "신청 시각"
            },
            "reviewed_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "심사 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "applied_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "할인 적용 시작 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "revoked_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "프로그램 종료 시각"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "가장 최근의 할인 프로그램 신청, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "discount_percent": {
      "anyOf": [
        {
          "type": "integer",
          "description": "승인된 프로그램에 따른 Pro와 Business 할인율, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "billing_emails": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "tax_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "badge": {
      "type": "object",
      "description": "배지 보너스 (무료 요금제)"
    },
    "usage": {
      "type": "object",
      "properties": {
        "month": {
          "type": "string",
          "format": "date",
          "description": "보고 대상 월의 첫째 날"
        },
        "events": {
          "type": "integer",
          "description": "과금 대상 이벤트 (페이지뷰와 사용자 지정 이벤트)"
        },
        "bots": {
          "type": "integer",
          "description": "걸러낸 봇 히트 (과금 안 됨)"
        },
        "allowance": {
          "type": "integer",
          "description": "포함된 이벤트, 배지 보너스 포함"
        },
        "percent": {
          "type": "number",
          "description": "허용량 대비 이벤트 비율"
        },
        "forecast": {
          "anyOf": [
            {
              "type": "integer",
              "description": "월말 예상 이벤트 수"
            },
            {
              "type": "null"
            }
          ]
        },
        "forecast_percent": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ]
        },
        "days_left": {
          "type": "integer",
          "description": "이번 달 남은 일수"
        },
        "status": {
          "type": "string",
          "description": "ok, warning (80% 이상), over (허용량에 도달했거나 넘은 지난 달), locked 또는 paused"
        },
        "sites": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "site_id": {
                "type": "string"
              },
              "domain": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "events": {
                "type": "integer",
                "description": "이번 달 페이지뷰와 사용자 지정 이벤트"
              },
              "share": {
                "type": "number",
                "description": "워크스페이스 전체 대비 비율 (%)"
              }
            }
          },
          "description": "사이트별 이벤트"
        },
        "history": {
          "type": "array",
          "description": "이전 달, 최신순"
        },
        "access_locked_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "Privatus 직원이 대시보드를 잠근 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused": {
          "type": "boolean",
          "description": "새 이벤트가 버려지는 동안 true (월간 한도에 도달했거나 직원이 수집을 일시 중지함)"
        },
        "pause_reason": {
          "anyOf": [
            {
              "type": "string",
              "description": "수집이 일시 중지된 이유: limit (월간 허용량 도달) 또는 staff. 수집 중이면 null"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "직원이 수집을 일시 중지한 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "resumes_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "한도로 인한 일시 중지가 풀리는 시각: 다음 달 시작 (UTC), 업그레이드하면 더 일찍. 그 외에는 null"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "description": "이번 달 현재까지"
    }
  }
}
POST /workspaces/:workspace_id/billing/cancel.json 결제 기간 종료 시 해지 billing_cancel

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/cancel.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "reason": {
      "type": "string",
      "description": "해지하는 주된 이유 (선택 설문)",
      "enum": [
        "too_expensive",
        "missing_features",
        "switching_tool",
        "not_using",
        "temporary",
        "other"
      ]
    },
    "comment": {
      "type": "string",
      "description": "개선할 점이 있다면 알려 주세요"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "유료 티어의 월간 이벤트 수"
    },
    "allowance": {
      "type": "integer",
      "description": "배지 보너스를 포함한 월간 이벤트 수"
    },
    "billing_interval": {
      "anyOf": [
        {
          "type": "string",
          "description": "month 또는 year"
        },
        {
          "type": "null"
        }
      ]
    },
    "price": {
      "anyOf": [
        {
          "type": "integer",
          "description": "결제 주기당 USD"
        },
        {
          "type": "null"
        }
      ]
    },
    "subscription_status": {
      "type": "string",
      "description": "none, trialing, active, past_due, paused 또는 canceled"
    },
    "current_period_ends_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "갱신 또는 종료 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "canceled_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "auto_upgrade": {
      "type": "boolean"
    },
    "discount": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "program": {
              "type": "string",
              "description": "nonprofit, education, open_source, open_source_free 또는 agency"
            },
            "status": {
              "type": "string",
              "description": "pending, approved (아직 구독에 적용되지 않음), active, rejected 또는 revoked"
            },
            "percent": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "Pro와 Business 할인율 (무료 오픈 소스 프로그램은 null)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "comp_events": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "월간 무료 이벤트 (무료 오픈 소스 프로그램만)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "organization_name": {
              "type": "string",
              "description": "단체, 학교, 프로젝트 또는 에이전시 이름"
            },
            "website": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "웹사이트"
                },
                {
                  "type": "null"
                }
              ]
            },
            "proof_url": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "증빙 링크 또는 저장소 URL"
                },
                {
                  "type": "null"
                }
              ]
            },
            "license": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "OSI 라이선스 (오픈 소스)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "note": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "심사를 위한 메모"
                },
                {
                  "type": "null"
                }
              ]
            },
            "rejection_reason": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "신청이 승인되지 않은 이유"
                },
                {
                  "type": "null"
                }
              ]
            },
            "created_at": {
              "type": "string",
              "format": "date-time",
              "description": "신청 시각"
            },
            "reviewed_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "심사 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "applied_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "할인 적용 시작 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "revoked_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "프로그램 종료 시각"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "가장 최근의 할인 프로그램 신청, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "discount_percent": {
      "anyOf": [
        {
          "type": "integer",
          "description": "승인된 프로그램에 따른 Pro와 Business 할인율, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "billing_emails": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "tax_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "badge": {
      "type": "object",
      "description": "배지 보너스 (무료 요금제)"
    },
    "usage": {
      "type": "object",
      "properties": {
        "month": {
          "type": "string",
          "format": "date",
          "description": "보고 대상 월의 첫째 날"
        },
        "events": {
          "type": "integer",
          "description": "과금 대상 이벤트 (페이지뷰와 사용자 지정 이벤트)"
        },
        "bots": {
          "type": "integer",
          "description": "걸러낸 봇 히트 (과금 안 됨)"
        },
        "allowance": {
          "type": "integer",
          "description": "포함된 이벤트, 배지 보너스 포함"
        },
        "percent": {
          "type": "number",
          "description": "허용량 대비 이벤트 비율"
        },
        "forecast": {
          "anyOf": [
            {
              "type": "integer",
              "description": "월말 예상 이벤트 수"
            },
            {
              "type": "null"
            }
          ]
        },
        "forecast_percent": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ]
        },
        "days_left": {
          "type": "integer",
          "description": "이번 달 남은 일수"
        },
        "status": {
          "type": "string",
          "description": "ok, warning (80% 이상), over (허용량에 도달했거나 넘은 지난 달), locked 또는 paused"
        },
        "sites": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "site_id": {
                "type": "string"
              },
              "domain": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "events": {
                "type": "integer",
                "description": "이번 달 페이지뷰와 사용자 지정 이벤트"
              },
              "share": {
                "type": "number",
                "description": "워크스페이스 전체 대비 비율 (%)"
              }
            }
          },
          "description": "사이트별 이벤트"
        },
        "history": {
          "type": "array",
          "description": "이전 달, 최신순"
        },
        "access_locked_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "Privatus 직원이 대시보드를 잠근 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused": {
          "type": "boolean",
          "description": "새 이벤트가 버려지는 동안 true (월간 한도에 도달했거나 직원이 수집을 일시 중지함)"
        },
        "pause_reason": {
          "anyOf": [
            {
              "type": "string",
              "description": "수집이 일시 중지된 이유: limit (월간 허용량 도달) 또는 staff. 수집 중이면 null"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "직원이 수집을 일시 중지한 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "resumes_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "한도로 인한 일시 중지가 풀리는 시각: 다음 달 시작 (UTC), 업그레이드하면 더 일찍. 그 외에는 null"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "description": "이번 달 현재까지"
    }
  }
}
POST /workspaces/:workspace_id/billing/change_plan.json 요금제, 티어 또는 주기 변경 (일할 계산) billing_change_plan

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/change_plan.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "plan": {
      "type": "string",
      "description": "변경할 요금제: pro 또는 business",
      "enum": [
        "pro",
        "business"
      ]
    },
    "events": {
      "type": "integer",
      "description": "티어의 월간 이벤트 수, GET /plans에서 확인",
      "examples": [
        1000000
      ]
    },
    "interval": {
      "type": "string",
      "description": "결제 주기. 연간은 2개월 무료",
      "enum": [
        "month",
        "year"
      ],
      "default": "month"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "plan",
    "events",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "유료 티어의 월간 이벤트 수"
    },
    "allowance": {
      "type": "integer",
      "description": "배지 보너스를 포함한 월간 이벤트 수"
    },
    "billing_interval": {
      "anyOf": [
        {
          "type": "string",
          "description": "month 또는 year"
        },
        {
          "type": "null"
        }
      ]
    },
    "price": {
      "anyOf": [
        {
          "type": "integer",
          "description": "결제 주기당 USD"
        },
        {
          "type": "null"
        }
      ]
    },
    "subscription_status": {
      "type": "string",
      "description": "none, trialing, active, past_due, paused 또는 canceled"
    },
    "current_period_ends_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "갱신 또는 종료 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "canceled_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "auto_upgrade": {
      "type": "boolean"
    },
    "discount": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "program": {
              "type": "string",
              "description": "nonprofit, education, open_source, open_source_free 또는 agency"
            },
            "status": {
              "type": "string",
              "description": "pending, approved (아직 구독에 적용되지 않음), active, rejected 또는 revoked"
            },
            "percent": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "Pro와 Business 할인율 (무료 오픈 소스 프로그램은 null)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "comp_events": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "월간 무료 이벤트 (무료 오픈 소스 프로그램만)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "organization_name": {
              "type": "string",
              "description": "단체, 학교, 프로젝트 또는 에이전시 이름"
            },
            "website": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "웹사이트"
                },
                {
                  "type": "null"
                }
              ]
            },
            "proof_url": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "증빙 링크 또는 저장소 URL"
                },
                {
                  "type": "null"
                }
              ]
            },
            "license": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "OSI 라이선스 (오픈 소스)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "note": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "심사를 위한 메모"
                },
                {
                  "type": "null"
                }
              ]
            },
            "rejection_reason": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "신청이 승인되지 않은 이유"
                },
                {
                  "type": "null"
                }
              ]
            },
            "created_at": {
              "type": "string",
              "format": "date-time",
              "description": "신청 시각"
            },
            "reviewed_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "심사 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "applied_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "할인 적용 시작 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "revoked_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "프로그램 종료 시각"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "가장 최근의 할인 프로그램 신청, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "discount_percent": {
      "anyOf": [
        {
          "type": "integer",
          "description": "승인된 프로그램에 따른 Pro와 Business 할인율, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "billing_emails": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "tax_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "badge": {
      "type": "object",
      "description": "배지 보너스 (무료 요금제)"
    },
    "usage": {
      "type": "object",
      "properties": {
        "month": {
          "type": "string",
          "format": "date",
          "description": "보고 대상 월의 첫째 날"
        },
        "events": {
          "type": "integer",
          "description": "과금 대상 이벤트 (페이지뷰와 사용자 지정 이벤트)"
        },
        "bots": {
          "type": "integer",
          "description": "걸러낸 봇 히트 (과금 안 됨)"
        },
        "allowance": {
          "type": "integer",
          "description": "포함된 이벤트, 배지 보너스 포함"
        },
        "percent": {
          "type": "number",
          "description": "허용량 대비 이벤트 비율"
        },
        "forecast": {
          "anyOf": [
            {
              "type": "integer",
              "description": "월말 예상 이벤트 수"
            },
            {
              "type": "null"
            }
          ]
        },
        "forecast_percent": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ]
        },
        "days_left": {
          "type": "integer",
          "description": "이번 달 남은 일수"
        },
        "status": {
          "type": "string",
          "description": "ok, warning (80% 이상), over (허용량에 도달했거나 넘은 지난 달), locked 또는 paused"
        },
        "sites": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "site_id": {
                "type": "string"
              },
              "domain": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "events": {
                "type": "integer",
                "description": "이번 달 페이지뷰와 사용자 지정 이벤트"
              },
              "share": {
                "type": "number",
                "description": "워크스페이스 전체 대비 비율 (%)"
              }
            }
          },
          "description": "사이트별 이벤트"
        },
        "history": {
          "type": "array",
          "description": "이전 달, 최신순"
        },
        "access_locked_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "Privatus 직원이 대시보드를 잠근 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused": {
          "type": "boolean",
          "description": "새 이벤트가 버려지는 동안 true (월간 한도에 도달했거나 직원이 수집을 일시 중지함)"
        },
        "pause_reason": {
          "anyOf": [
            {
              "type": "string",
              "description": "수집이 일시 중지된 이유: limit (월간 허용량 도달) 또는 staff. 수집 중이면 null"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "직원이 수집을 일시 중지한 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "resumes_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "한도로 인한 일시 중지가 풀리는 시각: 다음 달 시작 (UTC), 업그레이드하면 더 일찍. 그 외에는 null"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "description": "이번 달 현재까지"
    }
  }
}
POST /workspaces/:workspace_id/billing/checkout.json 유료 요금제의 Paddle 결제 시작 billing_checkout

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/checkout.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "plan": {
      "type": "string",
      "description": "변경할 요금제: pro 또는 business",
      "enum": [
        "pro",
        "business"
      ]
    },
    "events": {
      "type": "integer",
      "description": "티어의 월간 이벤트 수, GET /plans에서 확인",
      "examples": [
        1000000
      ]
    },
    "interval": {
      "type": "string",
      "description": "결제 주기. 연간은 2개월 무료",
      "enum": [
        "month",
        "year"
      ],
      "default": "month"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "plan",
    "events",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "transaction_id": {
      "type": "string",
      "description": "Paddle 트랜잭션 ID (txn_...)"
    },
    "url": {
      "anyOf": [
        {
          "type": "string",
          "description": "호스팅 결제 URL"
        },
        {
          "type": "null"
        }
      ]
    },
    "price_id": {
      "type": "string"
    },
    "plan": {
      "type": "string"
    },
    "events": {
      "type": "integer"
    },
    "interval": {
      "type": "string"
    },
    "amount": {
      "type": "integer",
      "description": "주기당 USD"
    },
    "client_token": {
      "anyOf": [
        {
          "type": "string",
          "description": "Paddle.js 클라이언트 측 토큰"
        },
        {
          "type": "null"
        }
      ]
    },
    "environment": {
      "type": "string",
      "description": "sandbox 또는 production"
    },
    "custom_data": {
      "type": "object",
      "description": "구독을 연결하기 위해 Paddle에 전달됨"
    },
    "discount_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "승인된 프로그램의 Paddle 할인 ID, 이 체크아웃에 적용됨"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /workspaces/:workspace_id/billing/discount.json 비영리, 교육 또는 오픈 소스 할인 신청 billing_discount

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/discount.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "program": {
      "type": "string",
      "description": "nonprofit, education, open_source (50% 할인), open_source_free (월 이벤트 100만 개까지 Pro 무료) 또는 agency (소유한 모든 워크스페이스 20% 할인)",
      "enum": [
        "nonprofit",
        "education",
        "open_source",
        "open_source_free",
        "agency"
      ]
    },
    "organization_name": {
      "type": "string",
      "description": "단체, 학교, 프로젝트 또는 에이전시의 이름"
    },
    "website": {
      "type": "string",
      "description": "해당 웹사이트"
    },
    "proof_url": {
      "type": "string",
      "description": "증빙 링크. 오픈 소스의 경우 저장소 URL"
    },
    "license": {
      "type": "string",
      "description": "프로젝트의 OSI 라이선스 (오픈 소스만 해당)"
    },
    "note": {
      "type": "string",
      "description": "심사에 도움이 되는 내용, 최대 1,000자"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "program",
    "organization_name",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "program": {
      "type": "string",
      "description": "nonprofit, education, open_source, open_source_free 또는 agency"
    },
    "status": {
      "type": "string",
      "description": "pending, approved (아직 구독에 적용되지 않음), active, rejected 또는 revoked"
    },
    "percent": {
      "anyOf": [
        {
          "type": "integer",
          "description": "Pro와 Business 할인율 (무료 오픈 소스 프로그램은 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "comp_events": {
      "anyOf": [
        {
          "type": "integer",
          "description": "월간 무료 이벤트 (무료 오픈 소스 프로그램만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "organization_name": {
      "type": "string",
      "description": "단체, 학교, 프로젝트 또는 에이전시 이름"
    },
    "website": {
      "anyOf": [
        {
          "type": "string",
          "description": "웹사이트"
        },
        {
          "type": "null"
        }
      ]
    },
    "proof_url": {
      "anyOf": [
        {
          "type": "string",
          "description": "증빙 링크 또는 저장소 URL"
        },
        {
          "type": "null"
        }
      ]
    },
    "license": {
      "anyOf": [
        {
          "type": "string",
          "description": "OSI 라이선스 (오픈 소스)"
        },
        {
          "type": "null"
        }
      ]
    },
    "note": {
      "anyOf": [
        {
          "type": "string",
          "description": "심사를 위한 메모"
        },
        {
          "type": "null"
        }
      ]
    },
    "rejection_reason": {
      "anyOf": [
        {
          "type": "string",
          "description": "신청이 승인되지 않은 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time",
      "description": "신청 시각"
    },
    "reviewed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "심사 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "applied_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "할인 적용 시작 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "revoked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "프로그램 종료 시각"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /workspaces/:workspace_id/billing/payment_method.json 결제 수단 업데이트 링크 받기 billing_payment_method

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/payment_method.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "kind": {
      "type": "string",
      "description": "portal, payment_method 또는 invoice"
    },
    "url": {
      "anyOf": [
        {
          "type": "string",
          "description": "유효 기간이 짧은 Paddle URL"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /workspaces/:workspace_id/billing/portal.json Paddle 고객 포털 링크 받기 billing_portal

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/portal.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "kind": {
      "type": "string",
      "description": "portal, payment_method 또는 invoice"
    },
    "url": {
      "anyOf": [
        {
          "type": "string",
          "description": "유효 기간이 짧은 Paddle URL"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
GET /workspaces/:workspace_id/billing/preview.json 일할 계산이 포함된 요금제 변경 미리 보기 billing_preview

권한: billing.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/billing/preview.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "plan": {
      "type": "string",
      "description": "변경할 요금제: pro 또는 business",
      "enum": [
        "pro",
        "business"
      ]
    },
    "events": {
      "type": "integer",
      "description": "티어의 월간 이벤트 수, GET /plans에서 확인",
      "examples": [
        1000000
      ]
    },
    "interval": {
      "type": "string",
      "description": "결제 주기. 연간은 2개월 무료",
      "enum": [
        "month",
        "year"
      ],
      "default": "month"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "plan",
    "events",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "plan": {
      "type": "string"
    },
    "events": {
      "type": "integer"
    },
    "interval": {
      "type": "string"
    },
    "price_id": {
      "type": "string"
    },
    "amount": {
      "type": "integer",
      "description": "주기당 USD 기준 새 가격"
    },
    "currency": {
      "type": "string"
    },
    "charge_minor": {
      "type": "integer",
      "description": "지금 청구되는 금액 (최소 단위)"
    },
    "credit_minor": {
      "type": "integer",
      "description": "미사용 기간에 대한 크레딧 (최소 단위)"
    },
    "result_action": {
      "anyOf": [
        {
          "type": "string",
          "description": "charge 또는 credit"
        },
        {
          "type": "null"
        }
      ]
    },
    "result_minor": {
      "type": "integer",
      "description": "순 청구액 또는 크레딧 (최소 단위)"
    },
    "next_billed_at": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "warnings": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "새 요금제가 감당하지 못하는 사용량 또는 한도"
    }
  }
}
POST /workspaces/:workspace_id/billing/resume.json 예약된 해지를 취소하거나 일시 중지 해제 billing_resume

권한: billing.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/billing/resume.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "유료 티어의 월간 이벤트 수"
    },
    "allowance": {
      "type": "integer",
      "description": "배지 보너스를 포함한 월간 이벤트 수"
    },
    "billing_interval": {
      "anyOf": [
        {
          "type": "string",
          "description": "month 또는 year"
        },
        {
          "type": "null"
        }
      ]
    },
    "price": {
      "anyOf": [
        {
          "type": "integer",
          "description": "결제 주기당 USD"
        },
        {
          "type": "null"
        }
      ]
    },
    "subscription_status": {
      "type": "string",
      "description": "none, trialing, active, past_due, paused 또는 canceled"
    },
    "current_period_ends_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "갱신 또는 종료 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "canceled_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "auto_upgrade": {
      "type": "boolean"
    },
    "discount": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "program": {
              "type": "string",
              "description": "nonprofit, education, open_source, open_source_free 또는 agency"
            },
            "status": {
              "type": "string",
              "description": "pending, approved (아직 구독에 적용되지 않음), active, rejected 또는 revoked"
            },
            "percent": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "Pro와 Business 할인율 (무료 오픈 소스 프로그램은 null)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "comp_events": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "월간 무료 이벤트 (무료 오픈 소스 프로그램만)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "organization_name": {
              "type": "string",
              "description": "단체, 학교, 프로젝트 또는 에이전시 이름"
            },
            "website": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "웹사이트"
                },
                {
                  "type": "null"
                }
              ]
            },
            "proof_url": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "증빙 링크 또는 저장소 URL"
                },
                {
                  "type": "null"
                }
              ]
            },
            "license": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "OSI 라이선스 (오픈 소스)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "note": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "심사를 위한 메모"
                },
                {
                  "type": "null"
                }
              ]
            },
            "rejection_reason": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "신청이 승인되지 않은 이유"
                },
                {
                  "type": "null"
                }
              ]
            },
            "created_at": {
              "type": "string",
              "format": "date-time",
              "description": "신청 시각"
            },
            "reviewed_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "심사 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "applied_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "할인 적용 시작 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "revoked_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "프로그램 종료 시각"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "가장 최근의 할인 프로그램 신청, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "discount_percent": {
      "anyOf": [
        {
          "type": "integer",
          "description": "승인된 프로그램에 따른 Pro와 Business 할인율, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "billing_emails": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "tax_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "badge": {
      "type": "object",
      "description": "배지 보너스 (무료 요금제)"
    },
    "usage": {
      "type": "object",
      "properties": {
        "month": {
          "type": "string",
          "format": "date",
          "description": "보고 대상 월의 첫째 날"
        },
        "events": {
          "type": "integer",
          "description": "과금 대상 이벤트 (페이지뷰와 사용자 지정 이벤트)"
        },
        "bots": {
          "type": "integer",
          "description": "걸러낸 봇 히트 (과금 안 됨)"
        },
        "allowance": {
          "type": "integer",
          "description": "포함된 이벤트, 배지 보너스 포함"
        },
        "percent": {
          "type": "number",
          "description": "허용량 대비 이벤트 비율"
        },
        "forecast": {
          "anyOf": [
            {
              "type": "integer",
              "description": "월말 예상 이벤트 수"
            },
            {
              "type": "null"
            }
          ]
        },
        "forecast_percent": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ]
        },
        "days_left": {
          "type": "integer",
          "description": "이번 달 남은 일수"
        },
        "status": {
          "type": "string",
          "description": "ok, warning (80% 이상), over (허용량에 도달했거나 넘은 지난 달), locked 또는 paused"
        },
        "sites": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "site_id": {
                "type": "string"
              },
              "domain": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "events": {
                "type": "integer",
                "description": "이번 달 페이지뷰와 사용자 지정 이벤트"
              },
              "share": {
                "type": "number",
                "description": "워크스페이스 전체 대비 비율 (%)"
              }
            }
          },
          "description": "사이트별 이벤트"
        },
        "history": {
          "type": "array",
          "description": "이전 달, 최신순"
        },
        "access_locked_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "Privatus 직원이 대시보드를 잠근 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused": {
          "type": "boolean",
          "description": "새 이벤트가 버려지는 동안 true (월간 한도에 도달했거나 직원이 수집을 일시 중지함)"
        },
        "pause_reason": {
          "anyOf": [
            {
              "type": "string",
              "description": "수집이 일시 중지된 이유: limit (월간 허용량 도달) 또는 staff. 수집 중이면 null"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "직원이 수집을 일시 중지한 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "resumes_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "한도로 인한 일시 중지가 풀리는 시각: 다음 달 시작 (UTC), 업그레이드하면 더 일찍. 그 외에는 null"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "description": "이번 달 현재까지"
    }
  }
}
GET /workspaces/:workspace_id/billing.json 요금제, 구독, 사용량 조회 billing_get

권한: billing.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/billing.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "유료 티어의 월간 이벤트 수"
    },
    "allowance": {
      "type": "integer",
      "description": "배지 보너스를 포함한 월간 이벤트 수"
    },
    "billing_interval": {
      "anyOf": [
        {
          "type": "string",
          "description": "month 또는 year"
        },
        {
          "type": "null"
        }
      ]
    },
    "price": {
      "anyOf": [
        {
          "type": "integer",
          "description": "결제 주기당 USD"
        },
        {
          "type": "null"
        }
      ]
    },
    "subscription_status": {
      "type": "string",
      "description": "none, trialing, active, past_due, paused 또는 canceled"
    },
    "current_period_ends_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "갱신 또는 종료 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "canceled_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "auto_upgrade": {
      "type": "boolean"
    },
    "discount": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "program": {
              "type": "string",
              "description": "nonprofit, education, open_source, open_source_free 또는 agency"
            },
            "status": {
              "type": "string",
              "description": "pending, approved (아직 구독에 적용되지 않음), active, rejected 또는 revoked"
            },
            "percent": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "Pro와 Business 할인율 (무료 오픈 소스 프로그램은 null)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "comp_events": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "월간 무료 이벤트 (무료 오픈 소스 프로그램만)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "organization_name": {
              "type": "string",
              "description": "단체, 학교, 프로젝트 또는 에이전시 이름"
            },
            "website": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "웹사이트"
                },
                {
                  "type": "null"
                }
              ]
            },
            "proof_url": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "증빙 링크 또는 저장소 URL"
                },
                {
                  "type": "null"
                }
              ]
            },
            "license": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "OSI 라이선스 (오픈 소스)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "note": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "심사를 위한 메모"
                },
                {
                  "type": "null"
                }
              ]
            },
            "rejection_reason": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "신청이 승인되지 않은 이유"
                },
                {
                  "type": "null"
                }
              ]
            },
            "created_at": {
              "type": "string",
              "format": "date-time",
              "description": "신청 시각"
            },
            "reviewed_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "심사 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "applied_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "할인 적용 시작 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "revoked_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "프로그램 종료 시각"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "가장 최근의 할인 프로그램 신청, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "discount_percent": {
      "anyOf": [
        {
          "type": "integer",
          "description": "승인된 프로그램에 따른 Pro와 Business 할인율, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "billing_emails": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "tax_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "badge": {
      "type": "object",
      "description": "배지 보너스 (무료 요금제)"
    },
    "usage": {
      "type": "object",
      "properties": {
        "month": {
          "type": "string",
          "format": "date",
          "description": "보고 대상 월의 첫째 날"
        },
        "events": {
          "type": "integer",
          "description": "과금 대상 이벤트 (페이지뷰와 사용자 지정 이벤트)"
        },
        "bots": {
          "type": "integer",
          "description": "걸러낸 봇 히트 (과금 안 됨)"
        },
        "allowance": {
          "type": "integer",
          "description": "포함된 이벤트, 배지 보너스 포함"
        },
        "percent": {
          "type": "number",
          "description": "허용량 대비 이벤트 비율"
        },
        "forecast": {
          "anyOf": [
            {
              "type": "integer",
              "description": "월말 예상 이벤트 수"
            },
            {
              "type": "null"
            }
          ]
        },
        "forecast_percent": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ]
        },
        "days_left": {
          "type": "integer",
          "description": "이번 달 남은 일수"
        },
        "status": {
          "type": "string",
          "description": "ok, warning (80% 이상), over (허용량에 도달했거나 넘은 지난 달), locked 또는 paused"
        },
        "sites": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "site_id": {
                "type": "string"
              },
              "domain": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "events": {
                "type": "integer",
                "description": "이번 달 페이지뷰와 사용자 지정 이벤트"
              },
              "share": {
                "type": "number",
                "description": "워크스페이스 전체 대비 비율 (%)"
              }
            }
          },
          "description": "사이트별 이벤트"
        },
        "history": {
          "type": "array",
          "description": "이전 달, 최신순"
        },
        "access_locked_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "Privatus 직원이 대시보드를 잠근 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused": {
          "type": "boolean",
          "description": "새 이벤트가 버려지는 동안 true (월간 한도에 도달했거나 직원이 수집을 일시 중지함)"
        },
        "pause_reason": {
          "anyOf": [
            {
              "type": "string",
              "description": "수집이 일시 중지된 이유: limit (월간 허용량 도달) 또는 staff. 수집 중이면 null"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "직원이 수집을 일시 중지한 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "resumes_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "한도로 인한 일시 중지가 풀리는 시각: 다음 달 시작 (UTC), 업그레이드하면 더 일찍. 그 외에는 null"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "description": "이번 달 현재까지"
    }
  }
}
PATCH /workspaces/:workspace_id/billing.json 결제 이메일, 세금 ID, 자동 업그레이드 수정 billing_update

권한: billing.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/billing.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "billing_emails": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "인보이스와 결제 안내를 받을 추가 주소 (최대 5개)"
    },
    "tax_id": {
      "type": "string",
      "description": "인보이스에 표시되는 VAT/GST/세금 ID"
    },
    "auto_upgrade": {
      "type": "boolean",
      "description": "true이면 월간 한도에 도달했을 때 수집을 일시 중지하는 대신 다음 등급으로 이동하고 차액을 청구합니다. 기본값은 꺼짐"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "유료 티어의 월간 이벤트 수"
    },
    "allowance": {
      "type": "integer",
      "description": "배지 보너스를 포함한 월간 이벤트 수"
    },
    "billing_interval": {
      "anyOf": [
        {
          "type": "string",
          "description": "month 또는 year"
        },
        {
          "type": "null"
        }
      ]
    },
    "price": {
      "anyOf": [
        {
          "type": "integer",
          "description": "결제 주기당 USD"
        },
        {
          "type": "null"
        }
      ]
    },
    "subscription_status": {
      "type": "string",
      "description": "none, trialing, active, past_due, paused 또는 canceled"
    },
    "current_period_ends_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "갱신 또는 종료 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "cancel_at_period_end": {
      "type": "boolean"
    },
    "canceled_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "auto_upgrade": {
      "type": "boolean"
    },
    "discount": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "program": {
              "type": "string",
              "description": "nonprofit, education, open_source, open_source_free 또는 agency"
            },
            "status": {
              "type": "string",
              "description": "pending, approved (아직 구독에 적용되지 않음), active, rejected 또는 revoked"
            },
            "percent": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "Pro와 Business 할인율 (무료 오픈 소스 프로그램은 null)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "comp_events": {
              "anyOf": [
                {
                  "type": "integer",
                  "description": "월간 무료 이벤트 (무료 오픈 소스 프로그램만)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "organization_name": {
              "type": "string",
              "description": "단체, 학교, 프로젝트 또는 에이전시 이름"
            },
            "website": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "웹사이트"
                },
                {
                  "type": "null"
                }
              ]
            },
            "proof_url": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "증빙 링크 또는 저장소 URL"
                },
                {
                  "type": "null"
                }
              ]
            },
            "license": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "OSI 라이선스 (오픈 소스)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "note": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "심사를 위한 메모"
                },
                {
                  "type": "null"
                }
              ]
            },
            "rejection_reason": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "신청이 승인되지 않은 이유"
                },
                {
                  "type": "null"
                }
              ]
            },
            "created_at": {
              "type": "string",
              "format": "date-time",
              "description": "신청 시각"
            },
            "reviewed_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "심사 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "applied_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "할인 적용 시작 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "revoked_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "프로그램 종료 시각"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "가장 최근의 할인 프로그램 신청, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "discount_percent": {
      "anyOf": [
        {
          "type": "integer",
          "description": "승인된 프로그램에 따른 Pro와 Business 할인율, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "billing_emails": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "tax_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "badge": {
      "type": "object",
      "description": "배지 보너스 (무료 요금제)"
    },
    "usage": {
      "type": "object",
      "properties": {
        "month": {
          "type": "string",
          "format": "date",
          "description": "보고 대상 월의 첫째 날"
        },
        "events": {
          "type": "integer",
          "description": "과금 대상 이벤트 (페이지뷰와 사용자 지정 이벤트)"
        },
        "bots": {
          "type": "integer",
          "description": "걸러낸 봇 히트 (과금 안 됨)"
        },
        "allowance": {
          "type": "integer",
          "description": "포함된 이벤트, 배지 보너스 포함"
        },
        "percent": {
          "type": "number",
          "description": "허용량 대비 이벤트 비율"
        },
        "forecast": {
          "anyOf": [
            {
              "type": "integer",
              "description": "월말 예상 이벤트 수"
            },
            {
              "type": "null"
            }
          ]
        },
        "forecast_percent": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ]
        },
        "days_left": {
          "type": "integer",
          "description": "이번 달 남은 일수"
        },
        "status": {
          "type": "string",
          "description": "ok, warning (80% 이상), over (허용량에 도달했거나 넘은 지난 달), locked 또는 paused"
        },
        "sites": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "site_id": {
                "type": "string"
              },
              "domain": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "events": {
                "type": "integer",
                "description": "이번 달 페이지뷰와 사용자 지정 이벤트"
              },
              "share": {
                "type": "number",
                "description": "워크스페이스 전체 대비 비율 (%)"
              }
            }
          },
          "description": "사이트별 이벤트"
        },
        "history": {
          "type": "array",
          "description": "이전 달, 최신순"
        },
        "access_locked_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "Privatus 직원이 대시보드를 잠근 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused": {
          "type": "boolean",
          "description": "새 이벤트가 버려지는 동안 true (월간 한도에 도달했거나 직원이 수집을 일시 중지함)"
        },
        "pause_reason": {
          "anyOf": [
            {
              "type": "string",
              "description": "수집이 일시 중지된 이유: limit (월간 허용량 도달) 또는 staff. 수집 중이면 null"
            },
            {
              "type": "null"
            }
          ]
        },
        "collection_paused_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "직원이 수집을 일시 중지한 시각"
            },
            {
              "type": "null"
            }
          ]
        },
        "resumes_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time",
              "description": "한도로 인한 일시 중지가 풀리는 시각: 다음 달 시작 (UTC), 업그레이드하면 더 일찍. 그 외에는 null"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "description": "이번 달 현재까지"
    }
  }
}
GET /workspaces/:workspace_id/billing/usage.json 이번 달 사용량, 예측, 사이트별 분포 조회 billing_usage

권한: billing.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/billing/usage.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "month": {
      "type": "string",
      "format": "date",
      "description": "리포트할 월의 아무 날 (기본값은 이번 달)",
      "examples": [
        "2026-09-01"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "month": {
      "type": "string",
      "format": "date",
      "description": "보고 대상 월의 첫째 날"
    },
    "events": {
      "type": "integer",
      "description": "과금 대상 이벤트 (페이지뷰와 사용자 지정 이벤트)"
    },
    "bots": {
      "type": "integer",
      "description": "걸러낸 봇 히트 (과금 안 됨)"
    },
    "allowance": {
      "type": "integer",
      "description": "포함된 이벤트, 배지 보너스 포함"
    },
    "percent": {
      "type": "number",
      "description": "허용량 대비 이벤트 비율"
    },
    "forecast": {
      "anyOf": [
        {
          "type": "integer",
          "description": "월말 예상 이벤트 수"
        },
        {
          "type": "null"
        }
      ]
    },
    "forecast_percent": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "days_left": {
      "type": "integer",
      "description": "이번 달 남은 일수"
    },
    "status": {
      "type": "string",
      "description": "ok, warning (80% 이상), over (허용량에 도달했거나 넘은 지난 달), locked 또는 paused"
    },
    "sites": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "site_id": {
            "type": "string"
          },
          "domain": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "events": {
            "type": "integer",
            "description": "이번 달 페이지뷰와 사용자 지정 이벤트"
          },
          "share": {
            "type": "number",
            "description": "워크스페이스 전체 대비 비율 (%)"
          }
        }
      },
      "description": "사이트별 이벤트"
    },
    "history": {
      "type": "array",
      "description": "이전 달, 최신순"
    },
    "access_locked_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "Privatus 직원이 대시보드를 잠근 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "collection_paused": {
      "type": "boolean",
      "description": "새 이벤트가 버려지는 동안 true (월간 한도에 도달했거나 직원이 수집을 일시 중지함)"
    },
    "pause_reason": {
      "anyOf": [
        {
          "type": "string",
          "description": "수집이 일시 중지된 이유: limit (월간 허용량 도달) 또는 staff. 수집 중이면 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "collection_paused_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "직원이 수집을 일시 중지한 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "resumes_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "한도로 인한 일시 중지가 풀리는 시각: 다음 달 시작 (UTC), 업그레이드하면 더 일찍. 그 외에는 null"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
GET /workspaces/:workspace_id/billing/invoices.json 인보이스 목록 보기 billing_invoices_list

권한: billing.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/billing/invoices.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "Paddle 트랜잭션 ID"
      },
      "invoice_number": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "status": {
        "type": "string",
        "description": "paid, completed, payment_failed, ..."
      },
      "amount_minor": {
        "type": "integer",
        "description": "최소 단위 (센트)의 합계"
      },
      "currency": {
        "type": "string"
      },
      "billed_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      }
    }
  }
}
GET /workspaces/:workspace_id/billing/invoices/:id.json 인보이스의 PDF 링크 받기 billing_invoices_get

권한: billing.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/billing/invoices/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "kind": {
      "type": "string",
      "description": "portal, payment_method 또는 invoice"
    },
    "url": {
      "anyOf": [
        {
          "type": "string",
          "description": "유효 기간이 짧은 Paddle URL"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}

계정

GET /account.json 프로필과 환경설정 조회 account_get

권한: member

예시
curl https://privatusanalytics.com/account.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {},
  "required": []
}
응답 데이터
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string"
    },
    "unconfirmed_email": {
      "anyOf": [
        {
          "type": "string",
          "description": "확인 대기 중인 새 이메일"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "theme": {
      "type": "string"
    },
    "default_landing": {
      "type": "string"
    },
    "locale": {
      "type": "string",
      "description": "이 계정의 앱 언어 코드 (기본값 en)"
    },
    "timezone": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "shortcuts_enabled": {
      "type": "boolean"
    },
    "reduce_motion": {
      "type": "boolean"
    },
    "product_emails": {
      "type": "boolean"
    },
    "marketing_emails": {
      "type": "boolean",
      "description": "마케팅 이메일(드립 캠페인) 발송 허용 여부. 수신 거부 후에는 false"
    },
    "newsletter": {
      "type": "boolean"
    },
    "two_factor": {
      "type": "boolean"
    },
    "passkeys": {
      "type": "integer"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /account.json 프로필과 환경설정 수정 account_update

권한: member

예시
curl -X PATCH https://privatusanalytics.com/account.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "이름"
    },
    "email": {
      "type": "string",
      "description": "새 이메일 주소 (먼저 이메일로 확인)"
    },
    "theme": {
      "type": "string",
      "description": "색상 테마",
      "enum": [
        "system",
        "light",
        "dark"
      ]
    },
    "default_landing": {
      "type": "string",
      "description": "로그인 후 페이지: sites 또는 last_site",
      "enum": [
        "sites",
        "last_site"
      ]
    },
    "locale": {
      "type": "string",
      "description": "로그인했을 때 앱의 언어, 언어 코드로 지정 (en, de, fr 등). 공개 페이지와 API는 그대로 유지됩니다",
      "enum": [
        "en",
        "de",
        "es",
        "fr",
        "it",
        "nl",
        "pt",
        "pl",
        "sv",
        "da",
        "no",
        "fi",
        "ja",
        "ko",
        "zh-CN",
        "zh-TW"
      ]
    },
    "timezone": {
      "type": "string",
      "description": "시간대 (IANA 이름)"
    },
    "shortcuts_enabled": {
      "type": "boolean",
      "description": "키보드 단축키"
    },
    "reduce_motion": {
      "type": "boolean",
      "description": "애니메이션 줄이기"
    },
    "product_emails": {
      "type": "boolean",
      "description": "제품 업데이트 및 팁 이메일"
    },
    "marketing_emails": {
      "type": "boolean",
      "description": "시작 팁 등 마케팅 이메일. 수신 거부 후 다시 켜려면 로그인된 브라우저가 필요합니다"
    },
    "newsletter": {
      "type": "boolean",
      "description": "월간 뉴스레터"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string"
    },
    "unconfirmed_email": {
      "anyOf": [
        {
          "type": "string",
          "description": "확인 대기 중인 새 이메일"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "theme": {
      "type": "string"
    },
    "default_landing": {
      "type": "string"
    },
    "locale": {
      "type": "string",
      "description": "이 계정의 앱 언어 코드 (기본값 en)"
    },
    "timezone": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "shortcuts_enabled": {
      "type": "boolean"
    },
    "reduce_motion": {
      "type": "boolean"
    },
    "product_emails": {
      "type": "boolean"
    },
    "marketing_emails": {
      "type": "boolean",
      "description": "마케팅 이메일(드립 캠페인) 발송 허용 여부. 수신 거부 후에는 false"
    },
    "newsletter": {
      "type": "boolean"
    },
    "two_factor": {
      "type": "boolean"
    },
    "passkeys": {
      "type": "integer"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

공유

GET /badge/:site_id.json 공개 사이트의 방문자 카운터 배지 (SVG) badges_get

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/badge/:site_id.json
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /share/:token/breakdown/:dimension.json 공유된 차원의 상위 값 shares_breakdown

권한: public

예시
curl https://privatusanalytics.com/share/:token/breakdown/:dimension.json
입력
{
  "type": "object",
  "properties": {
    "dimension": {
      "type": "string",
      "description": "리소스의 Dimension"
    },
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋 (링크가 고정한 경우 무시됨)",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "링크가 허용하는 경우 추가 필터",
      "default": []
    },
    "limit": {
      "type": "integer",
      "description": "행 수 (최대 100)",
      "default": 10
    },
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "dimension",
    "token"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /share/:token.json 공유 토큰으로 보는 공유 대시보드 개요 shares_overview

권한: public

예시
curl https://privatusanalytics.com/share/:token.json
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋 (링크가 고정한 경우 무시됨)",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "링크가 허용하는 경우 추가 필터: [[\"dimension\",\"operator\",\"value\"], …]",
      "default": []
    },
    "interval": {
      "type": "string",
      "description": "차트 구간 크기",
      "enum": [
        "auto",
        "minute",
        "hour",
        "day",
        "week",
        "month",
        "quarter",
        "year"
      ],
      "default": "auto"
    },
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object"
}

내보내기

POST /workspaces/:workspace_id/exports.json 내보내기 대기열에 추가 (백그라운드에서 생성) exports_create

권한: analytics.export

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/exports.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "내보낼 사이트 (pa_…)",
      "examples": [
        "pa_7Q2K9XH3AB"
      ]
    },
    "kind": {
      "type": "string",
      "description": "aggregated: 시간 구간과 차원별 지표. pageviews/events/raw: 히트당 한 행 (Pro 이상). imported: 가져온 일별 통계. dashboard: 개요 패널의 ZIP",
      "enum": [
        "aggregated",
        "pageviews",
        "events",
        "imported",
        "raw",
        "dashboard"
      ],
      "default": "aggregated"
    },
    "file_format": {
      "type": "string",
      "description": "csv, json 또는 xlsx (aggregated, pageviews, events, imported), csv 또는 ndjson (raw), zip (dashboard)",
      "enum": [
        "csv",
        "json",
        "xlsx",
        "ndjson",
        "zip"
      ],
      "default": "csv"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "첫째 날 (내보내기 시간대 기준)",
      "examples": [
        "2026-09-01"
      ]
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "마지막 날 (포함, 최대 400일, raw는 93일)",
      "examples": [
        "2026-09-28"
      ]
    },
    "timezone": {
      "type": "string",
      "description": "날짜와 그룹화에 쓸 시간대, 예: America/New_York (기본값: 사이트 시간대)"
    },
    "grouping": {
      "type": "string",
      "description": "aggregated 내보내기의 시간 구간",
      "enum": [
        "hour",
        "day",
        "week",
        "month",
        "quarter",
        "year"
      ],
      "default": "day"
    },
    "dimensions": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "aggregated 내보내기를 그룹화할 방문 차원 (최대 6개), 예: country, channel, entry_page. imported 내보내기의 경우: 포함할 가져온 차원",
      "default": []
    },
    "metrics": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "aggregated 내보내기의 지표 (기본값 전체): visitors, visits, pageviews, bounce_rate, visit_duration, views_per_visit, revenue",
      "default": []
    },
    "fields": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "pageviews/events/raw 내보내기의 열 (기본값은 visit_id, vital_value, selector를 제외한 전체): occurred_at, kind, name, visit_id, hostname, path, referrer_host, referrer_path, channel, utm_source, utm_medium, utm_campaign, utm_content, utm_term, ref, paid_click, country, language, device, browser, browser_major, os, os_major, screen_bucket, engaged_ms, scroll_depth, revenue_minor, currency, vital_value, selector, props",
      "default": []
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터, 통계 API와 같은 형식: [[\"dimension\",\"operator\",\"value\"], …]",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id",
    "from",
    "to",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "내보내기 ID, 예: exp_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "내보낸 사이트 (pa_…)"
        },
        {
          "type": "null"
        }
      ]
    },
    "kind": {
      "type": "string",
      "description": "aggregated, pageviews, events, imported, raw 또는 dashboard"
    },
    "format": {
      "type": "string",
      "description": "csv, json, xlsx, ndjson 또는 zip"
    },
    "status": {
      "type": "string",
      "description": "queued, running, complete, failed 또는 expired"
    },
    "params": {
      "type": "object",
      "description": "내보내기 정의 (날짜, 시간대, 그룹화, 차원, 지표, 필드, 필터)"
    },
    "row_count": {
      "anyOf": [
        {
          "type": "integer",
          "description": "기록된 행 수"
        },
        {
          "type": "null"
        }
      ]
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "내보내기가 실패한 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "completed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "파일이 삭제되는 시점"
        },
        {
          "type": "null"
        }
      ]
    },
    "download_url": {
      "anyOf": [
        {
          "type": "string",
          "description": "유효 기간이 짧은 서명된 파일 링크를 반환하는 경로 (exports_download)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /exports/:id.json 내보내기와 파일 삭제 exports_delete

권한: analytics.export

예시
curl -X DELETE https://privatusanalytics.com/exports/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "내보내기 ID, 예: exp_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "내보낸 사이트 (pa_…)"
        },
        {
          "type": "null"
        }
      ]
    },
    "kind": {
      "type": "string",
      "description": "aggregated, pageviews, events, imported, raw 또는 dashboard"
    },
    "format": {
      "type": "string",
      "description": "csv, json, xlsx, ndjson 또는 zip"
    },
    "status": {
      "type": "string",
      "description": "queued, running, complete, failed 또는 expired"
    },
    "params": {
      "type": "object",
      "description": "내보내기 정의 (날짜, 시간대, 그룹화, 차원, 지표, 필드, 필터)"
    },
    "row_count": {
      "anyOf": [
        {
          "type": "integer",
          "description": "기록된 행 수"
        },
        {
          "type": "null"
        }
      ]
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "내보내기가 실패한 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "completed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "파일이 삭제되는 시점"
        },
        {
          "type": "null"
        }
      ]
    },
    "download_url": {
      "anyOf": [
        {
          "type": "string",
          "description": "유효 기간이 짧은 서명된 파일 링크를 반환하는 경로 (exports_download)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /exports/:id/download.json 파일의 서명된 링크 받기 (10분간 유효) exports_download

권한: analytics.export

예시
curl https://privatusanalytics.com/exports/:id/download.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /workspaces/:workspace_id/exports.json 내보내기 목록 보기 (작업 대기열) exports_list

권한: analytics.export

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/exports.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "이 사이트의 내보내기만 (pa_…)"
    },
    "status": {
      "type": "string",
      "description": "이 상태의 내보내기만",
      "enum": [
        "queued",
        "running",
        "complete",
        "failed",
        "expired"
      ]
    },
    "kind": {
      "type": "string",
      "description": "이 종류의 내보내기만",
      "enum": [
        "aggregated",
        "pageviews",
        "events",
        "imported",
        "raw",
        "dashboard"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "내보내기 ID, 예: exp_7Q2K9XH3AB"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "내보낸 사이트 (pa_…)"
          },
          {
            "type": "null"
          }
        ]
      },
      "kind": {
        "type": "string",
        "description": "aggregated, pageviews, events, imported, raw 또는 dashboard"
      },
      "format": {
        "type": "string",
        "description": "csv, json, xlsx, ndjson 또는 zip"
      },
      "status": {
        "type": "string",
        "description": "queued, running, complete, failed 또는 expired"
      },
      "params": {
        "type": "object",
        "description": "내보내기 정의 (날짜, 시간대, 그룹화, 차원, 지표, 필드, 필터)"
      },
      "row_count": {
        "anyOf": [
          {
            "type": "integer",
            "description": "기록된 행 수"
          },
          {
            "type": "null"
          }
        ]
      },
      "error": {
        "anyOf": [
          {
            "type": "string",
            "description": "내보내기가 실패한 이유"
          },
          {
            "type": "null"
          }
        ]
      },
      "completed_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "expires_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time",
            "description": "파일이 삭제되는 시점"
          },
          {
            "type": "null"
          }
        ]
      },
      "download_url": {
        "anyOf": [
          {
            "type": "string",
            "description": "유효 기간이 짧은 서명된 파일 링크를 반환하는 경로 (exports_download)"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /workspaces/:workspace_id/exports/preview.json 내보내기 미리 보기: 처음 20개 행과 예상 행 수 exports_preview

권한: analytics.export

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/exports/preview.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "내보낼 사이트 (pa_…)",
      "examples": [
        "pa_7Q2K9XH3AB"
      ]
    },
    "kind": {
      "type": "string",
      "description": "aggregated: 시간 구간과 차원별 지표. pageviews/events/raw: 히트당 한 행 (Pro 이상). imported: 가져온 일별 통계. dashboard: 개요 패널의 ZIP",
      "enum": [
        "aggregated",
        "pageviews",
        "events",
        "imported",
        "raw",
        "dashboard"
      ],
      "default": "aggregated"
    },
    "file_format": {
      "type": "string",
      "description": "csv, json 또는 xlsx (aggregated, pageviews, events, imported), csv 또는 ndjson (raw), zip (dashboard)",
      "enum": [
        "csv",
        "json",
        "xlsx",
        "ndjson",
        "zip"
      ],
      "default": "csv"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "첫째 날 (내보내기 시간대 기준)",
      "examples": [
        "2026-09-01"
      ]
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "마지막 날 (포함, 최대 400일, raw는 93일)",
      "examples": [
        "2026-09-28"
      ]
    },
    "timezone": {
      "type": "string",
      "description": "날짜와 그룹화에 쓸 시간대, 예: America/New_York (기본값: 사이트 시간대)"
    },
    "grouping": {
      "type": "string",
      "description": "aggregated 내보내기의 시간 구간",
      "enum": [
        "hour",
        "day",
        "week",
        "month",
        "quarter",
        "year"
      ],
      "default": "day"
    },
    "dimensions": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "aggregated 내보내기를 그룹화할 방문 차원 (최대 6개), 예: country, channel, entry_page. imported 내보내기의 경우: 포함할 가져온 차원",
      "default": []
    },
    "metrics": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "aggregated 내보내기의 지표 (기본값 전체): visitors, visits, pageviews, bounce_rate, visit_duration, views_per_visit, revenue",
      "default": []
    },
    "fields": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "pageviews/events/raw 내보내기의 열 (기본값은 visit_id, vital_value, selector를 제외한 전체): occurred_at, kind, name, visit_id, hostname, path, referrer_host, referrer_path, channel, utm_source, utm_medium, utm_campaign, utm_content, utm_term, ref, paid_click, country, language, device, browser, browser_major, os, os_major, screen_bucket, engaged_ms, scroll_depth, revenue_minor, currency, vital_value, selector, props",
      "default": []
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터, 통계 API와 같은 형식: [[\"dimension\",\"operator\",\"value\"], …]",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id",
    "from",
    "to",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /exports/:id.json 내보내기와 상태 조회 exports_get

권한: analytics.export

예시
curl https://privatusanalytics.com/exports/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "내보내기 ID, 예: exp_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "내보낸 사이트 (pa_…)"
        },
        {
          "type": "null"
        }
      ]
    },
    "kind": {
      "type": "string",
      "description": "aggregated, pageviews, events, imported, raw 또는 dashboard"
    },
    "format": {
      "type": "string",
      "description": "csv, json, xlsx, ndjson 또는 zip"
    },
    "status": {
      "type": "string",
      "description": "queued, running, complete, failed 또는 expired"
    },
    "params": {
      "type": "object",
      "description": "내보내기 정의 (날짜, 시간대, 그룹화, 차원, 지표, 필드, 필터)"
    },
    "row_count": {
      "anyOf": [
        {
          "type": "integer",
          "description": "기록된 행 수"
        },
        {
          "type": "null"
        }
      ]
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "내보내기가 실패한 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "completed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "파일이 삭제되는 시점"
        },
        {
          "type": "null"
        }
      ]
    },
    "download_url": {
      "anyOf": [
        {
          "type": "string",
          "description": "유효 기간이 짧은 서명된 파일 링크를 반환하는 경로 (exports_download)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

대시보드

GET /workspaces/:workspace_id/dashboards/:id/cards/:index.json 사용자 지정 대시보드의 카드 하나에 대한 데이터 dashboards_card

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/dashboards/:id/cards/:index.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    },
    "index": {
      "type": "string",
      "description": "리소스의 Index"
    }
  },
  "required": [
    "workspace_id",
    "id",
    "index"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /workspaces/:workspace_id/dashboards.json 사용자 지정 대시보드 만들기 dashboards_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/dashboards.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "대시보드 이름",
      "examples": [
        "Client: Acme"
      ]
    },
    "cards": {
      "type": "array",
      "items": {},
      "description": "순서대로 나열한 카드 (최대 40개): [{\"type\": \"metric|chart|breakdown|goal|live|funnel|uptime|vitals\", \"site_id\": \"pa_…\", \"title\": \"optional\", \"params\": {\"period\": \"30d\", \"metric\": \"visitors\", \"dimension\": \"page\", \"funnel_id\": \"fun_…\"}}]. 유형이 사용하지 않는 params는 무시됩니다",
      "default": []
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대시보드 ID, 예: dash_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "cards": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "순서대로 나열한 카드: [{type, site_id, title, params}]"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /workspaces/:workspace_id/dashboards/:id.json 사용자 지정 대시보드 삭제 dashboards_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:workspace_id/dashboards/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대시보드 ID, 예: dash_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "cards": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "순서대로 나열한 카드: [{type, site_id, title, params}]"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/dashboards.json 사용자 지정 대시보드 목록 보기 dashboards_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/dashboards.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "대시보드 ID, 예: dash_7Q2K9XH3AB"
      },
      "name": {
        "type": "string"
      },
      "cards": {
        "type": "array",
        "items": {
          "type": "object"
        },
        "description": "순서대로 나열한 카드: [{type, site_id, title, params}]"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      },
      "updated_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /workspaces/:workspace_id/dashboards/:id.json 사용자 지정 대시보드와 카드 조회 dashboards_get

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/dashboards/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대시보드 ID, 예: dash_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "cards": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "순서대로 나열한 카드: [{type, site_id, title, params}]"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /workspaces/:workspace_id/dashboards/:id.json 사용자 지정 대시보드 이름 변경 또는 카드 교체 dashboards_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/dashboards/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "새 이름 (비우면 변경 없음)"
    },
    "cards": {
      "type": "array",
      "items": {},
      "description": "모든 카드를 교체합니다. 순서대로 나열한 카드 (최대 40개): [{\"type\": \"metric|chart|breakdown|goal|live|funnel|uptime|vitals\", \"site_id\": \"pa_…\", \"title\": \"optional\", \"params\": {\"period\": \"30d\", \"metric\": \"visitors\", \"dimension\": \"page\", \"funnel_id\": \"fun_…\"}}]. 유형이 사용하지 않는 params는 무시됩니다"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대시보드 ID, 예: dash_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "cards": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "순서대로 나열한 카드: [{type, site_id, title, params}]"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

메모

POST /sites/:site_id/notes.json 사이트에 메모 추가 (릴리스 웹훅에는 source "deploy" 사용) notes_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/notes.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "format": "date",
      "description": "메모 날짜 (사이트 시간대). 기본값은 오늘"
    },
    "end_date": {
      "type": "string",
      "format": "date",
      "description": "날짜 범위의 마지막 날"
    },
    "title": {
      "type": "string",
      "description": "차트에 표시되는 짧은 제목",
      "examples": [
        "Launched new pricing"
      ]
    },
    "body": {
      "type": "string",
      "description": "상세 내용 (Markdown)"
    },
    "url": {
      "type": "string",
      "description": "링크, 예: PR 또는 변경 내역"
    },
    "color": {
      "type": "string",
      "description": "핀 색상",
      "enum": [
        "neutral",
        "brand",
        "blue",
        "amber",
        "red",
        "violet"
      ]
    },
    "source": {
      "type": "string",
      "description": "manual, 또는 릴리스 웹훅용 deploy",
      "enum": [
        "manual",
        "deploy",
        "system",
        "import",
        "incident"
      ],
      "default": "manual"
    },
    "version": {
      "type": "string",
      "description": "배포: 릴리스 버전 또는 커밋, 기본 제목에 사용됨"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "메모 ID, 예: note_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트, 워크스페이스 전체 메모는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "date": {
      "type": "string",
      "format": "date"
    },
    "end_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string",
          "description": "Markdown"
        },
        {
          "type": "null"
        }
      ]
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "color": {
      "type": "string",
      "description": "neutral, brand, blue, amber, red, violet"
    },
    "source": {
      "type": "string",
      "description": "manual, deploy, system, import, incident"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/notes/:id.json 메모 삭제 notes_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/notes/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "메모 ID, 예: note_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트, 워크스페이스 전체 메모는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "date": {
      "type": "string",
      "format": "date"
    },
    "end_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string",
          "description": "Markdown"
        },
        {
          "type": "null"
        }
      ]
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "color": {
      "type": "string",
      "description": "neutral, brand, blue, amber, red, violet"
    },
    "source": {
      "type": "string",
      "description": "manual, deploy, system, import, incident"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/notes.json 사이트의 메모 목록 보기 (워크스페이스 전체 메모 포함) notes_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/notes.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "from": {
      "type": "string",
      "format": "date",
      "description": "이 날짜 이후의 메모만"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "이 날짜 이전의 메모만"
    },
    "source": {
      "type": "string",
      "description": "이 소스의 메모만",
      "enum": [
        "manual",
        "deploy",
        "system",
        "import",
        "incident"
      ]
    },
    "query": {
      "type": "string",
      "description": "제목, 본문, 링크 검색"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "메모 ID, 예: note_7Q2K9XH3AB"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "사이트, 워크스페이스 전체 메모는 null"
          },
          {
            "type": "null"
          }
        ]
      },
      "date": {
        "type": "string",
        "format": "date"
      },
      "end_date": {
        "anyOf": [
          {
            "type": "string",
            "format": "date"
          },
          {
            "type": "null"
          }
        ]
      },
      "title": {
        "type": "string"
      },
      "body": {
        "anyOf": [
          {
            "type": "string",
            "description": "Markdown"
          },
          {
            "type": "null"
          }
        ]
      },
      "url": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "color": {
        "type": "string",
        "description": "neutral, brand, blue, amber, red, violet"
      },
      "source": {
        "type": "string",
        "description": "manual, deploy, system, import, incident"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /sites/:site_id/notes/:id.json 메모 조회 notes_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/notes/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "메모 ID, 예: note_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트, 워크스페이스 전체 메모는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "date": {
      "type": "string",
      "format": "date"
    },
    "end_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string",
          "description": "Markdown"
        },
        {
          "type": "null"
        }
      ]
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "color": {
      "type": "string",
      "description": "neutral, brand, blue, amber, red, violet"
    },
    "source": {
      "type": "string",
      "description": "manual, deploy, system, import, incident"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /sites/:site_id/notes/:id.json 메모 편집 notes_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/notes/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "format": "date",
      "description": "메모 날짜"
    },
    "end_date": {
      "type": "string",
      "format": "date",
      "description": "날짜 범위의 마지막 날"
    },
    "title": {
      "type": "string",
      "description": "차트에 표시되는 짧은 제목"
    },
    "body": {
      "type": "string",
      "description": "상세 내용 (Markdown)"
    },
    "url": {
      "type": "string",
      "description": "링크"
    },
    "color": {
      "type": "string",
      "description": "핀 색상",
      "enum": [
        "neutral",
        "brand",
        "blue",
        "amber",
        "red",
        "violet"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "메모 ID, 예: note_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트, 워크스페이스 전체 메모는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "date": {
      "type": "string",
      "format": "date"
    },
    "end_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string",
          "description": "Markdown"
        },
        {
          "type": "null"
        }
      ]
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "color": {
      "type": "string",
      "description": "neutral, brand, blue, amber, red, violet"
    },
    "source": {
      "type": "string",
      "description": "manual, deploy, system, import, incident"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /workspaces/:workspace_id/notes.json 워크스페이스 전체 메모 추가 (모든 사이트에 표시) workspace_notes_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/notes.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "format": "date",
      "description": "메모 날짜 (사이트 시간대). 기본값은 오늘"
    },
    "end_date": {
      "type": "string",
      "format": "date",
      "description": "날짜 범위의 마지막 날"
    },
    "title": {
      "type": "string",
      "description": "차트에 표시되는 짧은 제목",
      "examples": [
        "Launched new pricing"
      ]
    },
    "body": {
      "type": "string",
      "description": "상세 내용 (Markdown)"
    },
    "url": {
      "type": "string",
      "description": "링크, 예: PR 또는 변경 내역"
    },
    "color": {
      "type": "string",
      "description": "핀 색상",
      "enum": [
        "neutral",
        "brand",
        "blue",
        "amber",
        "red",
        "violet"
      ]
    },
    "source": {
      "type": "string",
      "description": "manual, 또는 릴리스 웹훅용 deploy",
      "enum": [
        "manual",
        "deploy",
        "system",
        "import",
        "incident"
      ],
      "default": "manual"
    },
    "version": {
      "type": "string",
      "description": "배포: 릴리스 버전 또는 커밋, 기본 제목에 사용됨"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "메모 ID, 예: note_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트, 워크스페이스 전체 메모는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "date": {
      "type": "string",
      "format": "date"
    },
    "end_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string",
          "description": "Markdown"
        },
        {
          "type": "null"
        }
      ]
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "color": {
      "type": "string",
      "description": "neutral, brand, blue, amber, red, violet"
    },
    "source": {
      "type": "string",
      "description": "manual, deploy, system, import, incident"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /workspaces/:workspace_id/notes/:id.json 워크스페이스 메모 삭제 workspace_notes_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:workspace_id/notes/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "메모 ID, 예: note_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트, 워크스페이스 전체 메모는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "date": {
      "type": "string",
      "format": "date"
    },
    "end_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string",
          "description": "Markdown"
        },
        {
          "type": "null"
        }
      ]
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "color": {
      "type": "string",
      "description": "neutral, brand, blue, amber, red, violet"
    },
    "source": {
      "type": "string",
      "description": "manual, deploy, system, import, incident"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/notes.json 워크스페이스 전체의 메모 목록 보기 workspace_notes_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/notes.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "from": {
      "type": "string",
      "format": "date",
      "description": "이 날짜 이후의 메모만"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "이 날짜 이전의 메모만"
    },
    "source": {
      "type": "string",
      "description": "이 소스의 메모만",
      "enum": [
        "manual",
        "deploy",
        "system",
        "import",
        "incident"
      ]
    },
    "query": {
      "type": "string",
      "description": "제목, 본문, 링크 검색"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "메모 ID, 예: note_7Q2K9XH3AB"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "사이트, 워크스페이스 전체 메모는 null"
          },
          {
            "type": "null"
          }
        ]
      },
      "date": {
        "type": "string",
        "format": "date"
      },
      "end_date": {
        "anyOf": [
          {
            "type": "string",
            "format": "date"
          },
          {
            "type": "null"
          }
        ]
      },
      "title": {
        "type": "string"
      },
      "body": {
        "anyOf": [
          {
            "type": "string",
            "description": "Markdown"
          },
          {
            "type": "null"
          }
        ]
      },
      "url": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "color": {
        "type": "string",
        "description": "neutral, brand, blue, amber, red, violet"
      },
      "source": {
        "type": "string",
        "description": "manual, deploy, system, import, incident"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
PATCH /workspaces/:workspace_id/notes/:id.json 워크스페이스 메모 편집 workspace_notes_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/notes/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "format": "date",
      "description": "메모 날짜"
    },
    "end_date": {
      "type": "string",
      "format": "date",
      "description": "날짜 범위의 마지막 날"
    },
    "title": {
      "type": "string",
      "description": "차트에 표시되는 짧은 제목"
    },
    "body": {
      "type": "string",
      "description": "상세 내용 (Markdown)"
    },
    "url": {
      "type": "string",
      "description": "링크"
    },
    "color": {
      "type": "string",
      "description": "핀 색상",
      "enum": [
        "neutral",
        "brand",
        "blue",
        "amber",
        "red",
        "violet"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "메모 ID, 예: note_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트, 워크스페이스 전체 메모는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "date": {
      "type": "string",
      "format": "date"
    },
    "end_date": {
      "anyOf": [
        {
          "type": "string",
          "format": "date"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string",
          "description": "Markdown"
        },
        {
          "type": "null"
        }
      ]
    },
    "url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "color": {
      "type": "string",
      "description": "neutral, brand, blue, amber, red, violet"
    },
    "source": {
      "type": "string",
      "description": "manual, deploy, system, import, incident"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

멤버

POST /workspaces/:workspace_id/invitations.json 이메일로 사용자 초대 invitations_create

권한: members.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/invitations.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "emails": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "초대할 이메일 주소"
    },
    "role": {
      "type": "string",
      "description": "새 멤버의 역할 (custom은 custom_role_id 필요)",
      "enum": [
        "admin",
        "editor",
        "analyst",
        "viewer",
        "billing",
        "custom"
      ],
      "default": "viewer"
    },
    "custom_role_id": {
      "type": "string",
      "description": "사용자 지정 역할 ID (Business)"
    },
    "all_sites": {
      "type": "boolean",
      "description": "향후 추가되는 사이트를 포함한 모든 사이트 접근",
      "default": true
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "all_sites가 false일 때 사이트 ID (pa_…)",
      "default": []
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "emails",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "email": {
      "type": "string"
    },
    "role": {
      "type": "string"
    },
    "custom_role": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "all_sites": {
      "type": "boolean"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "invited_by": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /workspaces/:workspace_id/invitations/:id.json 대기 중인 초대 취소 invitations_delete

권한: members.manage

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:workspace_id/invitations/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "email": {
      "type": "string"
    },
    "role": {
      "type": "string"
    },
    "custom_role": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "all_sites": {
      "type": "boolean"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "invited_by": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/invitations.json 대기 중인 초대 목록 보기 invitations_list

권한: members.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/invitations.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid"
      },
      "email": {
        "type": "string"
      },
      "role": {
        "type": "string"
      },
      "custom_role": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "all_sites": {
        "type": "boolean"
      },
      "site_ids": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "invited_by": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "expires_at": {
        "type": "string",
        "format": "date-time"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
DELETE /workspaces/:workspace_id/members/:id.json 멤버 제거 (또는 워크스페이스 나가기) members_delete

권한: member

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:workspace_id/members/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "멤버 ID (멤버를 수정하거나 제거할 때 사용)"
    },
    "email": {
      "type": "string"
    },
    "name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "role": {
      "type": "string",
      "description": "owner, admin, editor, analyst, viewer, billing 또는 custom"
    },
    "custom_role": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 역할 이름"
        },
        {
          "type": "null"
        }
      ]
    },
    "custom_role_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ]
    },
    "all_sites": {
      "type": "boolean",
      "description": "모든 사이트 접근"
    },
    "include_future_sites": {
      "type": "boolean"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "all_sites가 false일 때 사이트 ID"
    },
    "two_factor": {
      "type": "boolean",
      "description": "2FA 또는 패스키 사용 여부"
    },
    "last_active_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time",
      "description": "가입 시각"
    }
  }
}
GET /workspaces/:workspace_id/members.json 워크스페이스 멤버 목록 보기 members_list

권한: member

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/members.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "query": {
      "type": "string",
      "description": "이름 또는 이메일로 필터링"
    },
    "role": {
      "type": "string",
      "description": "이 역할의 멤버만",
      "enum": [
        "owner",
        "admin",
        "editor",
        "analyst",
        "viewer",
        "billing",
        "custom"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid",
        "description": "멤버 ID (멤버를 수정하거나 제거할 때 사용)"
      },
      "email": {
        "type": "string"
      },
      "name": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "role": {
        "type": "string",
        "description": "owner, admin, editor, analyst, viewer, billing 또는 custom"
      },
      "custom_role": {
        "anyOf": [
          {
            "type": "string",
            "description": "사용자 지정 역할 이름"
          },
          {
            "type": "null"
          }
        ]
      },
      "custom_role_id": {
        "anyOf": [
          {
            "type": "string",
            "format": "uuid"
          },
          {
            "type": "null"
          }
        ]
      },
      "all_sites": {
        "type": "boolean",
        "description": "모든 사이트 접근"
      },
      "include_future_sites": {
        "type": "boolean"
      },
      "site_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "all_sites가 false일 때 사이트 ID"
      },
      "two_factor": {
        "type": "boolean",
        "description": "2FA 또는 패스키 사용 여부"
      },
      "last_active_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time",
        "description": "가입 시각"
      }
    }
  }
}
PATCH /workspaces/:workspace_id/members/:id.json 멤버의 역할 또는 사이트 접근 권한 변경 members_update

권한: members.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/members/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "role": {
      "type": "string",
      "description": "새 역할 (custom은 custom_role_id 필요)",
      "enum": [
        "admin",
        "editor",
        "analyst",
        "viewer",
        "billing",
        "custom"
      ]
    },
    "custom_role_id": {
      "type": "string",
      "description": "사용자 지정 역할 ID (Business)"
    },
    "all_sites": {
      "type": "boolean",
      "description": "향후 추가되는 사이트를 포함한 모든 사이트 접근"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "all_sites가 false일 때 사이트 ID (pa_…)"
    },
    "include_future_sites": {
      "type": "boolean",
      "description": "나중에 추가되는 사이트에도 접근 권한 부여"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "멤버 ID (멤버를 수정하거나 제거할 때 사용)"
    },
    "email": {
      "type": "string"
    },
    "name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "role": {
      "type": "string",
      "description": "owner, admin, editor, analyst, viewer, billing 또는 custom"
    },
    "custom_role": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 역할 이름"
        },
        {
          "type": "null"
        }
      ]
    },
    "custom_role_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ]
    },
    "all_sites": {
      "type": "boolean",
      "description": "모든 사이트 접근"
    },
    "include_future_sites": {
      "type": "boolean"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "all_sites가 false일 때 사이트 ID"
    },
    "two_factor": {
      "type": "boolean",
      "description": "2FA 또는 패스키 사용 여부"
    },
    "last_active_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time",
      "description": "가입 시각"
    }
  }
}
POST /workspaces/:workspace_id/ownership_transfer.json 워크스페이스 소유권을 다른 멤버에게 이전 (소유자 전용, 본인은 관리자가 됨) ownership_transfers_create

권한: member

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/ownership_transfer.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "membership_id": {
      "type": "string",
      "description": "새 소유자의 멤버 ID"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "membership_id",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "멤버 ID (멤버를 수정하거나 제거할 때 사용)"
    },
    "email": {
      "type": "string"
    },
    "name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "role": {
      "type": "string",
      "description": "owner, admin, editor, analyst, viewer, billing 또는 custom"
    },
    "custom_role": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 역할 이름"
        },
        {
          "type": "null"
        }
      ]
    },
    "custom_role_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ]
    },
    "all_sites": {
      "type": "boolean",
      "description": "모든 사이트 접근"
    },
    "include_future_sites": {
      "type": "boolean"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "all_sites가 false일 때 사이트 ID"
    },
    "two_factor": {
      "type": "boolean",
      "description": "2FA 또는 패스키 사용 여부"
    },
    "last_active_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time",
      "description": "가입 시각"
    }
  }
}

목표

POST /sites/:site_id/goals/:id/archive.json 목표 보관 (리포트에서 숨김) goals_archive

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/goals/:id/archive.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "목표 ID, 예: goal_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "page, event, engagement, outbound 또는 download"
    },
    "match_type": {
      "type": "string",
      "description": "exact, prefix, glob 또는 regex"
    },
    "pattern": {
      "anyOf": [
        {
          "type": "string",
          "description": "경로, 도메인 또는 파일 패턴"
        },
        {
          "type": "null"
        }
      ]
    },
    "hostname": {
      "anyOf": [
        {
          "type": "string",
          "description": "호스트명 제한 (page 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "event_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 이벤트 이름 (event 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "이벤트 속성 조건"
    },
    "scroll_threshold": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 스크롤 %"
        },
        {
          "type": "null"
        }
      ]
    },
    "time_threshold_seconds": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 페이지 체류 시간 (초)"
        },
        {
          "type": "null"
        }
      ]
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed 또는 revenue"
    },
    "fixed_value_minor": {
      "anyOf": [
        {
          "type": "integer",
          "description": "최소 단위의 고정 가치"
        },
        {
          "type": "null"
        }
      ]
    },
    "count_mode": {
      "type": "string",
      "description": "once_per_visit 또는 every"
    },
    "archived": {
      "type": "boolean"
    },
    "archived_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "completions": {
              "type": "integer",
              "description": "일치한 이벤트 (반복 포함)"
            },
            "conversions": {
              "type": "integer",
              "description": "완료가 한 번 이상 있는 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
            },
            "value": {
              "type": "integer",
              "description": "사이트 통화 최소 단위의 목표 가치"
            },
            "change": {
              "anyOf": [
                {
                  "type": "number",
                  "description": "이전 기간 대비 전환 변화, %"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/goals.json 목표 만들기 goals_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/goals.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "목표 이름",
      "examples": [
        "Signed up"
      ]
    },
    "kind": {
      "type": "string",
      "description": "page (페이지 방문), event (사용자 지정 이벤트), engagement (스크롤 또는 페이지 체류 시간), outbound (외부 링크 클릭), download (파일 다운로드)",
      "enum": [
        "page",
        "event",
        "engagement",
        "outbound",
        "download"
      ]
    },
    "match_type": {
      "type": "string",
      "description": "pattern이 경로 (page, engagement), 링크 도메인 (outbound), 파일 (download)과 일치하는 방식: exact, prefix, glob (*) 또는 regex",
      "enum": [
        "exact",
        "prefix",
        "glob",
        "regex"
      ],
      "default": "exact"
    },
    "pattern": {
      "type": "string",
      "description": "경로, 도메인 또는 파일 패턴, 예: /pricing, /blog/*, stripe.com 또는 *.pdf"
    },
    "hostname": {
      "type": "string",
      "description": "이 호스트명의 페이지만 집계 (page 목표)"
    },
    "event_name": {
      "type": "string",
      "description": "사용자 지정 이벤트 이름 (event 목표)"
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true
      },
      "description": "이벤트 속성 조건: [{\"key\": \"plan\", \"operator\": \"is|is_not|contains|gt|lt\", \"value\": \"pro\"}]",
      "default": []
    },
    "scroll_threshold": {
      "type": "integer",
      "description": "engagement: 도달해야 하는 스크롤 깊이 %"
    },
    "time_threshold_seconds": {
      "type": "integer",
      "description": "engagement: 페이지 체류 시간 (초)"
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed (전환당 fixed_value) 또는 revenue (이벤트 매출)",
      "enum": [
        "none",
        "fixed",
        "revenue"
      ],
      "default": "none"
    },
    "fixed_value": {
      "type": "number",
      "description": "사이트 통화 기준 전환당 고정 가치, 예: 50.0"
    },
    "count_mode": {
      "type": "string",
      "description": "가치를 once_per_visit 또는 every completion으로 집계",
      "enum": [
        "once_per_visit",
        "every"
      ],
      "default": "once_per_visit"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "kind",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "목표 ID, 예: goal_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "page, event, engagement, outbound 또는 download"
    },
    "match_type": {
      "type": "string",
      "description": "exact, prefix, glob 또는 regex"
    },
    "pattern": {
      "anyOf": [
        {
          "type": "string",
          "description": "경로, 도메인 또는 파일 패턴"
        },
        {
          "type": "null"
        }
      ]
    },
    "hostname": {
      "anyOf": [
        {
          "type": "string",
          "description": "호스트명 제한 (page 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "event_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 이벤트 이름 (event 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "이벤트 속성 조건"
    },
    "scroll_threshold": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 스크롤 %"
        },
        {
          "type": "null"
        }
      ]
    },
    "time_threshold_seconds": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 페이지 체류 시간 (초)"
        },
        {
          "type": "null"
        }
      ]
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed 또는 revenue"
    },
    "fixed_value_minor": {
      "anyOf": [
        {
          "type": "integer",
          "description": "최소 단위의 고정 가치"
        },
        {
          "type": "null"
        }
      ]
    },
    "count_mode": {
      "type": "string",
      "description": "once_per_visit 또는 every"
    },
    "archived": {
      "type": "boolean"
    },
    "archived_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "completions": {
              "type": "integer",
              "description": "일치한 이벤트 (반복 포함)"
            },
            "conversions": {
              "type": "integer",
              "description": "완료가 한 번 이상 있는 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
            },
            "value": {
              "type": "integer",
              "description": "사이트 통화 최소 단위의 목표 가치"
            },
            "change": {
              "anyOf": [
                {
                  "type": "number",
                  "description": "이전 기간 대비 전환 변화, %"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/goals/:id.json 목표 삭제 (데이터는 유지됨) goals_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/goals/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "목표 ID, 예: goal_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "page, event, engagement, outbound 또는 download"
    },
    "match_type": {
      "type": "string",
      "description": "exact, prefix, glob 또는 regex"
    },
    "pattern": {
      "anyOf": [
        {
          "type": "string",
          "description": "경로, 도메인 또는 파일 패턴"
        },
        {
          "type": "null"
        }
      ]
    },
    "hostname": {
      "anyOf": [
        {
          "type": "string",
          "description": "호스트명 제한 (page 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "event_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 이벤트 이름 (event 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "이벤트 속성 조건"
    },
    "scroll_threshold": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 스크롤 %"
        },
        {
          "type": "null"
        }
      ]
    },
    "time_threshold_seconds": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 페이지 체류 시간 (초)"
        },
        {
          "type": "null"
        }
      ]
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed 또는 revenue"
    },
    "fixed_value_minor": {
      "anyOf": [
        {
          "type": "integer",
          "description": "최소 단위의 고정 가치"
        },
        {
          "type": "null"
        }
      ]
    },
    "count_mode": {
      "type": "string",
      "description": "once_per_visit 또는 every"
    },
    "archived": {
      "type": "boolean"
    },
    "archived_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "completions": {
              "type": "integer",
              "description": "일치한 이벤트 (반복 포함)"
            },
            "conversions": {
              "type": "integer",
              "description": "완료가 한 번 이상 있는 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
            },
            "value": {
              "type": "integer",
              "description": "사이트 통화 최소 단위의 목표 가치"
            },
            "change": {
              "anyOf": [
                {
                  "type": "number",
                  "description": "이전 기간 대비 전환 변화, %"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/goals/:id/duplicate.json 목표 복사 goals_duplicate

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/goals/:id/duplicate.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "복사본 이름"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "목표 ID, 예: goal_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "page, event, engagement, outbound 또는 download"
    },
    "match_type": {
      "type": "string",
      "description": "exact, prefix, glob 또는 regex"
    },
    "pattern": {
      "anyOf": [
        {
          "type": "string",
          "description": "경로, 도메인 또는 파일 패턴"
        },
        {
          "type": "null"
        }
      ]
    },
    "hostname": {
      "anyOf": [
        {
          "type": "string",
          "description": "호스트명 제한 (page 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "event_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 이벤트 이름 (event 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "이벤트 속성 조건"
    },
    "scroll_threshold": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 스크롤 %"
        },
        {
          "type": "null"
        }
      ]
    },
    "time_threshold_seconds": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 페이지 체류 시간 (초)"
        },
        {
          "type": "null"
        }
      ]
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed 또는 revenue"
    },
    "fixed_value_minor": {
      "anyOf": [
        {
          "type": "integer",
          "description": "최소 단위의 고정 가치"
        },
        {
          "type": "null"
        }
      ]
    },
    "count_mode": {
      "type": "string",
      "description": "once_per_visit 또는 every"
    },
    "archived": {
      "type": "boolean"
    },
    "archived_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "completions": {
              "type": "integer",
              "description": "일치한 이벤트 (반복 포함)"
            },
            "conversions": {
              "type": "integer",
              "description": "완료가 한 번 이상 있는 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
            },
            "value": {
              "type": "integer",
              "description": "사이트 통화 최소 단위의 목표 가치"
            },
            "change": {
              "anyOf": [
                {
                  "type": "number",
                  "description": "이전 기간 대비 전환 변화, %"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/goals.json 기간의 완료 수, 전환 수, 비율, 가치가 포함된 목표 목록 보기 goals_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/goals.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "status": {
      "type": "string",
      "description": "active, archived 또는 all 목표",
      "enum": [
        "active",
        "archived",
        "all"
      ],
      "default": "active"
    },
    "page": {
      "type": "integer",
      "description": "페이지 번호",
      "default": 1
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 목표 수 (최대 100)",
      "default": 25
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "목표 ID, 예: goal_7Q2K9XH3AB"
      },
      "name": {
        "type": "string"
      },
      "kind": {
        "type": "string",
        "description": "page, event, engagement, outbound 또는 download"
      },
      "match_type": {
        "type": "string",
        "description": "exact, prefix, glob 또는 regex"
      },
      "pattern": {
        "anyOf": [
          {
            "type": "string",
            "description": "경로, 도메인 또는 파일 패턴"
          },
          {
            "type": "null"
          }
        ]
      },
      "hostname": {
        "anyOf": [
          {
            "type": "string",
            "description": "호스트명 제한 (page 목표)"
          },
          {
            "type": "null"
          }
        ]
      },
      "event_name": {
        "anyOf": [
          {
            "type": "string",
            "description": "사용자 지정 이벤트 이름 (event 목표)"
          },
          {
            "type": "null"
          }
        ]
      },
      "conditions": {
        "type": "array",
        "items": {
          "type": "object"
        },
        "description": "이벤트 속성 조건"
      },
      "scroll_threshold": {
        "anyOf": [
          {
            "type": "integer",
            "description": "engagement: 스크롤 %"
          },
          {
            "type": "null"
          }
        ]
      },
      "time_threshold_seconds": {
        "anyOf": [
          {
            "type": "integer",
            "description": "engagement: 페이지 체류 시간 (초)"
          },
          {
            "type": "null"
          }
        ]
      },
      "value_mode": {
        "type": "string",
        "description": "none, fixed 또는 revenue"
      },
      "fixed_value_minor": {
        "anyOf": [
          {
            "type": "integer",
            "description": "최소 단위의 고정 가치"
          },
          {
            "type": "null"
          }
        ]
      },
      "count_mode": {
        "type": "string",
        "description": "once_per_visit 또는 every"
      },
      "archived": {
        "type": "boolean"
      },
      "archived_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "stats": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "completions": {
                "type": "integer",
                "description": "일치한 이벤트 (반복 포함)"
              },
              "conversions": {
                "type": "integer",
                "description": "완료가 한 번 이상 있는 방문"
              },
              "conversion_rate": {
                "type": "number",
                "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
              },
              "value": {
                "type": "integer",
                "description": "사이트 통화 최소 단위의 목표 가치"
              },
              "change": {
                "anyOf": [
                  {
                    "type": "number",
                    "description": "이전 기간 대비 전환 변화, %"
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "description": "기간 통계 (목록에서만)"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      },
      "updated_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /sites/:site_id/goals/:id.json 목표 리포트: 지표, 차트, 세부 분석, 전환까지의 여정 goals_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/goals/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "interval": {
      "type": "string",
      "description": "차트 구간 크기",
      "enum": [
        "auto",
        "minute",
        "hour",
        "day",
        "week",
        "month",
        "quarter",
        "year"
      ],
      "default": "auto"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "period": {
      "type": "object",
      "description": "기간의 from/to (UTC)"
    },
    "goal": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "목표 ID, 예: goal_7Q2K9XH3AB"
        },
        "name": {
          "type": "string"
        },
        "kind": {
          "type": "string",
          "description": "page, event, engagement, outbound 또는 download"
        },
        "match_type": {
          "type": "string",
          "description": "exact, prefix, glob 또는 regex"
        },
        "pattern": {
          "anyOf": [
            {
              "type": "string",
              "description": "경로, 도메인 또는 파일 패턴"
            },
            {
              "type": "null"
            }
          ]
        },
        "hostname": {
          "anyOf": [
            {
              "type": "string",
              "description": "호스트명 제한 (page 목표)"
            },
            {
              "type": "null"
            }
          ]
        },
        "event_name": {
          "anyOf": [
            {
              "type": "string",
              "description": "사용자 지정 이벤트 이름 (event 목표)"
            },
            {
              "type": "null"
            }
          ]
        },
        "conditions": {
          "type": "array",
          "items": {
            "type": "object"
          },
          "description": "이벤트 속성 조건"
        },
        "scroll_threshold": {
          "anyOf": [
            {
              "type": "integer",
              "description": "engagement: 스크롤 %"
            },
            {
              "type": "null"
            }
          ]
        },
        "time_threshold_seconds": {
          "anyOf": [
            {
              "type": "integer",
              "description": "engagement: 페이지 체류 시간 (초)"
            },
            {
              "type": "null"
            }
          ]
        },
        "value_mode": {
          "type": "string",
          "description": "none, fixed 또는 revenue"
        },
        "fixed_value_minor": {
          "anyOf": [
            {
              "type": "integer",
              "description": "최소 단위의 고정 가치"
            },
            {
              "type": "null"
            }
          ]
        },
        "count_mode": {
          "type": "string",
          "description": "once_per_visit 또는 every"
        },
        "archived": {
          "type": "boolean"
        },
        "archived_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time"
            },
            {
              "type": "null"
            }
          ]
        },
        "stats": {
          "anyOf": [
            {
              "type": "object",
              "properties": {
                "completions": {
                  "type": "integer",
                  "description": "일치한 이벤트 (반복 포함)"
                },
                "conversions": {
                  "type": "integer",
                  "description": "완료가 한 번 이상 있는 방문"
                },
                "conversion_rate": {
                  "type": "number",
                  "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
                },
                "value": {
                  "type": "integer",
                  "description": "사이트 통화 최소 단위의 목표 가치"
                },
                "change": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "이전 기간 대비 전환 변화, %"
                    },
                    {
                      "type": "null"
                    }
                  ]
                }
              },
              "description": "기간 통계 (목록에서만)"
            },
            {
              "type": "null"
            }
          ]
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "description": "목표 정의"
    },
    "metrics": {
      "type": "object",
      "description": "completions, conversions, conversion_rate (%), value (최소 단위)"
    },
    "comparison_period": {
      "anyOf": [
        {
          "type": "object",
          "description": "비교 기간의 from/to"
        },
        {
          "type": "null"
        }
      ]
    },
    "comparison": {
      "anyOf": [
        {
          "type": "object",
          "description": "비교 기간의 지표"
        },
        {
          "type": "null"
        }
      ]
    },
    "change": {
      "anyOf": [
        {
          "type": "object",
          "description": "비교 대비 변화, 지표별 %"
        },
        {
          "type": "null"
        }
      ]
    },
    "interval": {
      "type": "string",
      "description": "차트 구간 크기"
    },
    "series": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "구간별: date, completions, conversions, conversion_rate"
    },
    "breakdowns": {
      "type": "object",
      "description": "channel, utm_campaign, entry_page, country, device별 전환 상위 값: value, completions, conversions, conversion_rate"
    },
    "journey": {
      "anyOf": [
        {
          "type": "object",
          "description": "converting_visits, median_seconds_to_convert, median_pages_before, pages_before (전환한 방문이 그 방문에서 앞서 본 페이지)"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /sites/:site_id/goals/:id/unarchive.json 보관된 목표 복원 goals_unarchive

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/goals/:id/unarchive.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "목표 ID, 예: goal_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "page, event, engagement, outbound 또는 download"
    },
    "match_type": {
      "type": "string",
      "description": "exact, prefix, glob 또는 regex"
    },
    "pattern": {
      "anyOf": [
        {
          "type": "string",
          "description": "경로, 도메인 또는 파일 패턴"
        },
        {
          "type": "null"
        }
      ]
    },
    "hostname": {
      "anyOf": [
        {
          "type": "string",
          "description": "호스트명 제한 (page 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "event_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 이벤트 이름 (event 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "이벤트 속성 조건"
    },
    "scroll_threshold": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 스크롤 %"
        },
        {
          "type": "null"
        }
      ]
    },
    "time_threshold_seconds": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 페이지 체류 시간 (초)"
        },
        {
          "type": "null"
        }
      ]
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed 또는 revenue"
    },
    "fixed_value_minor": {
      "anyOf": [
        {
          "type": "integer",
          "description": "최소 단위의 고정 가치"
        },
        {
          "type": "null"
        }
      ]
    },
    "count_mode": {
      "type": "string",
      "description": "once_per_visit 또는 every"
    },
    "archived": {
      "type": "boolean"
    },
    "archived_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "completions": {
              "type": "integer",
              "description": "일치한 이벤트 (반복 포함)"
            },
            "conversions": {
              "type": "integer",
              "description": "완료가 한 번 이상 있는 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
            },
            "value": {
              "type": "integer",
              "description": "사이트 통화 최소 단위의 목표 가치"
            },
            "change": {
              "anyOf": [
                {
                  "type": "number",
                  "description": "이전 기간 대비 전환 변화, %"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /sites/:site_id/goals/:id.json 목표 수정 goals_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/goals/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "목표 이름",
      "examples": [
        "Signed up"
      ]
    },
    "kind": {
      "type": "string",
      "description": "page (페이지 방문), event (사용자 지정 이벤트), engagement (스크롤 또는 페이지 체류 시간), outbound (외부 링크 클릭), download (파일 다운로드)",
      "enum": [
        "page",
        "event",
        "engagement",
        "outbound",
        "download"
      ]
    },
    "match_type": {
      "type": "string",
      "description": "pattern이 경로 (page, engagement), 링크 도메인 (outbound), 파일 (download)과 일치하는 방식: exact, prefix, glob (*) 또는 regex",
      "enum": [
        "exact",
        "prefix",
        "glob",
        "regex"
      ]
    },
    "pattern": {
      "type": "string",
      "description": "경로, 도메인 또는 파일 패턴, 예: /pricing, /blog/*, stripe.com 또는 *.pdf"
    },
    "hostname": {
      "type": "string",
      "description": "이 호스트명의 페이지만 집계 (page 목표)"
    },
    "event_name": {
      "type": "string",
      "description": "사용자 지정 이벤트 이름 (event 목표)"
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true
      },
      "description": "이벤트 속성 조건: [{\"key\": \"plan\", \"operator\": \"is|is_not|contains|gt|lt\", \"value\": \"pro\"}]"
    },
    "scroll_threshold": {
      "type": "integer",
      "description": "engagement: 도달해야 하는 스크롤 깊이 %"
    },
    "time_threshold_seconds": {
      "type": "integer",
      "description": "engagement: 페이지 체류 시간 (초)"
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed (전환당 fixed_value) 또는 revenue (이벤트 매출)",
      "enum": [
        "none",
        "fixed",
        "revenue"
      ]
    },
    "fixed_value": {
      "type": "number",
      "description": "사이트 통화 기준 전환당 고정 가치, 예: 50.0"
    },
    "count_mode": {
      "type": "string",
      "description": "가치를 once_per_visit 또는 every completion으로 집계",
      "enum": [
        "once_per_visit",
        "every"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "목표 ID, 예: goal_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "page, event, engagement, outbound 또는 download"
    },
    "match_type": {
      "type": "string",
      "description": "exact, prefix, glob 또는 regex"
    },
    "pattern": {
      "anyOf": [
        {
          "type": "string",
          "description": "경로, 도메인 또는 파일 패턴"
        },
        {
          "type": "null"
        }
      ]
    },
    "hostname": {
      "anyOf": [
        {
          "type": "string",
          "description": "호스트명 제한 (page 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "event_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "사용자 지정 이벤트 이름 (event 목표)"
        },
        {
          "type": "null"
        }
      ]
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "이벤트 속성 조건"
    },
    "scroll_threshold": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 스크롤 %"
        },
        {
          "type": "null"
        }
      ]
    },
    "time_threshold_seconds": {
      "anyOf": [
        {
          "type": "integer",
          "description": "engagement: 페이지 체류 시간 (초)"
        },
        {
          "type": "null"
        }
      ]
    },
    "value_mode": {
      "type": "string",
      "description": "none, fixed 또는 revenue"
    },
    "fixed_value_minor": {
      "anyOf": [
        {
          "type": "integer",
          "description": "최소 단위의 고정 가치"
        },
        {
          "type": "null"
        }
      ]
    },
    "count_mode": {
      "type": "string",
      "description": "once_per_visit 또는 every"
    },
    "archived": {
      "type": "boolean"
    },
    "archived_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "completions": {
              "type": "integer",
              "description": "일치한 이벤트 (반복 포함)"
            },
            "conversions": {
              "type": "integer",
              "description": "완료가 한 번 이상 있는 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "전환 ÷ 방문 (사이트 설정에 따라 ÷ 방문자), %"
            },
            "value": {
              "type": "integer",
              "description": "사이트 통화 최소 단위의 목표 가치"
            },
            "change": {
              "anyOf": [
                {
                  "type": "number",
                  "description": "이전 기간 대비 전환 변화, %"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

문서

GET /docs/api.json 모든 API 작업과 MCP 도구 목록 보기 docs_api

권한: public

예시
curl https://privatusanalytics.com/docs/api.json
입력
{
  "type": "object",
  "properties": {
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "tool_name": {
        "type": "string",
        "description": "MCP 도구 이름과 OpenAPI operationId"
      },
      "summary": {
        "type": "string"
      },
      "description": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "group": {
        "type": "string"
      },
      "verb": {
        "type": "string",
        "description": "HTTP 메서드"
      },
      "path": {
        "type": "string",
        "description": "경로 템플릿. JSON은 .json을 붙이세요"
      },
      "permission": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "input_schema": {
        "type": "object",
        "description": "입력의 JSON Schema"
      },
      "response_schema": {
        "type": "object",
        "description": "`data`의 JSON Schema"
      }
    }
  }
}
GET /docs.json 문서 페이지 목록 보기 docs_list

권한: public

예시
curl https://privatusanalytics.com/docs.json
입력
{
  "type": "object",
  "properties": {
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "title": {
        "type": "string",
        "description": "페이지 제목"
      },
      "description": {
        "type": "string",
        "description": "한 줄 요약"
      },
      "path": {
        "type": "string",
        "description": "페이지 경로. Markdown은 .md, JSON은 .json을 붙이세요"
      },
      "section": {
        "type": "string",
        "description": "섹션 슬러그, 예: tracker"
      }
    }
  }
}
GET /openapi.json 전체 API의 OpenAPI 3.1 문서 docs_openapi

권한: public

예시
curl https://privatusanalytics.com/openapi.json
입력
{
  "type": "object",
  "properties": {},
  "required": []
}
응답 데이터
{
  "type": "object"
}
GET /docs/:section/:page.json 문서 페이지 읽기 (Markdown 및 HTML) docs_get

section과 page는 페이지 경로 /docs/<section>/<page>에서 가져옵니다. 섹션 개요는 page에 "index"를 사용하세요.

권한: public

예시
curl https://privatusanalytics.com/docs/:section/:page.json
입력
{
  "type": "object",
  "properties": {
    "section": {
      "type": "string",
      "description": "리소스의 Section"
    },
    "page": {
      "type": "string",
      "description": "리소스의 Page"
    }
  },
  "required": [
    "section",
    "page"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "페이지 제목"
    },
    "description": {
      "type": "string",
      "description": "한 줄 요약"
    },
    "path": {
      "type": "string",
      "description": "페이지 경로. Markdown은 .md, JSON은 .json을 붙이세요"
    },
    "section": {
      "type": "string",
      "description": "섹션 슬러그, 예: tracker"
    },
    "headings": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "페이지의 섹션 (id와 텍스트)"
    },
    "full_markdown": {
      "type": "string",
      "description": "Markdown 형식의 페이지 (제목 포함)"
    },
    "html": {
      "type": "string",
      "description": "HTML로 렌더링된 페이지 본문"
    }
  }
}

분석

GET /sites/:site_id/overview.json 사이트 개요: 지표, 차트 시리즈, 상위 패널, 실시간 방문자, 메모 stats_overview

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/overview.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "interval": {
      "type": "string",
      "description": "차트 구간 크기",
      "enum": [
        "auto",
        "minute",
        "hour",
        "day",
        "week",
        "month",
        "quarter",
        "year"
      ],
      "default": "auto"
    },
    "panels": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "상위 값을 포함할 차원",
      "default": [
        "channel",
        "referrer",
        "page",
        "entry_page",
        "country",
        "device",
        "browser",
        "os",
        "utm_campaign",
        "event",
        "goal"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/experiments.json 실험 리포트: 변형별 전환율, 대조군 대비 상승률, 유의성 (두 비율 z-검정) experiments_report

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/experiments.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "property": {
      "type": "string",
      "description": "변형을 담은 이벤트 속성, 예: variant",
      "examples": [
        "variant"
      ]
    },
    "goal_id": {
      "type": "string",
      "description": "전환으로 집계할 목표 (goal_…)"
    },
    "control": {
      "type": "string",
      "description": "대조군 변형 (있으면 기본값은 \"control\", 없으면 방문이 가장 많은 변형)"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "property",
    "goal_id",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/insights.json 이전 기간 대비 주목할 만한 변화를 일상 언어로 요약 (가장 크게 변한 항목, 목표 전환 변화) insights_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/insights.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "어제까지의 완료된 날짜를 그 이전 같은 일수와 비교",
      "enum": [
        "7d",
        "14d",
        "28d",
        "30d"
      ],
      "default": "7d"
    },
    "limit": {
      "type": "integer",
      "description": "인사이트 최대 개수 (1에서 20)",
      "default": 8
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/journeys.json 여정: 페이지(또는 임의의 진입점) 이후, 또는 페이지나 목표 이전의 상위 3단계 경로 journeys_explore

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/journeys.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "mode": {
      "type": "string",
      "description": "forward: 시작 페이지 이후의 페이지, reverse: 종료 페이지 또는 목표로 이어지는 페이지",
      "enum": [
        "forward",
        "reverse"
      ],
      "default": "forward"
    },
    "path": {
      "type": "string",
      "description": "시작 페이지 (forward) 또는 종료 페이지 (reverse). 비우면 모든 진입점 (forward만)"
    },
    "goal_id": {
      "type": "string",
      "description": "reverse 모드: 페이지 대신 이 목표 (goal_…)에서 끝남"
    },
    "limit": {
      "type": "integer",
      "description": "단계당 표시할 페이지 수 (최대 12)",
      "default": 6
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/pages/detail.json 페이지 상세: 한 경로의 지표, 이전 및 다음 페이지, 소스, 웹 바이탈, 이벤트, 클릭 맵 pages_detail

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/pages/detail.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "path": {
      "type": "string",
      "description": "페이지 경로, 예: /pricing",
      "examples": [
        "/pricing"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "path",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/stats/aggregate.json 기간의 주요 지표 (비교 포함) stats_aggregate

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/stats/aggregate.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/breakdown/:dimension.json 차원의 상위 값 (페이지, 소스, 국가 등) stats_breakdown

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/breakdown/:dimension.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "dimension": {
      "type": "string",
      "description": "리소스의 Dimension"
    },
    "limit": {
      "type": "integer",
      "description": "페이지당 행 수 (최대 1000)",
      "default": 10
    },
    "page": {
      "type": "integer",
      "description": "페이지 번호",
      "default": 1
    },
    "sort": {
      "type": "string",
      "description": "정렬 지표",
      "enum": [
        "visitors",
        "visits",
        "pageviews",
        "revenue"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "dimension",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/stats/timeseries.json 차트용 시간 구간별 지표 stats_timeseries

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/stats/timeseries.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "interval": {
      "type": "string",
      "description": "구간 크기. auto는 범위에 맞게 선택",
      "enum": [
        "auto",
        "minute",
        "hour",
        "day",
        "week",
        "month",
        "quarter",
        "year"
      ],
      "default": "auto"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}

사이트

POST /sites/:site_id/data_reset.json 날짜 범위의 모든 이벤트와 방문 삭제 (백그라운드에서 실행되며 되돌릴 수 없음) sites_reset_data

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/data_reset.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "from": {
      "type": "string",
      "format": "date",
      "description": "삭제할 첫째 날 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "삭제할 마지막 날 (포함)"
    },
    "confirm": {
      "type": "string",
      "description": "확인을 위해 도메인을 입력하세요"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "from",
    "to",
    "confirm",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/filter_stats.json 필터링된 트래픽 요약: 사유 및 국가별 봇, 트래픽 규칙, 개인정보 삭제 (집계 수만) sites_filter_stats

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/filter_stats.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "kind": {
      "type": "string",
      "description": "bot (필터링된 봇), rule (트래픽 규칙) 또는 redaction (PII 스크러버)",
      "enum": [
        "bot",
        "rule",
        "redaction"
      ],
      "default": "bot"
    },
    "days": {
      "type": "integer",
      "description": "되돌아볼 일수 (1-395)",
      "default": 30
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/access.json 멤버와 이 사이트를 볼 수 있는지 여부 목록 보기 sites_access_list

권한: members.manage

예시
curl https://privatusanalytics.com/sites/:site_id/access.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "membership_id": {
      "type": "string",
      "format": "uuid",
      "description": "멤버십 ID"
    },
    "email": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "role": {
      "type": "string"
    },
    "access": {
      "type": "boolean",
      "description": "이 사이트를 볼 수 있음"
    },
    "locked": {
      "type": "boolean",
      "description": "소유자와 관리자는 항상 접근 가능"
    }
  }
}
PATCH /sites/:site_id/access.json 멤버 한 명의 이 사이트 접근 권한 부여 또는 제거 sites_access_update

권한: members.manage

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/access.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "membership_id": {
      "type": "string",
      "description": "sites_access_list의 멤버십 ID"
    },
    "access": {
      "type": "boolean",
      "description": "접근을 부여하려면 true, 제거하려면 false"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "membership_id",
    "access",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "membership_id": {
      "type": "string",
      "format": "uuid",
      "description": "멤버십 ID"
    },
    "email": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "role": {
      "type": "string"
    },
    "access": {
      "type": "boolean",
      "description": "이 사이트를 볼 수 있음"
    },
    "locked": {
      "type": "boolean",
      "description": "소유자와 관리자는 항상 접근 가능"
    }
  }
}
POST /sites/:site_id/favorite.json 사이트에 별표 표시 (모든 사이트에서 맨 위에 고정) sites_favorite

권한: analytics.read

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/favorite.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "추적 스니펫에 사용되는 사이트 ID"
    },
    "workspace_id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "multi_domain_mode": {
      "type": "string"
    },
    "timezone": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "week_start": {
      "type": "integer"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "honor_dnt": {
      "type": "boolean"
    },
    "honor_gpc": {
      "type": "boolean"
    },
    "pii_scrubber": {
      "type": "boolean"
    },
    "redaction_rules": {
      "type": "array"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "path_masks": {
      "type": "array"
    },
    "retention_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "bot_filtering": {
      "type": "boolean"
    },
    "traffic_rule_modes": {
      "type": "object"
    },
    "vitals_sample_rate": {
      "type": "integer"
    },
    "conversion_denominator": {
      "type": "string"
    },
    "public_dashboard": {
      "type": "boolean"
    },
    "public_indexable": {
      "type": "boolean"
    },
    "ingest_key_prefix": {
      "anyOf": [
        {
          "type": "string",
          "description": "서버 수집 키의 앞부분"
        },
        {
          "type": "null"
        }
      ]
    },
    "verified_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "first_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "snippet": {
      "type": "string",
      "description": "HTML 추적 스니펫"
    },
    "favorite": {
      "type": "boolean",
      "description": "내가 별표 표시함"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/favorite.json 사이트 별표 해제 sites_unfavorite

권한: analytics.read

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/favorite.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "추적 스니펫에 사용되는 사이트 ID"
    },
    "workspace_id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "multi_domain_mode": {
      "type": "string"
    },
    "timezone": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "week_start": {
      "type": "integer"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "honor_dnt": {
      "type": "boolean"
    },
    "honor_gpc": {
      "type": "boolean"
    },
    "pii_scrubber": {
      "type": "boolean"
    },
    "redaction_rules": {
      "type": "array"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "path_masks": {
      "type": "array"
    },
    "retention_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "bot_filtering": {
      "type": "boolean"
    },
    "traffic_rule_modes": {
      "type": "object"
    },
    "vitals_sample_rate": {
      "type": "integer"
    },
    "conversion_denominator": {
      "type": "string"
    },
    "public_dashboard": {
      "type": "boolean"
    },
    "public_indexable": {
      "type": "boolean"
    },
    "ingest_key_prefix": {
      "anyOf": [
        {
          "type": "string",
          "description": "서버 수집 키의 앞부분"
        },
        {
          "type": "null"
        }
      ]
    },
    "verified_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "first_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "snippet": {
      "type": "string",
      "description": "HTML 추적 스니펫"
    },
    "favorite": {
      "type": "boolean",
      "description": "내가 별표 표시함"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/setup.json 사이트의 설치 상태와 스니펫 sites_setup_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/setup.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /transfers/:token/accept.json 내 워크스페이스 중 하나로 사이트 이전 수락 site_transfers_accept

권한: public

예시
curl -X POST https://privatusanalytics.com/transfers/:token/accept.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "사이트를 옮길 워크스페이스 (ws_…)"
    },
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "workspace_id",
    "token"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "이전 중인 사이트"
    },
    "site_domain": {
      "type": "string"
    },
    "from_workspace": {
      "type": "string",
      "description": "현재 워크스페이스 이름"
    },
    "to_workspace_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "받는 워크스페이스"
        },
        {
          "type": "null"
        }
      ]
    },
    "to_email": {
      "type": "string",
      "description": "수신자 이메일"
    },
    "status": {
      "type": "string",
      "description": "pending, accepted 또는 canceled"
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/transfer.json 사이트를 다른 워크스페이스로 이전 시작 (수신자에게 이메일 발송) sites_transfer_start

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/transfer.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "description": "사이트를 받을 사람의 이메일 (본인의 워크스페이스 중 하나를 선택함)"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "email",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "이전 중인 사이트"
    },
    "site_domain": {
      "type": "string"
    },
    "from_workspace": {
      "type": "string",
      "description": "현재 워크스페이스 이름"
    },
    "to_workspace_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "받는 워크스페이스"
        },
        {
          "type": "null"
        }
      ]
    },
    "to_email": {
      "type": "string",
      "description": "수신자 이메일"
    },
    "status": {
      "type": "string",
      "description": "pending, accepted 또는 canceled"
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/transfer.json 대기 중인 사이트 이전 취소 sites_transfer_cancel

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/transfer.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "이전 중인 사이트"
    },
    "site_domain": {
      "type": "string"
    },
    "from_workspace": {
      "type": "string",
      "description": "현재 워크스페이스 이름"
    },
    "to_workspace_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "받는 워크스페이스"
        },
        {
          "type": "null"
        }
      ]
    },
    "to_email": {
      "type": "string",
      "description": "수신자 이메일"
    },
    "status": {
      "type": "string",
      "description": "pending, accepted 또는 canceled"
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /transfers/:token.json 이메일로 받은 토큰으로 대기 중인 이전 조회 site_transfers_get

권한: public

예시
curl https://privatusanalytics.com/transfers/:token.json
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "이전 중인 사이트"
    },
    "site_domain": {
      "type": "string"
    },
    "from_workspace": {
      "type": "string",
      "description": "현재 워크스페이스 이름"
    },
    "to_workspace_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "받는 워크스페이스"
        },
        {
          "type": "null"
        }
      ]
    },
    "to_email": {
      "type": "string",
      "description": "수신자 이메일"
    },
    "status": {
      "type": "string",
      "description": "pending, accepted 또는 canceled"
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /workspaces/:workspace_id/sites.json 사이트 추가 sites_create

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/sites.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "domain": {
      "type": "string",
      "description": "기본 도메인, 예: example.com",
      "examples": [
        "example.com"
      ]
    },
    "name": {
      "type": "string",
      "description": "표시 이름 (기본값은 도메인)"
    },
    "timezone": {
      "type": "string",
      "description": "리포트 시간대"
    },
    "currency": {
      "type": "string",
      "description": "매출 통화 (ISO 4217)"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "domain",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "추적 스니펫에 사용되는 사이트 ID"
    },
    "workspace_id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "multi_domain_mode": {
      "type": "string"
    },
    "timezone": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "week_start": {
      "type": "integer"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "honor_dnt": {
      "type": "boolean"
    },
    "honor_gpc": {
      "type": "boolean"
    },
    "pii_scrubber": {
      "type": "boolean"
    },
    "redaction_rules": {
      "type": "array"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "path_masks": {
      "type": "array"
    },
    "retention_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "bot_filtering": {
      "type": "boolean"
    },
    "traffic_rule_modes": {
      "type": "object"
    },
    "vitals_sample_rate": {
      "type": "integer"
    },
    "conversion_denominator": {
      "type": "string"
    },
    "public_dashboard": {
      "type": "boolean"
    },
    "public_indexable": {
      "type": "boolean"
    },
    "ingest_key_prefix": {
      "anyOf": [
        {
          "type": "string",
          "description": "서버 수집 키의 앞부분"
        },
        {
          "type": "null"
        }
      ]
    },
    "verified_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "first_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "snippet": {
      "type": "string",
      "description": "HTML 추적 스니펫"
    },
    "favorite": {
      "type": "boolean",
      "description": "내가 별표 표시함"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:id.json 사이트 삭제 (7일 후 완전 삭제) sites_delete

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "confirm": {
      "type": "string",
      "description": "확인을 위해 도메인을 입력하세요"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "confirm",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "추적 스니펫에 사용되는 사이트 ID"
    },
    "workspace_id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "multi_domain_mode": {
      "type": "string"
    },
    "timezone": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "week_start": {
      "type": "integer"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "honor_dnt": {
      "type": "boolean"
    },
    "honor_gpc": {
      "type": "boolean"
    },
    "pii_scrubber": {
      "type": "boolean"
    },
    "redaction_rules": {
      "type": "array"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "path_masks": {
      "type": "array"
    },
    "retention_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "bot_filtering": {
      "type": "boolean"
    },
    "traffic_rule_modes": {
      "type": "object"
    },
    "vitals_sample_rate": {
      "type": "integer"
    },
    "conversion_denominator": {
      "type": "string"
    },
    "public_dashboard": {
      "type": "boolean"
    },
    "public_indexable": {
      "type": "boolean"
    },
    "ingest_key_prefix": {
      "anyOf": [
        {
          "type": "string",
          "description": "서버 수집 키의 앞부분"
        },
        {
          "type": "null"
        }
      ]
    },
    "verified_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "first_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "snippet": {
      "type": "string",
      "description": "HTML 추적 스니펫"
    },
    "favorite": {
      "type": "boolean",
      "description": "내가 별표 표시함"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/sites.json 워크스페이스의 사이트 목록 보기 sites_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/sites.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "query": {
      "type": "string",
      "description": "도메인 또는 이름으로 필터링"
    },
    "label": {
      "type": "string",
      "description": "이 라벨이 있는 사이트만"
    },
    "sort": {
      "type": "string",
      "description": "position (내가 정한 순서), name, 또는 최근 30일 방문자 (많은 순)",
      "enum": [
        "position",
        "name",
        "visitors"
      ],
      "default": "position"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "추적 스니펫에 사용되는 사이트 ID"
      },
      "workspace_id": {
        "type": "string"
      },
      "domain": {
        "type": "string"
      },
      "name": {
        "type": "string"
      },
      "extra_domains": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "multi_domain_mode": {
        "type": "string"
      },
      "timezone": {
        "type": "string"
      },
      "currency": {
        "type": "string"
      },
      "week_start": {
        "type": "integer"
      },
      "labels": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "honor_dnt": {
        "type": "boolean"
      },
      "honor_gpc": {
        "type": "boolean"
      },
      "pii_scrubber": {
        "type": "boolean"
      },
      "redaction_rules": {
        "type": "array"
      },
      "allowed_params": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "path_masks": {
        "type": "array"
      },
      "retention_months": {
        "anyOf": [
          {
            "type": "integer"
          },
          {
            "type": "null"
          }
        ]
      },
      "bot_filtering": {
        "type": "boolean"
      },
      "traffic_rule_modes": {
        "type": "object"
      },
      "vitals_sample_rate": {
        "type": "integer"
      },
      "conversion_denominator": {
        "type": "string"
      },
      "public_dashboard": {
        "type": "boolean"
      },
      "public_indexable": {
        "type": "boolean"
      },
      "ingest_key_prefix": {
        "anyOf": [
          {
            "type": "string",
            "description": "서버 수집 키의 앞부분"
          },
          {
            "type": "null"
          }
        ]
      },
      "verified_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "first_event_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_event_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "snippet": {
        "type": "string",
        "description": "HTML 추적 스니펫"
      },
      "favorite": {
        "type": "boolean",
        "description": "내가 별표 표시함"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /sites/:id.json 사이트와 모든 설정 조회 sites_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "추적 스니펫에 사용되는 사이트 ID"
    },
    "workspace_id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "multi_domain_mode": {
      "type": "string"
    },
    "timezone": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "week_start": {
      "type": "integer"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "honor_dnt": {
      "type": "boolean"
    },
    "honor_gpc": {
      "type": "boolean"
    },
    "pii_scrubber": {
      "type": "boolean"
    },
    "redaction_rules": {
      "type": "array"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "path_masks": {
      "type": "array"
    },
    "retention_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "bot_filtering": {
      "type": "boolean"
    },
    "traffic_rule_modes": {
      "type": "object"
    },
    "vitals_sample_rate": {
      "type": "integer"
    },
    "conversion_denominator": {
      "type": "string"
    },
    "public_dashboard": {
      "type": "boolean"
    },
    "public_indexable": {
      "type": "boolean"
    },
    "ingest_key_prefix": {
      "anyOf": [
        {
          "type": "string",
          "description": "서버 수집 키의 앞부분"
        },
        {
          "type": "null"
        }
      ]
    },
    "verified_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "first_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "snippet": {
      "type": "string",
      "description": "HTML 추적 스니펫"
    },
    "favorite": {
      "type": "boolean",
      "description": "내가 별표 표시함"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /sites/:id.json 사이트 설정 수정 sites_update

권한: sites.manage

예시
curl -X PATCH https://privatusanalytics.com/sites/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "표시 이름"
    },
    "domain": {
      "type": "string",
      "description": "기본 도메인"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "추가 호스트명"
    },
    "multi_domain_mode": {
      "type": "string",
      "description": "combined: 도메인 전반에서 방문자 하나로 집계",
      "enum": [
        "combined",
        "separate"
      ]
    },
    "timezone": {
      "type": "string",
      "description": "리포트 시간대"
    },
    "currency": {
      "type": "string",
      "description": "매출 통화 (ISO 4217)"
    },
    "week_start": {
      "type": "integer",
      "description": "0 = 일요일, 1 = 월요일"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "사이트를 묶는 라벨"
    },
    "honor_dnt": {
      "type": "boolean",
      "description": "DNT를 보내는 방문자 제외"
    },
    "honor_gpc": {
      "type": "boolean",
      "description": "GPC를 보내는 방문자 제외"
    },
    "pii_scrubber": {
      "type": "boolean",
      "description": "이메일, 토큰, ID 삭제"
    },
    "redaction_rules": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string"
          },
          "pattern": {
            "type": "string"
          }
        }
      },
      "description": "사용자 지정 삭제 정규식"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "경로에 유지할 쿼리 매개변수"
    },
    "path_masks": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "pattern": {
            "type": "string"
          },
          "replacement": {
            "type": "string"
          }
        }
      },
      "description": "경로 마스킹 규칙, 예: /u/* -> /u/:id"
    },
    "retention_months": {
      "type": "integer",
      "description": "이 기간보다 오래된 데이터 삭제"
    },
    "bot_filtering": {
      "type": "boolean",
      "description": "봇 트래픽 필터링"
    },
    "traffic_rule_modes": {
      "type": "object",
      "additionalProperties": true,
      "description": "트래픽 규칙 목록별 block 또는 allow"
    },
    "vitals_sample_rate": {
      "type": "integer",
      "description": "웹 바이탈 샘플링 %"
    },
    "conversion_denominator": {
      "type": "string",
      "description": "전환율을 방문 또는 방문자 기준으로 계산",
      "enum": [
        "visits",
        "visitors"
      ]
    },
    "public_dashboard": {
      "type": "boolean",
      "description": "링크가 있는 누구나 통계를 볼 수 있음"
    },
    "public_indexable": {
      "type": "boolean",
      "description": "검색 엔진이 공개 페이지를 색인하도록 허용"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "추적 스니펫에 사용되는 사이트 ID"
    },
    "workspace_id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "multi_domain_mode": {
      "type": "string"
    },
    "timezone": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "week_start": {
      "type": "integer"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "honor_dnt": {
      "type": "boolean"
    },
    "honor_gpc": {
      "type": "boolean"
    },
    "pii_scrubber": {
      "type": "boolean"
    },
    "redaction_rules": {
      "type": "array"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "path_masks": {
      "type": "array"
    },
    "retention_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "bot_filtering": {
      "type": "boolean"
    },
    "traffic_rule_modes": {
      "type": "object"
    },
    "vitals_sample_rate": {
      "type": "integer"
    },
    "conversion_denominator": {
      "type": "string"
    },
    "public_dashboard": {
      "type": "boolean"
    },
    "public_indexable": {
      "type": "boolean"
    },
    "ingest_key_prefix": {
      "anyOf": [
        {
          "type": "string",
          "description": "서버 수집 키의 앞부분"
        },
        {
          "type": "null"
        }
      ]
    },
    "verified_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "first_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "snippet": {
      "type": "string",
      "description": "HTML 추적 스니펫"
    },
    "favorite": {
      "type": "boolean",
      "description": "내가 별표 표시함"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

상태 페이지

GET /status/:slug/confirm/:token.json 이메일로 받은 링크에서 구독 확인 public_status_pages_confirm

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/status/:slug/confirm/:token.json
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    },
    "slug": {
      "type": "string",
      "description": "리소스의 Slug"
    }
  },
  "required": [
    "token",
    "slug"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /status/:slug.json 공개 상태 페이지: 현재 상태, 90일 가동 시간 막대, 인시던트, 게시물 public_status_pages_get

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/status/:slug.json
입력
{
  "type": "object",
  "properties": {
    "slug": {
      "type": "string",
      "description": "리소스의 Slug"
    }
  },
  "required": [
    "slug"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string"
    },
    "description": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "logo_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_color": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "status": {
      "type": "string",
      "description": "operational, degraded 또는 outage"
    },
    "checks": {
      "type": "array",
      "description": "각 항목: {name, status, uptime_90d, days: [{date, uptime, downtime_seconds}]}"
    },
    "posts": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "게시물 ID (spp_…)"
          },
          "title": {
            "type": "string"
          },
          "body": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "status": {
            "type": "string",
            "description": "investigating, identified, monitoring 또는 resolved"
          },
          "posted_at": {
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "type": "string",
            "format": "date-time"
          }
        }
      }
    },
    "incidents": {
      "type": "array",
      "description": "최근 인시던트: {check, started_at, resolved_at, duration_seconds}"
    }
  }
}
POST /status/:slug/subscribers.json 이메일 주소 구독 (이중 수신 동의) public_status_pages_subscribe

브라우저 클라이언트는 Cloudflare Turnstile 토큰을 `cf-turnstile-response`로 보냅니다. API 토큰을 쓰는 요청에는 필요하지 않습니다.

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/status/:slug/subscribers.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "description": "알림을 받을 이메일 주소",
      "examples": [
        "[email protected]"
      ]
    },
    "slug": {
      "type": "string",
      "description": "리소스의 Slug"
    }
  },
  "required": [
    "email",
    "slug"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /status/:slug/unsubscribe/:token.json 이메일로 받은 토큰으로 구독 해지 public_status_pages_unsubscribe

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/status/:slug/unsubscribe/:token.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    },
    "slug": {
      "type": "string",
      "description": "리소스의 Slug"
    }
  },
  "required": [
    "token",
    "slug"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /status_pages/:status_page_id/posts.json 인시던트 업데이트 게시 (구독자에게 이메일 발송) status_page_posts_create

권한: uptime.manage

예시
curl -X POST https://privatusanalytics.com/status_pages/:status_page_id/posts.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "제목, 예: \"오류율 증가\""
    },
    "body": {
      "type": "string",
      "description": "업데이트 텍스트 (일반 텍스트)"
    },
    "status": {
      "type": "string",
      "description": "investigating, identified, monitoring 또는 resolved",
      "enum": [
        "investigating",
        "identified",
        "monitoring",
        "resolved"
      ],
      "default": "investigating"
    },
    "posted_at": {
      "type": "string",
      "format": "date-time",
      "description": "발생 시각 (기본값은 지금)"
    },
    "notify": {
      "type": "boolean",
      "description": "확인된 구독자에게 이메일 발송",
      "default": true
    },
    "status_page_id": {
      "type": "string",
      "description": "리소스의 Status page"
    }
  },
  "required": [
    "title",
    "status_page_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "게시물 ID (spp_…)"
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "status": {
      "type": "string",
      "description": "investigating, identified, monitoring 또는 resolved"
    },
    "posted_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /status_pages/:status_page_id/posts/:id.json 상태 페이지 게시물 삭제 status_page_posts_delete

권한: uptime.manage

예시
curl -X DELETE https://privatusanalytics.com/status_pages/:status_page_id/posts/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "status_page_id": {
      "type": "string",
      "description": "리소스의 Status page"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "status_page_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "게시물 ID (spp_…)"
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "status": {
      "type": "string",
      "description": "investigating, identified, monitoring 또는 resolved"
    },
    "posted_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /status_pages/:status_page_id/posts.json 상태 페이지의 게시물 목록 보기 status_page_posts_list

권한: analytics.read

예시
curl https://privatusanalytics.com/status_pages/:status_page_id/posts.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "이 상태의 게시물만",
      "enum": [
        "investigating",
        "identified",
        "monitoring",
        "resolved"
      ]
    },
    "status_page_id": {
      "type": "string",
      "description": "리소스의 Status page"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "status_page_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "게시물 ID (spp_…)"
      },
      "title": {
        "type": "string"
      },
      "body": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "status": {
        "type": "string",
        "description": "investigating, identified, monitoring 또는 resolved"
      },
      "posted_at": {
        "type": "string",
        "format": "date-time"
      },
      "updated_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
PATCH /status_pages/:status_page_id/posts/:id.json 상태 페이지 게시물 편집 status_page_posts_update

권한: uptime.manage

예시
curl -X PATCH https://privatusanalytics.com/status_pages/:status_page_id/posts/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "description": "제목"
    },
    "body": {
      "type": "string",
      "description": "업데이트 텍스트 (일반 텍스트)"
    },
    "status": {
      "type": "string",
      "description": "investigating, identified, monitoring 또는 resolved",
      "enum": [
        "investigating",
        "identified",
        "monitoring",
        "resolved"
      ]
    },
    "notify": {
      "type": "boolean",
      "description": "상태가 바뀌면 확인된 구독자에게 이메일 발송",
      "default": true
    },
    "status_page_id": {
      "type": "string",
      "description": "리소스의 Status page"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "status_page_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "게시물 ID (spp_…)"
    },
    "title": {
      "type": "string"
    },
    "body": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "status": {
      "type": "string",
      "description": "investigating, identified, monitoring 또는 resolved"
    },
    "posted_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /status_pages/:status_page_id/subscribers/:id.json 구독자 제거 status_page_subscribers_delete

권한: uptime.manage

예시
curl -X DELETE https://privatusanalytics.com/status_pages/:status_page_id/subscribers/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "status_page_id": {
      "type": "string",
      "description": "리소스의 Status page"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "status_page_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "email": {
      "type": "string"
    },
    "confirmed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /status_pages/:status_page_id/subscribers.json 상태 페이지의 구독자 목록 보기 status_page_subscribers_list

권한: uptime.manage

예시
curl https://privatusanalytics.com/status_pages/:status_page_id/subscribers.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "confirmed": {
      "type": "boolean",
      "description": "true: 확인된 구독자만, false: 대기 중인 구독자만"
    },
    "status_page_id": {
      "type": "string",
      "description": "리소스의 Status page"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "status_page_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid"
      },
      "email": {
        "type": "string"
      },
      "confirmed_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /workspaces/:workspace_id/status_pages.json 상태 페이지 만들기 status_pages_create

권한: uptime.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/status_pages.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "페이지 제목, 예: \"Acme 상태\""
    },
    "slug": {
      "type": "string",
      "description": "공개 URL 슬러그: /status/<slug> (기본값은 이름에서 생성)"
    },
    "description": {
      "type": "string",
      "description": "제목 아래의 소개 문구"
    },
    "logo_url": {
      "type": "string",
      "description": "로고 이미지의 HTTPS URL"
    },
    "brand_color": {
      "type": "string",
      "description": "강조 색상, 예: #06755b"
    },
    "custom_domain": {
      "type": "string",
      "description": "사용자 지정 도메인 (우리 호스트로 CNAME), 예: status.example.com. 비우면 제거"
    },
    "check_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "표시할 가동 시간 검사 ID (upc_…)"
    },
    "published": {
      "type": "boolean",
      "description": "공개 여부",
      "default": true
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "상태 페이지 ID (sp_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "slug": {
      "type": "string",
      "description": "공개 URL: /status/<slug>"
    },
    "custom_domain": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "description": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "logo_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_color": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "published": {
      "type": "boolean"
    },
    "check_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "표시되는 가동 시간 검사 ID"
    },
    "subscribers": {
      "type": "integer",
      "description": "확인된 구독자"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /status_pages/:id.json 상태 페이지 삭제 status_pages_delete

권한: uptime.manage

예시
curl -X DELETE https://privatusanalytics.com/status_pages/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "상태 페이지 ID (sp_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "slug": {
      "type": "string",
      "description": "공개 URL: /status/<slug>"
    },
    "custom_domain": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "description": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "logo_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_color": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "published": {
      "type": "boolean"
    },
    "check_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "표시되는 가동 시간 검사 ID"
    },
    "subscribers": {
      "type": "integer",
      "description": "확인된 구독자"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/status_pages.json 상태 페이지 목록 보기 status_pages_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/status_pages.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "query": {
      "type": "string",
      "description": "이름 또는 슬러그로 필터링"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "상태 페이지 ID (sp_…)"
      },
      "workspace_id": {
        "type": "string"
      },
      "name": {
        "type": "string"
      },
      "slug": {
        "type": "string",
        "description": "공개 URL: /status/<slug>"
      },
      "custom_domain": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "description": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "logo_url": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "brand_color": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "published": {
        "type": "boolean"
      },
      "check_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "표시되는 가동 시간 검사 ID"
      },
      "subscribers": {
        "type": "integer",
        "description": "확인된 구독자"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /status_pages/:id.json 상태 페이지 조회 status_pages_get

권한: analytics.read

예시
curl https://privatusanalytics.com/status_pages/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "상태 페이지 ID (sp_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "slug": {
      "type": "string",
      "description": "공개 URL: /status/<slug>"
    },
    "custom_domain": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "description": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "logo_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_color": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "published": {
      "type": "boolean"
    },
    "check_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "표시되는 가동 시간 검사 ID"
    },
    "subscribers": {
      "type": "integer",
      "description": "확인된 구독자"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /status_pages/:id.json 상태 페이지 변경 status_pages_update

권한: uptime.manage

예시
curl -X PATCH https://privatusanalytics.com/status_pages/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "페이지 제목, 예: \"Acme 상태\""
    },
    "slug": {
      "type": "string",
      "description": "공개 URL 슬러그: /status/<slug> (기본값은 이름에서 생성)"
    },
    "description": {
      "type": "string",
      "description": "제목 아래의 소개 문구"
    },
    "logo_url": {
      "type": "string",
      "description": "로고 이미지의 HTTPS URL"
    },
    "brand_color": {
      "type": "string",
      "description": "강조 색상, 예: #06755b"
    },
    "custom_domain": {
      "type": "string",
      "description": "사용자 지정 도메인 (우리 호스트로 CNAME), 예: status.example.com. 비우면 제거"
    },
    "check_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "표시할 가동 시간 검사 ID (upc_…)"
    },
    "published": {
      "type": "boolean",
      "description": "공개 여부"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "상태 페이지 ID (sp_…)"
    },
    "workspace_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "slug": {
      "type": "string",
      "description": "공개 URL: /status/<slug>"
    },
    "custom_domain": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "description": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "logo_url": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_color": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "published": {
      "type": "boolean"
    },
    "check_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "표시되는 가동 시간 검사 ID"
    },
    "subscribers": {
      "type": "integer",
      "description": "확인된 구독자"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

성능

GET /sites/:site_id/performance.json 웹 바이탈: p75 점수표, 일별 추세, 페이지, 기기, 브라우저, 국가별 세부 분석 performance_report

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/performance.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "metric": {
      "type": "string",
      "description": "추세와 세부 분석에 사용할 지표",
      "enum": [
        "LCP",
        "INP",
        "CLS",
        "FCP",
        "TTFB"
      ],
      "default": "LCP"
    },
    "limit": {
      "type": "integer",
      "description": "세부 분석당 행 수 (최대 100)",
      "default": 10
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}

세그먼트

POST /sites/:site_id/segments.json 필터를 세그먼트로 저장 segments_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/segments.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "세그먼트 이름, 예: \"광고에서 온 모바일 방문자\"",
      "examples": [
        "Mobile visitors from ads"
      ]
    },
    "description": {
      "type": "string",
      "description": "세그먼트의 용도에 대한 선택 메모 (최대 300자)",
      "examples": [
        "People who might buy the Pro plan"
      ]
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터, 모두 일치해야 합니다. 각 항목은 조건 [\"dimension\", \"operator\", \"value\"]이거나, 여러 조건 중 하나만 일치하면 될 때는 {\"any\": [conditions]}입니다. 차원: page, entry_page, exit_page, hostname, channel, referrer, referrer_url, ref, utm_source, utm_medium, utm_campaign, utm_content, utm_term, country (ISO 코드, 예: US), language, device (desktop, mobile, tablet, tv, other), browser, browser_version, os, os_version, screen, goal (목표 ID), event (사용자 지정 이벤트 이름), prop:<key> (사용자 지정 이벤트 속성). 연산자: is, is_not, contains, not_contains, starts_with, regex, not_regex, any_of와 none_of (값은 목록), gt와 lt (숫자), between (숫자 두 개의 목록). 세그먼트 양식의 행도 받습니다: {\"dimension\", \"operator\", \"value\", \"property\" (차원이 prop일 때), \"join\": \"and\" 또는 \"or\" (or는 해당 행을 바로 앞 행과 묶음)}. 예: [[\"country\", \"is\", \"US\"], [\"device\", \"is\", \"mobile\"], {\"any\": [[\"page\", \"starts_with\", \"/pricing\"], [\"goal\", \"is\", \"goal_7Q2K9XH3AB\"]]}]",
      "examples": [
        [
          [
            "country",
            "is",
            "US"
          ],
          [
            "device",
            "is",
            "mobile"
          ],
          {
            "any": [
              [
                "page",
                "starts_with",
                "/pricing"
              ],
              [
                "goal",
                "is",
                "goal_7Q2K9XH3AB"
              ]
            ]
          }
        ]
      ]
    },
    "shared": {
      "type": "boolean",
      "description": "사이트에 접근할 수 있는 모든 사용자에게 표시 (false: 본인만)",
      "default": true
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "filters",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "세그먼트 ID, 예: seg_7Q2K9XH3AB"
    },
    "site_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "description": {
      "anyOf": [
        {
          "type": "string",
          "description": "세그먼트의 용도, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "filters": {
      "type": "array",
      "description": "통계 필터 형식의 필터: 모두 일치해야 하는 조건 [\"dimension\", \"operator\", \"value\"]와 {\"any\": [conditions]} 그룹"
    },
    "summary": {
      "type": "string",
      "description": "일상 언어로 된 필터, 예: \"미국에서 모바일로 접속해 /pricing을 본 방문자\""
    },
    "shared": {
      "type": "boolean",
      "description": "사이트에 접근할 수 있는 모든 사용자에게 표시"
    },
    "mine": {
      "type": "boolean",
      "description": "내가 만듦"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/segments/:id.json 세그먼트 삭제 segments_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/segments/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "세그먼트 ID, 예: seg_7Q2K9XH3AB"
    },
    "site_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "description": {
      "anyOf": [
        {
          "type": "string",
          "description": "세그먼트의 용도, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "filters": {
      "type": "array",
      "description": "통계 필터 형식의 필터: 모두 일치해야 하는 조건 [\"dimension\", \"operator\", \"value\"]와 {\"any\": [conditions]} 그룹"
    },
    "summary": {
      "type": "string",
      "description": "일상 언어로 된 필터, 예: \"미국에서 모바일로 접속해 /pricing을 본 방문자\""
    },
    "shared": {
      "type": "boolean",
      "description": "사이트에 접근할 수 있는 모든 사용자에게 표시"
    },
    "mine": {
      "type": "boolean",
      "description": "내가 만듦"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/segments.json 사이트에서 사용할 수 있는 세그먼트 목록 보기 segments_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/segments.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "세그먼트 ID, 예: seg_7Q2K9XH3AB"
      },
      "site_id": {
        "type": "string"
      },
      "name": {
        "type": "string"
      },
      "description": {
        "anyOf": [
          {
            "type": "string",
            "description": "세그먼트의 용도, 또는 null"
          },
          {
            "type": "null"
          }
        ]
      },
      "filters": {
        "type": "array",
        "description": "통계 필터 형식의 필터: 모두 일치해야 하는 조건 [\"dimension\", \"operator\", \"value\"]와 {\"any\": [conditions]} 그룹"
      },
      "summary": {
        "type": "string",
        "description": "일상 언어로 된 필터, 예: \"미국에서 모바일로 접속해 /pricing을 본 방문자\""
      },
      "shared": {
        "type": "boolean",
        "description": "사이트에 접근할 수 있는 모든 사용자에게 표시"
      },
      "mine": {
        "type": "boolean",
        "description": "내가 만듦"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      },
      "updated_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /sites/:site_id/segments/preview.json 필터를 일상 언어로 설명하고 최근 30일 동안 일치한 방문자 수 세기 segments_preview

권한: analytics.read

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/segments/preview.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터, 모두 일치해야 합니다. 각 항목은 조건 [\"dimension\", \"operator\", \"value\"]이거나, 여러 조건 중 하나만 일치하면 될 때는 {\"any\": [conditions]}입니다. 차원: page, entry_page, exit_page, hostname, channel, referrer, referrer_url, ref, utm_source, utm_medium, utm_campaign, utm_content, utm_term, country (ISO 코드, 예: US), language, device (desktop, mobile, tablet, tv, other), browser, browser_version, os, os_version, screen, goal (목표 ID), event (사용자 지정 이벤트 이름), prop:<key> (사용자 지정 이벤트 속성). 연산자: is, is_not, contains, not_contains, starts_with, regex, not_regex, any_of와 none_of (값은 목록), gt와 lt (숫자), between (숫자 두 개의 목록). 세그먼트 양식의 행도 받습니다: {\"dimension\", \"operator\", \"value\", \"property\" (차원이 prop일 때), \"join\": \"and\" 또는 \"or\" (or는 해당 행을 바로 앞 행과 묶음)}. 예: [[\"country\", \"is\", \"US\"], [\"device\", \"is\", \"mobile\"], {\"any\": [[\"page\", \"starts_with\", \"/pricing\"], [\"goal\", \"is\", \"goal_7Q2K9XH3AB\"]]}]",
      "examples": [
        [
          [
            "country",
            "is",
            "US"
          ],
          [
            "device",
            "is",
            "mobile"
          ],
          {
            "any": [
              [
                "page",
                "starts_with",
                "/pricing"
              ],
              [
                "goal",
                "is",
                "goal_7Q2K9XH3AB"
              ]
            ]
          }
        ]
      ],
      "default": []
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/segments/:id.json 세그먼트 조회 segments_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/segments/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "세그먼트 ID, 예: seg_7Q2K9XH3AB"
    },
    "site_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "description": {
      "anyOf": [
        {
          "type": "string",
          "description": "세그먼트의 용도, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "filters": {
      "type": "array",
      "description": "통계 필터 형식의 필터: 모두 일치해야 하는 조건 [\"dimension\", \"operator\", \"value\"]와 {\"any\": [conditions]} 그룹"
    },
    "summary": {
      "type": "string",
      "description": "일상 언어로 된 필터, 예: \"미국에서 모바일로 접속해 /pricing을 본 방문자\""
    },
    "shared": {
      "type": "boolean",
      "description": "사이트에 접근할 수 있는 모든 사용자에게 표시"
    },
    "mine": {
      "type": "boolean",
      "description": "내가 만듦"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /sites/:site_id/segments/:id.json 세그먼트 이름, 필터 또는 공유 설정 변경 segments_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/segments/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "세그먼트 이름"
    },
    "description": {
      "type": "string",
      "description": "세그먼트의 용도에 대한 선택 메모 (최대 300자, 비우면 지워짐)"
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "교체할 필터, 만들 때와 같은 형식입니다. 필터, 모두 일치해야 합니다. 각 항목은 조건 [\"dimension\", \"operator\", \"value\"]이거나, 여러 조건 중 하나만 일치하면 될 때는 {\"any\": [conditions]}입니다. 차원: page, entry_page, exit_page, hostname, channel, referrer, referrer_url, ref, utm_source, utm_medium, utm_campaign, utm_content, utm_term, country (ISO 코드, 예: US), language, device (desktop, mobile, tablet, tv, other), browser, browser_version, os, os_version, screen, goal (목표 ID), event (사용자 지정 이벤트 이름), prop:<key> (사용자 지정 이벤트 속성). 연산자: is, is_not, contains, not_contains, starts_with, regex, not_regex, any_of와 none_of (값은 목록), gt와 lt (숫자), between (숫자 두 개의 목록). 세그먼트 양식의 행도 받습니다: {\"dimension\", \"operator\", \"value\", \"property\" (차원이 prop일 때), \"join\": \"and\" 또는 \"or\" (or는 해당 행을 바로 앞 행과 묶음)}. 예: [[\"country\", \"is\", \"US\"], [\"device\", \"is\", \"mobile\"], {\"any\": [[\"page\", \"starts_with\", \"/pricing\"], [\"goal\", \"is\", \"goal_7Q2K9XH3AB\"]]}]",
      "examples": [
        [
          [
            "country",
            "is",
            "US"
          ],
          [
            "device",
            "is",
            "mobile"
          ],
          {
            "any": [
              [
                "page",
                "starts_with",
                "/pricing"
              ],
              [
                "goal",
                "is",
                "goal_7Q2K9XH3AB"
              ]
            ]
          }
        ]
      ]
    },
    "shared": {
      "type": "boolean",
      "description": "사이트의 모든 사용자에게 표시"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "세그먼트 ID, 예: seg_7Q2K9XH3AB"
    },
    "site_id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "description": {
      "anyOf": [
        {
          "type": "string",
          "description": "세그먼트의 용도, 또는 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "filters": {
      "type": "array",
      "description": "통계 필터 형식의 필터: 모두 일치해야 하는 조건 [\"dimension\", \"operator\", \"value\"]와 {\"any\": [conditions]} 그룹"
    },
    "summary": {
      "type": "string",
      "description": "일상 언어로 된 필터, 예: \"미국에서 모바일로 접속해 /pricing을 본 방문자\""
    },
    "shared": {
      "type": "boolean",
      "description": "사이트에 접근할 수 있는 모든 사용자에게 표시"
    },
    "mine": {
      "type": "boolean",
      "description": "내가 만듦"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

수집

POST /api/logs.json AI 크롤러 리포트용 서버 액세스 로그 보내기 (JSON {lines: [...]} 또는 combined 로그 텍스트, 사이트 수집 키를 Bearer 토큰으로 사용) crawler_logs_create

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/api/logs.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "lines": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "ts": {
            "type": "string"
          },
          "path": {
            "type": "string",
            "default": "/"
          },
          "status": {
            "type": "integer"
          },
          "user_agent": {
            "type": "string",
            "default": ""
          }
        }
      },
      "description": "로그 줄: [{ts, path, status, user_agent}] (최대 1000)"
    }
  },
  "required": [
    "lines"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /api/event.json 브라우저 히트 수집 (/js/pa.js에서 사용) ingest_event

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/api/event.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site": {
      "type": "string",
      "description": "사이트 ID (pa_…)"
    },
    "type": {
      "type": "string",
      "description": "히트 유형",
      "enum": [
        "pageview",
        "event",
        "engagement",
        "vital",
        "click"
      ]
    },
    "url": {
      "type": "string",
      "description": "전체 페이지 URL"
    },
    "referrer": {
      "type": "string",
      "description": "document.referrer"
    },
    "name": {
      "type": "string",
      "description": "이벤트 이름 (type=event) 또는 바이탈 이름"
    },
    "props": {
      "type": "object",
      "additionalProperties": true,
      "description": "이벤트 속성: 문자열/숫자/불리언 값 최대 30개",
      "default": {}
    },
    "screen_width": {
      "type": "integer",
      "description": "화면 너비 (픽셀)"
    },
    "language": {
      "type": "string",
      "description": "navigator.language"
    },
    "engaged_ms": {
      "type": "integer",
      "description": "페이지에서 보인 시간 (참여도)"
    },
    "scroll_depth": {
      "type": "integer",
      "description": "최대 스크롤 깊이 % (참여도)"
    },
    "value": {
      "type": "number",
      "description": "웹 바이탈 값 (type=vital)"
    },
    "selector": {
      "type": "string",
      "description": "클릭한 요소의 셀렉터 (type=click)"
    },
    "hash_mode": {
      "type": "boolean",
      "description": "#프래그먼트 유지 (해시 라우팅 사이트)",
      "default": false
    },
    "dnt": {
      "type": "boolean",
      "description": "Do Not Track이 켜져 있음",
      "default": false
    },
    "gpc": {
      "type": "boolean",
      "description": "Global Privacy Control이 켜져 있음",
      "default": false
    },
    "revenue": {
      "type": "number",
      "description": "기본 통화 단위의 매출, 예: 49.99"
    },
    "currency": {
      "type": "string",
      "description": "매출의 ISO 4217 통화"
    }
  },
  "required": [
    "site",
    "type",
    "url"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /api/events.json 사이트 수집 키로 서버 측 이벤트 수집 ingest_events

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/api/events.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "events": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true
      },
      "description": "이벤트 최대 100개"
    }
  },
  "required": [
    "events"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /api/pixel.json JavaScript 없이 페이지뷰 수집 (1×1 GIF) ingest_pixel

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/api/pixel.json
입력
{
  "type": "object",
  "properties": {},
  "required": []
}
응답 데이터
{
  "type": "object"
}

실시간

GET /sites/:site_id/live.json 실시간 방문자, 활동 스트림, 지금 인기 있는 항목 (최근 30분) live_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/live.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "feed": {
      "type": "string",
      "description": "활동 스트림: 모든 히트, 페이지뷰 또는 사용자 지정 이벤트",
      "enum": [
        "all",
        "pageviews",
        "events"
      ],
      "default": "all"
    },
    "limit": {
      "type": "integer",
      "description": "활동 스트림 항목 수 (최대 100)",
      "default": 50
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/live/wallboard.json 사이트 하나 이상의 월보드 카드 (실시간 및 오늘) live_wallboard

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/live/wallboard.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "순환할 사이트 ID (기본값은 이 사이트)",
      "default": []
    },
    "rotate_seconds": {
      "type": "integer",
      "description": "각 사이트가 화면에 머무는 시간 (초, 5-300)",
      "default": 20
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /wallboard/:token.json 월보드 토큰으로 보는 월보드 (로그인 불필요) live_public_wallboard

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl https://privatusanalytics.com/wallboard/:token.json
입력
{
  "type": "object",
  "properties": {
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "순환할 사이트 ID (기본값은 이 사이트)",
      "default": []
    },
    "rotate_seconds": {
      "type": "integer",
      "description": "각 사이트가 화면에 머무는 시간 (초, 5-300)",
      "default": 20
    },
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object"
}

알림

POST /alerts/:id/acknowledge.json 최신 인시던트 확인 처리 alerts_acknowledge

권한: analytics.read

예시
curl -X POST https://privatusanalytics.com/alerts/:id/acknowledge.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "알림 ID, 예: alr_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID (사용량 알림은 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
    },
    "metric": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "operator": {
      "anyOf": [
        {
          "type": "string",
          "description": "gt, gte, lt 또는 lte"
        },
        {
          "type": "null"
        }
      ]
    },
    "threshold": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "window_minutes": {
      "type": "integer"
    },
    "sensitivity": {
      "type": "string",
      "description": "이상 감지 민감도"
    },
    "goal_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID"
    },
    "state": {
      "type": "string",
      "description": "ok 또는 triggered"
    },
    "enabled": {
      "type": "boolean"
    },
    "muted_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_triggered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_evaluated_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /workspaces/:workspace_id/alerts.json 알림 만들기 alerts_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/alerts.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID (pa_…). 사용량 알림을 제외하고 필수"
    },
    "metric": {
      "type": "string",
      "description": "threshold/anomaly: visitors, visits, pageviews, bounce_rate 또는 conversion. vitals: lcp, inp, cls, fcp 또는 ttfb"
    },
    "operator": {
      "type": "string",
      "description": "비교 (gt, gte, lt, lte). anomaly: lt는 감소만, gt는 급증만, 비우면 둘 다",
      "enum": [
        "gt",
        "gte",
        "lt",
        "lte"
      ]
    },
    "threshold": {
      "type": "number",
      "description": "threshold: 지표 값, goal: 완료 수, no_data: 시간, usage: 퍼센트, ssl: 일, vitals: ms (CLS: 점수)"
    },
    "window_minutes": {
      "type": "integer",
      "description": "평가 구간 (분, 5에서 10080)"
    },
    "sensitivity": {
      "type": "string",
      "description": "anomaly: low, medium 또는 high",
      "enum": [
        "low",
        "medium",
        "high"
      ]
    },
    "goal_id": {
      "type": "string",
      "description": "goal 및 conversion 알림: 목표 ID (goal_…)"
    },
    "uptime_check_id": {
      "type": "string",
      "description": "uptime/ssl: 검사 ID (기본값: 사이트의 모든 검사)"
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID (nch_…)"
    },
    "enabled": {
      "type": "boolean",
      "description": "이 알림 평가"
    },
    "name": {
      "type": "string",
      "description": "알림 이름",
      "examples": [
        "Traffic dropped"
      ]
    },
    "kind": {
      "type": "string",
      "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals",
      "enum": [
        "threshold",
        "anomaly",
        "goal",
        "no_data",
        "usage",
        "uptime",
        "ssl",
        "vitals"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "kind",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "알림 ID, 예: alr_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID (사용량 알림은 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
    },
    "metric": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "operator": {
      "anyOf": [
        {
          "type": "string",
          "description": "gt, gte, lt 또는 lte"
        },
        {
          "type": "null"
        }
      ]
    },
    "threshold": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "window_minutes": {
      "type": "integer"
    },
    "sensitivity": {
      "type": "string",
      "description": "이상 감지 민감도"
    },
    "goal_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID"
    },
    "state": {
      "type": "string",
      "description": "ok 또는 triggered"
    },
    "enabled": {
      "type": "boolean"
    },
    "muted_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_triggered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_evaluated_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /alerts/:id.json 알림 삭제 alerts_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/alerts/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "알림 ID, 예: alr_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID (사용량 알림은 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
    },
    "metric": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "operator": {
      "anyOf": [
        {
          "type": "string",
          "description": "gt, gte, lt 또는 lte"
        },
        {
          "type": "null"
        }
      ]
    },
    "threshold": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "window_minutes": {
      "type": "integer"
    },
    "sensitivity": {
      "type": "string",
      "description": "이상 감지 민감도"
    },
    "goal_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID"
    },
    "state": {
      "type": "string",
      "description": "ok 또는 triggered"
    },
    "enabled": {
      "type": "boolean"
    },
    "muted_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_triggered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_evaluated_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /alerts/:id/history.json 알림의 인시던트 기록 alerts_history

권한: analytics.read

예시
curl https://privatusanalytics.com/alerts/:id/history.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "open": {
      "type": "boolean",
      "description": "해결되지 않은 인시던트만",
      "default": false
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "triggered_at": {
        "type": "string",
        "format": "date-time"
      },
      "resolved_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "value": {
        "anyOf": [
          {
            "type": "number",
            "description": "트리거 시점에 측정된 값"
          },
          {
            "type": "null"
          }
        ]
      },
      "message": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "acknowledged_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "acknowledged_by": {
        "anyOf": [
          {
            "type": "string",
            "description": "확인 처리한 멤버 이름"
          },
          {
            "type": "null"
          }
        ]
      }
    }
  }
}
GET /workspaces/:workspace_id/alerts.json 알림 목록 보기 alerts_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/alerts.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "이 사이트의 알림만 (pa_…)"
    },
    "state": {
      "type": "string",
      "description": "ok 또는 triggered 상태의 알림만",
      "enum": [
        "ok",
        "triggered"
      ]
    },
    "kind": {
      "type": "string",
      "description": "이 종류만",
      "enum": [
        "threshold",
        "anomaly",
        "goal",
        "no_data",
        "usage",
        "uptime",
        "ssl",
        "vitals"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "알림 ID, 예: alr_7Q2K9XH3AB"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "사이트 ID (사용량 알림은 null)"
          },
          {
            "type": "null"
          }
        ]
      },
      "name": {
        "type": "string"
      },
      "kind": {
        "type": "string",
        "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
      },
      "metric": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "operator": {
        "anyOf": [
          {
            "type": "string",
            "description": "gt, gte, lt 또는 lte"
          },
          {
            "type": "null"
          }
        ]
      },
      "threshold": {
        "anyOf": [
          {
            "type": "number"
          },
          {
            "type": "null"
          }
        ]
      },
      "window_minutes": {
        "type": "integer"
      },
      "sensitivity": {
        "type": "string",
        "description": "이상 감지 민감도"
      },
      "goal_id": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "channel_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "알림 채널 ID"
      },
      "state": {
        "type": "string",
        "description": "ok 또는 triggered"
      },
      "enabled": {
        "type": "boolean"
      },
      "muted_until": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_triggered_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_evaluated_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /alerts/:id/mute.json 알림의 통지 음소거 (또는 해제) alerts_mute

권한: content.write

예시
curl -X POST https://privatusanalytics.com/alerts/:id/mute.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "minutes": {
      "type": "integer",
      "description": "이 시간(분) 동안 음소거 (0이면 해제, 최대 30일)",
      "default": 60
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "알림 ID, 예: alr_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID (사용량 알림은 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
    },
    "metric": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "operator": {
      "anyOf": [
        {
          "type": "string",
          "description": "gt, gte, lt 또는 lte"
        },
        {
          "type": "null"
        }
      ]
    },
    "threshold": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "window_minutes": {
      "type": "integer"
    },
    "sensitivity": {
      "type": "string",
      "description": "이상 감지 민감도"
    },
    "goal_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID"
    },
    "state": {
      "type": "string",
      "description": "ok 또는 triggered"
    },
    "enabled": {
      "type": "boolean"
    },
    "muted_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_triggered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_evaluated_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /alerts/:id.json 알림 조회 alerts_get

권한: analytics.read

예시
curl https://privatusanalytics.com/alerts/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "알림 ID, 예: alr_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID (사용량 알림은 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
    },
    "metric": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "operator": {
      "anyOf": [
        {
          "type": "string",
          "description": "gt, gte, lt 또는 lte"
        },
        {
          "type": "null"
        }
      ]
    },
    "threshold": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "window_minutes": {
      "type": "integer"
    },
    "sensitivity": {
      "type": "string",
      "description": "이상 감지 민감도"
    },
    "goal_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID"
    },
    "state": {
      "type": "string",
      "description": "ok 또는 triggered"
    },
    "enabled": {
      "type": "boolean"
    },
    "muted_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_triggered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_evaluated_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /alerts/:id.json 알림 수정 alerts_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/alerts/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID (pa_…). 사용량 알림을 제외하고 필수"
    },
    "metric": {
      "type": "string",
      "description": "threshold/anomaly: visitors, visits, pageviews, bounce_rate 또는 conversion. vitals: lcp, inp, cls, fcp 또는 ttfb"
    },
    "operator": {
      "type": "string",
      "description": "비교 (gt, gte, lt, lte). anomaly: lt는 감소만, gt는 급증만, 비우면 둘 다",
      "enum": [
        "gt",
        "gte",
        "lt",
        "lte"
      ]
    },
    "threshold": {
      "type": "number",
      "description": "threshold: 지표 값, goal: 완료 수, no_data: 시간, usage: 퍼센트, ssl: 일, vitals: ms (CLS: 점수)"
    },
    "window_minutes": {
      "type": "integer",
      "description": "평가 구간 (분, 5에서 10080)"
    },
    "sensitivity": {
      "type": "string",
      "description": "anomaly: low, medium 또는 high",
      "enum": [
        "low",
        "medium",
        "high"
      ]
    },
    "goal_id": {
      "type": "string",
      "description": "goal 및 conversion 알림: 목표 ID (goal_…)"
    },
    "uptime_check_id": {
      "type": "string",
      "description": "uptime/ssl: 검사 ID (기본값: 사이트의 모든 검사)"
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID (nch_…)"
    },
    "enabled": {
      "type": "boolean",
      "description": "이 알림 평가"
    },
    "name": {
      "type": "string",
      "description": "알림 이름"
    },
    "kind": {
      "type": "string",
      "description": "알림 종류",
      "enum": [
        "threshold",
        "anomaly",
        "goal",
        "no_data",
        "usage",
        "uptime",
        "ssl",
        "vitals"
      ]
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "알림 ID, 예: alr_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID (사용량 알림은 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "name": {
      "type": "string"
    },
    "kind": {
      "type": "string",
      "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
    },
    "metric": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "operator": {
      "anyOf": [
        {
          "type": "string",
          "description": "gt, gte, lt 또는 lte"
        },
        {
          "type": "null"
        }
      ]
    },
    "threshold": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ]
    },
    "window_minutes": {
      "type": "integer"
    },
    "sensitivity": {
      "type": "string",
      "description": "이상 감지 민감도"
    },
    "goal_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "channel_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "알림 채널 ID"
    },
    "state": {
      "type": "string",
      "description": "ok 또는 triggered"
    },
    "enabled": {
      "type": "boolean"
    },
    "muted_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_triggered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_evaluated_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/alerts.json 사이트의 알림 목록 보기 site_alerts_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/alerts.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "state": {
      "type": "string",
      "description": "ok 또는 triggered 상태의 알림만",
      "enum": [
        "ok",
        "triggered"
      ]
    },
    "kind": {
      "type": "string",
      "description": "이 종류만",
      "enum": [
        "threshold",
        "anomaly",
        "goal",
        "no_data",
        "usage",
        "uptime",
        "ssl",
        "vitals"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "알림 ID, 예: alr_7Q2K9XH3AB"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "사이트 ID (사용량 알림은 null)"
          },
          {
            "type": "null"
          }
        ]
      },
      "name": {
        "type": "string"
      },
      "kind": {
        "type": "string",
        "description": "threshold, anomaly, goal, no_data, usage, uptime, ssl 또는 vitals"
      },
      "metric": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "operator": {
        "anyOf": [
          {
            "type": "string",
            "description": "gt, gte, lt 또는 lte"
          },
          {
            "type": "null"
          }
        ]
      },
      "threshold": {
        "anyOf": [
          {
            "type": "number"
          },
          {
            "type": "null"
          }
        ]
      },
      "window_minutes": {
        "type": "integer"
      },
      "sensitivity": {
        "type": "string",
        "description": "이상 감지 민감도"
      },
      "goal_id": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "channel_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "알림 채널 ID"
      },
      "state": {
        "type": "string",
        "description": "ok 또는 triggered"
      },
      "enabled": {
        "type": "boolean"
      },
      "muted_until": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_triggered_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_evaluated_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}

알림 채널

POST /workspaces/:workspace_id/channels.json 알림 채널 추가 notification_channels_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/channels.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "웹훅 URL (slack, teams, discord, webhook), HTTPS"
    },
    "secret": {
      "type": "string",
      "description": "webhook: X-Privatus-Signature용 HMAC 시크릿"
    },
    "emails": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "email: 수신자 주소 (최대 20개)"
    },
    "routing_key": {
      "type": "string",
      "description": "pagerduty: Events API v2 통합 키"
    },
    "api_key": {
      "type": "string",
      "description": "opsgenie: API 통합 키"
    },
    "region": {
      "type": "string",
      "description": "opsgenie: 계정 리전",
      "enum": [
        "us",
        "eu"
      ]
    },
    "kind": {
      "type": "string",
      "description": "email, slack, teams, discord, webhook, pagerduty, opsgenie 또는 push",
      "enum": [
        "email",
        "slack",
        "teams",
        "discord",
        "webhook",
        "pagerduty",
        "opsgenie",
        "push"
      ]
    },
    "name": {
      "type": "string",
      "description": "표시 이름",
      "examples": [
        "#alerts"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "kind",
    "name",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "채널 ID, 예: nch_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "email, slack, teams, discord, webhook, pagerduty, opsgenie 또는 push"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "마스킹된 대상"
    },
    "last_used_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /channels/:id.json 알림 채널 삭제 notification_channels_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/channels/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "채널 ID, 예: nch_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "email, slack, teams, discord, webhook, pagerduty, opsgenie 또는 push"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "마스킹된 대상"
    },
    "last_used_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/channels.json 알림 채널 목록 보기 notification_channels_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/channels.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "kind": {
      "type": "string",
      "description": "이 종류의 채널만",
      "enum": [
        "email",
        "slack",
        "teams",
        "discord",
        "webhook",
        "pagerduty",
        "opsgenie",
        "push"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "채널 ID, 예: nch_7Q2K9XH3AB"
      },
      "kind": {
        "type": "string",
        "description": "email, slack, teams, discord, webhook, pagerduty, opsgenie 또는 push"
      },
      "name": {
        "type": "string"
      },
      "target": {
        "type": "string",
        "description": "마스킹된 대상"
      },
      "last_used_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /channels/:id/send_test.json 채널로 테스트 메시지 보내기 notification_channels_send_test

권한: content.write

예시
curl -X POST https://privatusanalytics.com/channels/:id/send_test.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "채널 ID, 예: nch_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "email, slack, teams, discord, webhook, pagerduty, opsgenie 또는 push"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "마스킹된 대상"
    },
    "last_used_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /channels/:id.json 알림 채널 조회 notification_channels_get

권한: analytics.read

예시
curl https://privatusanalytics.com/channels/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "채널 ID, 예: nch_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "email, slack, teams, discord, webhook, pagerduty, opsgenie 또는 push"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "마스킹된 대상"
    },
    "last_used_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /channels/:id.json 알림 채널 수정 notification_channels_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/channels/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "웹훅 URL (slack, teams, discord, webhook), HTTPS"
    },
    "secret": {
      "type": "string",
      "description": "webhook: X-Privatus-Signature용 HMAC 시크릿"
    },
    "emails": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "email: 수신자 주소 (최대 20개)"
    },
    "routing_key": {
      "type": "string",
      "description": "pagerduty: Events API v2 통합 키"
    },
    "api_key": {
      "type": "string",
      "description": "opsgenie: API 통합 키"
    },
    "region": {
      "type": "string",
      "description": "opsgenie: 계정 리전",
      "enum": [
        "us",
        "eu"
      ]
    },
    "name": {
      "type": "string",
      "description": "표시 이름"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "채널 ID, 예: nch_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "email, slack, teams, discord, webhook, pagerduty, opsgenie 또는 push"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "마스킹된 대상"
    },
    "last_used_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /push_subscription.json 푸시 알림용 브라우저 등록 push_subscriptions_create

권한: member

예시
curl -X POST https://privatusanalytics.com/push_subscription.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "endpoint": {
      "type": "string",
      "description": "브라우저의 PushSubscription.endpoint"
    },
    "p256dh": {
      "type": "string",
      "description": "PushSubscription keys.p256dh (base64url)"
    },
    "auth": {
      "type": "string",
      "description": "PushSubscription keys.auth (base64url)"
    }
  },
  "required": [
    "endpoint",
    "p256dh",
    "auth"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "endpoint_host": {
      "type": "string",
      "description": "푸시 서비스 호스트"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /push_subscription.json 브라우저 푸시 등록 제거 push_subscriptions_delete

권한: member

예시
curl -X DELETE https://privatusanalytics.com/push_subscription.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "endpoint": {
      "type": "string",
      "description": "제거할 PushSubscription.endpoint"
    }
  },
  "required": [
    "endpoint"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "endpoint_host": {
      "type": "string",
      "description": "푸시 서비스 호스트"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

어시스턴트

POST /sites/:site_id/ask.json 새 대화에서 질문하기 (월간 AI 질문 한도에 포함됩니다) assistant_ask

권한: analytics.read

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/ask.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "question": {
      "type": "string",
      "description": "일상 언어로 쓴 첫 질문",
      "examples": [
        "How many visitors did we have last week?"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "question",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대화 ID, 예: ask_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "anyOf": [
        {
          "type": "string",
          "description": "첫 질문을 줄인 것"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time",
      "description": "마지막 메시지 시각"
    },
    "expires_at": {
      "type": "string",
      "format": "date-time",
      "description": "이 시각 이후 자동 삭제 (마지막 메시지 30일 후)"
    },
    "messages": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid",
          "description": "대화 내 메시지 ID"
        },
        "role": {
          "type": "string",
          "description": "user (질문) 또는 assistant (답변)"
        },
        "content": {
          "type": "string",
          "description": "질문, 또는 Markdown 형식의 답변"
        },
        "queries": {
          "type": "array",
          "items": {
            "type": "object"
          },
          "description": "근거: 답변의 바탕이 된 정확한 API 쿼리, [{tool, input, status, error}] 형식"
        },
        "chart": {
          "anyOf": [
            {
              "type": "object",
              "description": "답변의 차트: {type: line, labels, series, comparison, metric, format} 또는 {type: table, columns, rows}"
            },
            {
              "type": "null"
            }
          ]
        },
        "goal_draft": {
          "anyOf": [
            {
              "type": "object",
              "description": "어시스턴트가 제안한 목표, goals_create로 확정"
            },
            {
              "type": "null"
            }
          ]
        },
        "input_tokens": {
          "anyOf": [
            {
              "type": "integer",
              "description": "사용한 모델 입력 토큰"
            },
            {
              "type": "null"
            }
          ]
        },
        "output_tokens": {
          "anyOf": [
            {
              "type": "integer",
              "description": "사용한 모델 출력 토큰"
            },
            {
              "type": "null"
            }
          ]
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "description": "질문과 답변 (오래된 순)"
    }
  }
}
DELETE /sites/:site_id/ask/:id.json 질문 대화와 그 메시지 삭제 assistant_conversations_delete

권한: analytics.read

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/ask/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대화 ID, 예: ask_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "anyOf": [
        {
          "type": "string",
          "description": "첫 질문을 줄인 것"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time",
      "description": "마지막 메시지 시각"
    },
    "expires_at": {
      "type": "string",
      "format": "date-time",
      "description": "이 시각 이후 자동 삭제 (마지막 메시지 30일 후)"
    }
  }
}
GET /sites/:site_id/ask.json 사이트의 질문 대화 목록 보기 assistant_conversations_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/ask.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "대화 ID, 예: ask_7Q2K9XH3AB"
      },
      "site_id": {
        "anyOf": [
          {
            "type": "string",
            "description": "사이트 ID"
          },
          {
            "type": "null"
          }
        ]
      },
      "title": {
        "anyOf": [
          {
            "type": "string",
            "description": "첫 질문을 줄인 것"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      },
      "updated_at": {
        "type": "string",
        "format": "date-time",
        "description": "마지막 메시지 시각"
      },
      "expires_at": {
        "type": "string",
        "format": "date-time",
        "description": "이 시각 이후 자동 삭제 (마지막 메시지 30일 후)"
      }
    }
  }
}
GET /sites/:site_id/ask/:id.json 질문 대화: 질문, 답변, 그 근거가 된 쿼리와 차트 assistant_conversations_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/ask/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대화 ID, 예: ask_7Q2K9XH3AB"
    },
    "site_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "사이트 ID"
        },
        {
          "type": "null"
        }
      ]
    },
    "title": {
      "anyOf": [
        {
          "type": "string",
          "description": "첫 질문을 줄인 것"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time",
      "description": "마지막 메시지 시각"
    },
    "expires_at": {
      "type": "string",
      "format": "date-time",
      "description": "이 시각 이후 자동 삭제 (마지막 메시지 30일 후)"
    },
    "messages": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid",
          "description": "대화 내 메시지 ID"
        },
        "role": {
          "type": "string",
          "description": "user (질문) 또는 assistant (답변)"
        },
        "content": {
          "type": "string",
          "description": "질문, 또는 Markdown 형식의 답변"
        },
        "queries": {
          "type": "array",
          "items": {
            "type": "object"
          },
          "description": "근거: 답변의 바탕이 된 정확한 API 쿼리, [{tool, input, status, error}] 형식"
        },
        "chart": {
          "anyOf": [
            {
              "type": "object",
              "description": "답변의 차트: {type: line, labels, series, comparison, metric, format} 또는 {type: table, columns, rows}"
            },
            {
              "type": "null"
            }
          ]
        },
        "goal_draft": {
          "anyOf": [
            {
              "type": "object",
              "description": "어시스턴트가 제안한 목표, goals_create로 확정"
            },
            {
              "type": "null"
            }
          ]
        },
        "input_tokens": {
          "anyOf": [
            {
              "type": "integer",
              "description": "사용한 모델 입력 토큰"
            },
            {
              "type": "null"
            }
          ]
        },
        "output_tokens": {
          "anyOf": [
            {
              "type": "integer",
              "description": "사용한 모델 출력 토큰"
            },
            {
              "type": "null"
            }
          ]
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "description": "질문과 답변 (오래된 순)"
    }
  }
}
POST /sites/:site_id/ask/:ask_conversation_id/messages.json 대화에서 추가 질문하기 (월간 AI 질문 한도에 포함됩니다). 답변을 반환합니다. assistant_ask_followup

권한: analytics.read

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/ask/:ask_conversation_id/messages.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "question": {
      "type": "string",
      "description": "일상 언어로 쓴 질문",
      "examples": [
        "Which pages had the most visitors last week?"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "ask_conversation_id": {
      "type": "string",
      "description": "리소스의 Ask conversation"
    }
  },
  "required": [
    "question",
    "site_id",
    "ask_conversation_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "대화 내 메시지 ID"
    },
    "role": {
      "type": "string",
      "description": "user (질문) 또는 assistant (답변)"
    },
    "content": {
      "type": "string",
      "description": "질문, 또는 Markdown 형식의 답변"
    },
    "queries": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "근거: 답변의 바탕이 된 정확한 API 쿼리, [{tool, input, status, error}] 형식"
    },
    "chart": {
      "anyOf": [
        {
          "type": "object",
          "description": "답변의 차트: {type: line, labels, series, comparison, metric, format} 또는 {type: table, columns, rows}"
        },
        {
          "type": "null"
        }
      ]
    },
    "goal_draft": {
      "anyOf": [
        {
          "type": "object",
          "description": "어시스턴트가 제안한 목표, goals_create로 확정"
        },
        {
          "type": "null"
        }
      ]
    },
    "input_tokens": {
      "anyOf": [
        {
          "type": "integer",
          "description": "사용한 모델 입력 토큰"
        },
        {
          "type": "null"
        }
      ]
    },
    "output_tokens": {
      "anyOf": [
        {
          "type": "integer",
          "description": "사용한 모델 출력 토큰"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

역할

POST /workspaces/:workspace_id/roles.json 사용자 지정 역할 만들기 roles_create

권한: members.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/roles.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "역할 이름",
      "examples": [
        "Client reviewer"
      ]
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "analytics.read",
          "analytics.export",
          "content.write",
          "sites.manage",
          "uptime.manage",
          "members.manage",
          "tokens.manage",
          "billing.manage",
          "workspace.manage"
        ]
      },
      "description": "역할이 부여하는 권한"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "permissions",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "사용자 지정 역할 ID (멤버의 custom_role_id)"
    },
    "name": {
      "type": "string"
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "부여된 권한"
    },
    "members": {
      "type": "integer",
      "description": "이 역할의 멤버"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /workspaces/:workspace_id/roles/:id.json 사용자 지정 역할 삭제 (사용 중이 아니어야 함) roles_delete

권한: members.manage

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:workspace_id/roles/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "사용자 지정 역할 ID (멤버의 custom_role_id)"
    },
    "name": {
      "type": "string"
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "부여된 권한"
    },
    "members": {
      "type": "integer",
      "description": "이 역할의 멤버"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/roles.json 사용자 지정 역할 목록 보기 roles_list

권한: member

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/roles.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid",
        "description": "사용자 지정 역할 ID (멤버의 custom_role_id)"
      },
      "name": {
        "type": "string"
      },
      "permissions": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "부여된 권한"
      },
      "members": {
        "type": "integer",
        "description": "이 역할의 멤버"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
PATCH /workspaces/:workspace_id/roles/:id.json 사용자 지정 역할 수정 roles_update

권한: members.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/roles/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "역할 이름"
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "analytics.read",
          "analytics.export",
          "content.write",
          "sites.manage",
          "uptime.manage",
          "members.manage",
          "tokens.manage",
          "billing.manage",
          "workspace.manage"
        ]
      },
      "description": "역할이 부여하는 권한"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "사용자 지정 역할 ID (멤버의 custom_role_id)"
    },
    "name": {
      "type": "string"
    },
    "permissions": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "부여된 권한"
    },
    "members": {
      "type": "integer",
      "description": "이 역할의 멤버"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

요금제

GET /plans.json 요금제, 가격, 한도 목록 보기 plans_list

권한: public

예시
curl https://privatusanalytics.com/plans.json
입력
{
  "type": "object",
  "properties": {
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "name": {
        "type": "string",
        "description": "free, pro, business 또는 enterprise"
      },
      "events": {
        "anyOf": [
          {
            "type": "integer",
            "description": "월간 포함 이벤트 수 (무료 요금제만)"
          },
          {
            "type": "null"
          }
        ]
      },
      "badge_bonus": {
        "anyOf": [
          {
            "type": "integer",
            "description": "배지를 표시하면 받는 월간 추가 이벤트 수 (무료 요금제)"
          },
          {
            "type": "null"
          }
        ]
      },
      "limits": {
        "type": "object",
        "description": "요금제 한도. null은 무제한"
      },
      "tiers": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "events": {
              "type": "integer",
              "description": "포함된 월간 이벤트 수"
            },
            "monthly": {
              "type": "integer",
              "description": "월 USD, 월 단위 결제"
            },
            "yearly": {
              "type": "integer",
              "description": "연 USD, 연 단위 결제 (2개월 무료)"
            },
            "monthly_price_id": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "Paddle 가격 ID (월간)"
                },
                {
                  "type": "null"
                }
              ]
            },
            "yearly_price_id": {
              "anyOf": [
                {
                  "type": "string",
                  "description": "Paddle 가격 ID (연간)"
                },
                {
                  "type": "null"
                }
              ]
            }
          }
        },
        "description": "월간 이벤트 수별 가격 구간"
      },
      "contact_sales": {
        "type": "boolean",
        "description": "계약별 가격"
      }
    }
  }
}

워크스페이스

GET /workspaces/:workspace_id/white_label.json 화이트 라벨 브랜드 조회 white_label_get

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/white_label.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "brand_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "Privatus Analytics 대신 표시되는 이름"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_logo_url": {
      "anyOf": [
        {
          "type": "string",
          "description": "로고 이미지 URL"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_color": {
      "anyOf": [
        {
          "type": "string",
          "description": "강조 색상"
        },
        {
          "type": "null"
        }
      ]
    },
    "hide_branding": {
      "type": "boolean",
      "description": "Privatus 브랜딩이 숨겨짐"
    },
    "available": {
      "type": "boolean",
      "description": "요금제에 화이트 라벨이 포함됨"
    },
    "active": {
      "type": "boolean",
      "description": "브랜드가 현재 적용됨"
    }
  }
}
PATCH /workspaces/:workspace_id/white_label.json 공유 대시보드와 이메일 리포트의 화이트 라벨 브랜드 설정 (Business) white_label_update

권한: workspace.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/white_label.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "brand_name": {
      "type": "string",
      "description": "Privatus Analytics 대신 표시할 이름 (비우면 제거)"
    },
    "brand_logo_url": {
      "type": "string",
      "description": "로고 이미지의 https URL (비우면 제거)"
    },
    "brand_color": {
      "type": "string",
      "description": "강조 색상, 예: #06755b"
    },
    "hide_branding": {
      "type": "boolean",
      "description": "공유 대시보드와 이메일 리포트에서 \"Privatus\" 숨기기"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "brand_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "Privatus Analytics 대신 표시되는 이름"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_logo_url": {
      "anyOf": [
        {
          "type": "string",
          "description": "로고 이미지 URL"
        },
        {
          "type": "null"
        }
      ]
    },
    "brand_color": {
      "anyOf": [
        {
          "type": "string",
          "description": "강조 색상"
        },
        {
          "type": "null"
        }
      ]
    },
    "hide_branding": {
      "type": "boolean",
      "description": "Privatus 브랜딩이 숨겨짐"
    },
    "available": {
      "type": "boolean",
      "description": "요금제에 화이트 라벨이 포함됨"
    },
    "active": {
      "type": "boolean",
      "description": "브랜드가 현재 적용됨"
    }
  }
}
GET /workspaces/:workspace_id/security.json 워크스페이스 보안 설정 조회 workspace_security_get

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/security.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "enforce_2fa": {
      "type": "boolean",
      "description": "멤버가 2FA를 설정해야 함"
    },
    "login_methods": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "허용되는 로그인 방법"
    },
    "session_ttl_hours": {
      "anyOf": [
        {
          "type": "integer",
          "description": "세션 유효 기간 (null = 없음)"
        },
        {
          "type": "null"
        }
      ]
    },
    "app_ip_allowlist": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "허용된 IP/CIDR (비어 있으면 어디서나)"
    },
    "support_access_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "Privatus 지원팀이 워크스페이스를 볼 수 있는 기한"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
PATCH /workspaces/:workspace_id/security.json 워크스페이스 보안 설정 수정 (2FA, 로그인 방법, 세션 유효 기간, IP 허용 목록, 지원 접근) workspace_security_update

권한: workspace.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/security.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "enforce_2fa": {
      "type": "boolean",
      "description": "멤버에게 2FA 설정을 요구"
    },
    "login_methods": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "password",
          "magic_link",
          "passkey",
          "google",
          "github",
          "sso"
        ]
      },
      "description": "허용되는 로그인 방법"
    },
    "session_ttl_hours": {
      "type": "integer",
      "description": "이 시간(시간 단위)이 지나면 멤버를 로그아웃 (0 = 제한 없음)"
    },
    "app_ip_allowlist": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이 IP/CIDR에서만 앱과 API 접근 허용 (Business). 비우면 어디서나"
    },
    "support_access": {
      "type": "boolean",
      "description": "Privatus 지원팀이 7일간 워크스페이스를 볼 수 있도록 허용"
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string"
    },
    "enforce_2fa": {
      "type": "boolean",
      "description": "멤버가 2FA를 설정해야 함"
    },
    "login_methods": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "허용되는 로그인 방법"
    },
    "session_ttl_hours": {
      "anyOf": [
        {
          "type": "integer",
          "description": "세션 유효 기간 (null = 없음)"
        },
        {
          "type": "null"
        }
      ]
    },
    "app_ip_allowlist": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "허용된 IP/CIDR (비어 있으면 어디서나)"
    },
    "support_access_until": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "Privatus 지원팀이 워크스페이스를 볼 수 있는 기한"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /workspaces.json 워크스페이스 만들기 (본인이 소유자가 됨) workspaces_create

권한: member · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/workspaces.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "워크스페이스 이름",
      "examples": [
        "Acme Inc"
      ]
    },
    "timezone": {
      "type": "string",
      "description": "기본 리포트 시간대 (기본값은 사용자의 시간대)"
    },
    "currency": {
      "type": "string",
      "description": "기본 통화 (ISO 4217)",
      "default": "USD"
    },
    "how_heard": {
      "type": "string",
      "description": "우리를 알게 된 경로"
    }
  },
  "required": [
    "name"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "timezone": {
      "type": "string",
      "description": "기본 리포트 시간대"
    },
    "currency": {
      "type": "string",
      "description": "기본 통화"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "요금제에 포함된 월간 이벤트 수"
    },
    "subscription_status": {
      "type": "string"
    },
    "role": {
      "type": "string",
      "description": "이 워크스페이스에서의 내 역할"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /workspaces/:id.json 워크스페이스와 모든 사이트 삭제 (소유자 전용, 구독도 해지됨) workspaces_delete

권한: workspace.manage

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "confirm": {
      "type": "string",
      "description": "확인을 위해 워크스페이스 이름을 입력하세요"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "confirm",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "timezone": {
      "type": "string",
      "description": "기본 리포트 시간대"
    },
    "currency": {
      "type": "string",
      "description": "기본 통화"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "요금제에 포함된 월간 이벤트 수"
    },
    "subscription_status": {
      "type": "string"
    },
    "role": {
      "type": "string",
      "description": "이 워크스페이스에서의 내 역할"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces.json 내 워크스페이스 목록 보기 workspaces_list

권한: member

예시
curl https://privatusanalytics.com/workspaces.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
      },
      "name": {
        "type": "string"
      },
      "timezone": {
        "type": "string",
        "description": "기본 리포트 시간대"
      },
      "currency": {
        "type": "string",
        "description": "기본 통화"
      },
      "plan": {
        "type": "string",
        "description": "free, pro, business 또는 enterprise"
      },
      "plan_events": {
        "type": "integer",
        "description": "요금제에 포함된 월간 이벤트 수"
      },
      "subscription_status": {
        "type": "string"
      },
      "role": {
        "type": "string",
        "description": "이 워크스페이스에서의 내 역할"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /workspaces/:id.json 워크스페이스 조회 workspaces_get

권한: member

예시
curl https://privatusanalytics.com/workspaces/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "timezone": {
      "type": "string",
      "description": "기본 리포트 시간대"
    },
    "currency": {
      "type": "string",
      "description": "기본 통화"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "요금제에 포함된 월간 이벤트 수"
    },
    "subscription_status": {
      "type": "string"
    },
    "role": {
      "type": "string",
      "description": "이 워크스페이스에서의 내 역할"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /workspaces/:id.json 워크스페이스 설정 수정 workspaces_update

권한: workspace.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "워크스페이스 이름"
    },
    "timezone": {
      "type": "string",
      "description": "기본 리포트 시간대"
    },
    "currency": {
      "type": "string",
      "description": "기본 통화 (ISO 4217)"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "timezone": {
      "type": "string",
      "description": "기본 리포트 시간대"
    },
    "currency": {
      "type": "string",
      "description": "기본 통화"
    },
    "plan": {
      "type": "string",
      "description": "free, pro, business 또는 enterprise"
    },
    "plan_events": {
      "type": "integer",
      "description": "요금제에 포함된 월간 이벤트 수"
    },
    "subscription_status": {
      "type": "string"
    },
    "role": {
      "type": "string",
      "description": "이 워크스페이스에서의 내 역할"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

웨어하우스 동기화

POST /workspaces/:workspace_id/warehouses.json 웨어하우스 대상 추가 warehouse_destinations_create

권한: workspace.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/warehouses.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "표시 이름, 예: 데이터 레이크"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "보낼 사이트 (pa_…). 비우면 모든 사이트를 보냄"
    },
    "bucket": {
      "type": "string",
      "description": "s3: 버킷 이름"
    },
    "region": {
      "type": "string",
      "description": "s3: 리전, 예: us-east-1 (R2는 auto)"
    },
    "prefix": {
      "type": "string",
      "description": "s3/azure: 경로 접두사, 예: privatus/events"
    },
    "endpoint": {
      "type": "string",
      "description": "s3: S3 호환 스토리지 (GCS 상호 운용성, R2, MinIO)의 https 엔드포인트"
    },
    "access_key_id": {
      "type": "string",
      "description": "s3: 액세스 키 ID"
    },
    "secret_access_key": {
      "type": "string",
      "description": "s3: 시크릿 액세스 키 (쓰기 전용)"
    },
    "service_account_json": {
      "type": "string",
      "description": "bigquery: BigQuery 데이터 편집자 권한이 있는 서비스 계정 JSON 키 (쓰기 전용)"
    },
    "project_id": {
      "type": "string",
      "description": "bigquery: 프로젝트 ID (기본값: 키에서 가져옴)"
    },
    "dataset": {
      "type": "string",
      "description": "bigquery: 데이터세트 ID"
    },
    "table": {
      "type": "string",
      "description": "bigquery/snowflake: 테이블 이름 (열: 스키마 v1)"
    },
    "account": {
      "type": "string",
      "description": "snowflake: 계정 식별자, 예: xy12345.us-east-1 또는 myorg-myaccount"
    },
    "user": {
      "type": "string",
      "description": "snowflake: 키 페어 인증을 사용하는 사용자"
    },
    "private_key": {
      "type": "string",
      "description": "snowflake: PEM RSA 개인 키 (쓰기 전용)"
    },
    "database": {
      "type": "string",
      "description": "snowflake: 데이터베이스"
    },
    "schema": {
      "type": "string",
      "description": "snowflake: 스키마"
    },
    "warehouse": {
      "type": "string",
      "description": "snowflake: 가상 웨어하우스"
    },
    "role": {
      "type": "string",
      "description": "snowflake: 역할 (선택)"
    },
    "sas_url": {
      "type": "string",
      "description": "azure: 생성/쓰기 권한이 있는 컨테이너 SAS URL (쓰기 전용)"
    },
    "kind": {
      "type": "string",
      "description": "s3 (GCS/R2/MinIO 포함), bigquery, snowflake 또는 azure",
      "enum": [
        "s3",
        "bigquery",
        "snowflake",
        "azure"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "kind",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대상 ID, 예: whd_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "s3, bigquery, snowflake 또는 azure"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "데이터가 가는 곳: s3://bucket/prefix, project.dataset.table, account/database.schema.table 또는 Azure 컨테이너"
    },
    "configured": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "채워진 설정 이름 (값은 절대 반환되지 않음)"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "전송되는 사이트 (pa_…). 비어 있으면 모든 사이트"
    },
    "schedule": {
      "type": "string",
      "description": "daily: 02:00 UTC, 전날 UTC 하루치를 전송"
    },
    "schema_version": {
      "type": "string",
      "description": "전송되는 행 스키마"
    },
    "last_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /warehouses/:id.json 웨어하우스 대상 삭제 warehouse_destinations_delete

권한: workspace.manage

예시
curl -X DELETE https://privatusanalytics.com/warehouses/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대상 ID, 예: whd_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "s3, bigquery, snowflake 또는 azure"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "데이터가 가는 곳: s3://bucket/prefix, project.dataset.table, account/database.schema.table 또는 Azure 컨테이너"
    },
    "configured": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "채워진 설정 이름 (값은 절대 반환되지 않음)"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "전송되는 사이트 (pa_…). 비어 있으면 모든 사이트"
    },
    "schedule": {
      "type": "string",
      "description": "daily: 02:00 UTC, 전날 UTC 하루치를 전송"
    },
    "schema_version": {
      "type": "string",
      "description": "전송되는 행 스키마"
    },
    "last_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/warehouses.json 웨어하우스 대상 목록 보기 warehouse_destinations_list

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/warehouses.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "kind": {
      "type": "string",
      "description": "이 종류의 대상만",
      "enum": [
        "s3",
        "bigquery",
        "snowflake",
        "azure"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "대상 ID, 예: whd_7Q2K9XH3AB"
      },
      "kind": {
        "type": "string",
        "description": "s3, bigquery, snowflake 또는 azure"
      },
      "name": {
        "type": "string"
      },
      "target": {
        "type": "string",
        "description": "데이터가 가는 곳: s3://bucket/prefix, project.dataset.table, account/database.schema.table 또는 Azure 컨테이너"
      },
      "configured": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "채워진 설정 이름 (값은 절대 반환되지 않음)"
      },
      "site_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "전송되는 사이트 (pa_…). 비어 있으면 모든 사이트"
      },
      "schedule": {
        "type": "string",
        "description": "daily: 02:00 UTC, 전날 UTC 하루치를 전송"
      },
      "schema_version": {
        "type": "string",
        "description": "전송되는 행 스키마"
      },
      "last_run_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "next_run_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_error": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /warehouses/:id.json 웨어하우스 대상 조회 (비밀 값 제외) warehouse_destinations_get

권한: workspace.manage

예시
curl https://privatusanalytics.com/warehouses/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대상 ID, 예: whd_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "s3, bigquery, snowflake 또는 azure"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "데이터가 가는 곳: s3://bucket/prefix, project.dataset.table, account/database.schema.table 또는 Azure 컨테이너"
    },
    "configured": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "채워진 설정 이름 (값은 절대 반환되지 않음)"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "전송되는 사이트 (pa_…). 비어 있으면 모든 사이트"
    },
    "schedule": {
      "type": "string",
      "description": "daily: 02:00 UTC, 전날 UTC 하루치를 전송"
    },
    "schema_version": {
      "type": "string",
      "description": "전송되는 행 스키마"
    },
    "last_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /warehouses/:id/sync.json 하루치 동기화를 지금 대기열에 추가 warehouse_destinations_sync

권한: workspace.manage

예시
curl -X POST https://privatusanalytics.com/warehouses/:id/sync.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "date": {
      "type": "string",
      "format": "date",
      "description": "보낼 UTC 날짜, 예: 2026-09-28 (기본값: 어제)"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대상 ID, 예: whd_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "s3, bigquery, snowflake 또는 azure"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "데이터가 가는 곳: s3://bucket/prefix, project.dataset.table, account/database.schema.table 또는 Azure 컨테이너"
    },
    "configured": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "채워진 설정 이름 (값은 절대 반환되지 않음)"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "전송되는 사이트 (pa_…). 비어 있으면 모든 사이트"
    },
    "schedule": {
      "type": "string",
      "description": "daily: 02:00 UTC, 전날 UTC 하루치를 전송"
    },
    "schema_version": {
      "type": "string",
      "description": "전송되는 행 스키마"
    },
    "last_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /warehouses/:id.json 웨어하우스 대상 수정 (비워 둔 비밀 값은 유지됨) warehouse_destinations_update

권한: workspace.manage

예시
curl -X PATCH https://privatusanalytics.com/warehouses/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "표시 이름, 예: 데이터 레이크"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "보낼 사이트 (pa_…). 비우면 모든 사이트를 보냄"
    },
    "bucket": {
      "type": "string",
      "description": "s3: 버킷 이름"
    },
    "region": {
      "type": "string",
      "description": "s3: 리전, 예: us-east-1 (R2는 auto)"
    },
    "prefix": {
      "type": "string",
      "description": "s3/azure: 경로 접두사, 예: privatus/events"
    },
    "endpoint": {
      "type": "string",
      "description": "s3: S3 호환 스토리지 (GCS 상호 운용성, R2, MinIO)의 https 엔드포인트"
    },
    "access_key_id": {
      "type": "string",
      "description": "s3: 액세스 키 ID"
    },
    "secret_access_key": {
      "type": "string",
      "description": "s3: 시크릿 액세스 키 (쓰기 전용)"
    },
    "service_account_json": {
      "type": "string",
      "description": "bigquery: BigQuery 데이터 편집자 권한이 있는 서비스 계정 JSON 키 (쓰기 전용)"
    },
    "project_id": {
      "type": "string",
      "description": "bigquery: 프로젝트 ID (기본값: 키에서 가져옴)"
    },
    "dataset": {
      "type": "string",
      "description": "bigquery: 데이터세트 ID"
    },
    "table": {
      "type": "string",
      "description": "bigquery/snowflake: 테이블 이름 (열: 스키마 v1)"
    },
    "account": {
      "type": "string",
      "description": "snowflake: 계정 식별자, 예: xy12345.us-east-1 또는 myorg-myaccount"
    },
    "user": {
      "type": "string",
      "description": "snowflake: 키 페어 인증을 사용하는 사용자"
    },
    "private_key": {
      "type": "string",
      "description": "snowflake: PEM RSA 개인 키 (쓰기 전용)"
    },
    "database": {
      "type": "string",
      "description": "snowflake: 데이터베이스"
    },
    "schema": {
      "type": "string",
      "description": "snowflake: 스키마"
    },
    "warehouse": {
      "type": "string",
      "description": "snowflake: 가상 웨어하우스"
    },
    "role": {
      "type": "string",
      "description": "snowflake: 역할 (선택)"
    },
    "sas_url": {
      "type": "string",
      "description": "azure: 생성/쓰기 권한이 있는 컨테이너 SAS URL (쓰기 전용)"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "대상 ID, 예: whd_7Q2K9XH3AB"
    },
    "kind": {
      "type": "string",
      "description": "s3, bigquery, snowflake 또는 azure"
    },
    "name": {
      "type": "string"
    },
    "target": {
      "type": "string",
      "description": "데이터가 가는 곳: s3://bucket/prefix, project.dataset.table, account/database.schema.table 또는 Azure 컨테이너"
    },
    "configured": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "채워진 설정 이름 (값은 절대 반환되지 않음)"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "전송되는 사이트 (pa_…). 비어 있으면 모든 사이트"
    },
    "schedule": {
      "type": "string",
      "description": "daily: 02:00 UTC, 전날 UTC 하루치를 전송"
    },
    "schema_version": {
      "type": "string",
      "description": "전송되는 행 스키마"
    },
    "last_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

웹사이트

GET /changelog.json 변경 내역 항목 목록 보기 changelog_list

게시된 제품 업데이트를 최신순으로 제공합니다. /changelog.rss에서 RSS로도 받을 수 있습니다.

권한: public

예시
curl https://privatusanalytics.com/changelog.json
입력
{
  "type": "object",
  "properties": {
    "area": {
      "type": "string",
      "description": "이 제품 영역의 항목만",
      "enum": [
        "product",
        "dashboard",
        "tracker",
        "privacy",
        "api",
        "integrations",
        "billing",
        "docs"
      ]
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "항목 ID, 예: chg_7Q2K9XH3AB"
      },
      "title": {
        "type": "string",
        "description": "제목"
      },
      "area": {
        "type": "string",
        "description": "제품 영역, 예: dashboard, tracker, api"
      },
      "body": {
        "type": "string",
        "description": "Markdown 본문"
      },
      "published_at": {
        "type": "string",
        "format": "date-time",
        "description": "게시 시각"
      },
      "url": {
        "type": "string",
        "description": "고정 링크"
      }
    }
  }
}
GET /changelog/:id.json 변경 내역 항목 조회 changelog_get

권한: public

예시
curl https://privatusanalytics.com/changelog/:id.json
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "항목 ID, 예: chg_7Q2K9XH3AB"
    },
    "title": {
      "type": "string",
      "description": "제목"
    },
    "area": {
      "type": "string",
      "description": "제품 영역, 예: dashboard, tracker, api"
    },
    "body": {
      "type": "string",
      "description": "Markdown 본문"
    },
    "published_at": {
      "type": "string",
      "format": "date-time",
      "description": "게시 시각"
    },
    "url": {
      "type": "string",
      "description": "고정 링크"
    }
  }
}
POST /contact.json Privatus 팀에 메시지 보내기 contact_create

브라우저 클라이언트는 Cloudflare Turnstile 토큰을 `cf-turnstile-response`로 보냅니다. API 토큰을 쓰는 요청에는 필요하지 않습니다.

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/contact.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "이름",
      "examples": [
        "Ada Lovelace"
      ]
    },
    "email": {
      "type": "string",
      "description": "답변을 받을 주소",
      "examples": [
        "[email protected]"
      ]
    },
    "company": {
      "type": "string",
      "description": "회사 또는 조직 (선택)"
    },
    "topic": {
      "type": "string",
      "description": "메시지 주제",
      "enum": [
        "general",
        "sales",
        "support",
        "privacy",
        "security",
        "partnerships",
        "press"
      ],
      "default": "general"
    },
    "message": {
      "type": "string",
      "description": "메시지 (10자에서 5,000자)"
    },
    "website": {
      "type": "string",
      "description": "비워 두세요. 봇을 잡기 위한 스팸 트랩입니다. 채워진 제출은 폐기됩니다"
    }
  },
  "required": [
    "name",
    "email",
    "message"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "received": {
      "type": "boolean",
      "description": "제출이 접수되었으면 항상 true"
    },
    "message": {
      "type": "string",
      "description": "다음에 일어날 일"
    }
  }
}
POST /newsletter/confirm.json 뉴스레터 구독 확인 (서명된 토큰) newsletter_confirm

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/newsletter/confirm.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "확인 이메일에 포함된 서명된 토큰"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "received": {
      "type": "boolean",
      "description": "제출이 접수되었으면 항상 true"
    },
    "message": {
      "type": "string",
      "description": "다음에 일어날 일"
    }
  }
}
POST /newsletter.json 이메일을 뉴스레터에 구독 newsletter_subscribe

브라우저 클라이언트는 Cloudflare Turnstile 토큰을 `cf-turnstile-response`로 보냅니다. API 토큰을 쓰는 요청에는 필요하지 않습니다.

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/newsletter.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "description": "구독할 이메일 주소. 확인 링크가 이메일로 전송됩니다",
      "examples": [
        "[email protected]"
      ]
    },
    "website": {
      "type": "string",
      "description": "비워 두세요. 봇을 잡기 위한 스팸 트랩입니다. 채워진 제출은 폐기됩니다"
    }
  },
  "required": [
    "email"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "received": {
      "type": "boolean",
      "description": "제출이 접수되었으면 항상 true"
    },
    "message": {
      "type": "string",
      "description": "다음에 일어날 일"
    }
  }
}
POST /newsletter/unsubscribe.json 서명된 링크 토큰으로 구독 해지 newsletter_unsubscribe

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/newsletter/unsubscribe.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "수신 거부 링크의 서명된 토큰"
    },
    "list": {
      "type": "string",
      "description": "newsletter (기본값: 링크가 해당하는 목록) 또는 marketing (모든 마케팅 이메일)",
      "enum": [
        "newsletter",
        "marketing"
      ]
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "received": {
      "type": "boolean",
      "description": "제출이 접수되었으면 항상 true"
    },
    "message": {
      "type": "string",
      "description": "다음에 일어날 일"
    }
  }
}
GET /pricing.json 요금제, 가격, 요금제 한도 조회 pricing_get

가격 페이지와 같은 데이터입니다: 이벤트 구간표, 모든 요금제 한도, 이벤트로 집계되는 항목. events를 넘기면 해당하는 티어를 받습니다.

권한: public

예시
curl https://privatusanalytics.com/pricing.json
입력
{
  "type": "object",
  "properties": {
    "events": {
      "type": "integer",
      "description": "월간 예상 페이지뷰와 사용자 지정 이벤트 수. 해당하는 티어를 `recommendation`으로 반환합니다",
      "examples": [
        750000
      ]
    },
    "interval": {
      "type": "string",
      "description": "표시할 가격의 결제 주기: month 또는 year (월 가격의 10배)",
      "enum": [
        "month",
        "year"
      ],
      "default": "month"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "object",
  "properties": {
    "currency": {
      "type": "string",
      "description": "모든 가격의 통화 (USD)"
    },
    "tax_included": {
      "type": "boolean",
      "description": "항상 true. 가격에 부가가치세 또는 판매세가 포함되어 있어 표시된 가격이 곧 결제 금액입니다"
    },
    "interval": {
      "type": "string",
      "description": "month 또는 year. 가격은 이 주기 기준입니다"
    },
    "annual_multiplier": {
      "type": "integer",
      "description": "연 가격 = 월 가격 x 이 값 (2개월 무료)"
    },
    "free_events": {
      "type": "integer",
      "description": "Free 요금제에 포함된 월간 이벤트 수"
    },
    "badge_bonus": {
      "type": "integer",
      "description": "선택 배지를 표시하면 받는 월간 추가 무료 이벤트 수"
    },
    "tiers": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "이벤트 구간표: 해당 주기의 { events, pro, business } 가격 (Business만 제공되는 곳은 pro가 null), 그리고 월 가격"
    },
    "plans": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "{ id, name, from_price, limits }가 있는 요금제. limits가 null이면 무제한"
    },
    "counted": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "과금 대상 이벤트로 집계되는 항목"
    },
    "not_counted": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "사용량에 절대 포함되지 않는 항목"
    },
    "recommendation": {
      "anyOf": [
        {
          "type": "object",
          "description": "`events` 입력에 대한 { events, plan, tier_events, price }, 물량을 주지 않았으면 null"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
GET /status.json 현재 시스템 상태 조회 status_get

데이터베이스, Redis, 백그라운드 작업 상태이며 최대 15초마다 확인됩니다.

권한: public

예시
curl https://privatusanalytics.com/status.json
입력
{
  "type": "object",
  "properties": {
    "fresh": {
      "type": "boolean",
      "description": "15초 캐시를 건너뛰고 지금 다시 확인",
      "default": false
    }
  },
  "required": []
}
응답 데이터
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "전체: operational, degraded 또는 outage"
    },
    "checked_at": {
      "type": "string",
      "format": "date-time",
      "description": "검사가 실행된 시각 (최대 15초 캐시)"
    },
    "components": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "구성 요소별: { id, name, status, detail, latency_ms }, 큐는 queue_latency_s와 queue_depth 추가"
    }
  }
}
GET /tools/header-checker.json 분석을 위한 페이지의 Referrer-Policy와 CSP 확인 tools_header_check

권한: public

예시
curl https://privatusanalytics.com/tools/header-checker.json
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "확인할 공개 페이지 (http 또는 https)",
      "examples": [
        "https://example.com"
      ]
    }
  },
  "required": [
    "url"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "리디렉션 후 최종 URL"
    },
    "status": {
      "type": "integer",
      "description": "최종 응답의 HTTP 상태"
    },
    "findings": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "검사 항목: { check, value, level (ok, warn, info), note }"
    }
  }
}
GET /tools/privacy-policy-generator.json Privatus Analytics용 개인정보 처리방침 문단 초안 작성 tools_privacy_policy

권한: public

예시
curl https://privatusanalytics.com/tools/privacy-policy-generator.json
입력
{
  "type": "object",
  "properties": {
    "site_name": {
      "type": "string",
      "description": "웹사이트 또는 회사 이름",
      "examples": [
        "Example Books"
      ]
    },
    "contact_email": {
      "type": "string",
      "description": "명시할 개인정보 문의 연락처 (선택)"
    },
    "honors_gpc": {
      "type": "boolean",
      "description": "Do Not Track과 Global Privacy Control을 따르는지 여부 (기본값)",
      "default": true
    }
  },
  "required": [
    "site_name"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "site_name": {
      "type": "string",
      "description": "입력: 사이트 또는 회사 이름"
    },
    "paragraphs": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "처리방침 텍스트 (항목당 한 문단)"
    },
    "text": {
      "type": "string",
      "description": "빈 줄로 이어 붙인 문단"
    }
  }
}
GET /tools/qr-code.json QR 코드를 SVG로 생성 tools_qr_code

권한: public

예시
curl https://privatusanalytics.com/tools/qr-code.json
입력
{
  "type": "object",
  "properties": {
    "text": {
      "type": "string",
      "description": "인코딩할 URL 또는 텍스트 (최대 1,000자)",
      "examples": [
        "https://example.com/?utm_source=poster"
      ]
    },
    "level": {
      "type": "string",
      "description": "오류 정정: l (7%), m (15%), q (25%), h (30%)",
      "enum": [
        "l",
        "m",
        "q",
        "h"
      ],
      "default": "m"
    }
  },
  "required": [
    "text"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "text": {
      "type": "string",
      "description": "인코딩된 텍스트"
    },
    "level": {
      "type": "string",
      "description": "오류 정정 수준"
    },
    "size": {
      "type": "integer",
      "description": "한 변의 모듈 수"
    },
    "svg": {
      "type": "string",
      "description": "독립형 SVG 문서"
    }
  }
}
GET /tools/tracker-scanner.json 페이지의 쿠키와 알려진 트래커 목록 보기 tools_tracker_scan

권한: public

예시
curl https://privatusanalytics.com/tools/tracker-scanner.json
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "스캔할 공개 페이지 (http 또는 https)",
      "examples": [
        "https://example.com"
      ]
    }
  },
  "required": [
    "url"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "리디렉션 후 최종 URL"
    },
    "status": {
      "type": "integer",
      "description": "최종 응답의 HTTP 상태"
    },
    "truncated": {
      "type": "boolean",
      "description": "페이지가 1 MB를 넘어 처음 1 MB만 스캔했으면 true"
    },
    "cookies": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "HTTP 응답이 설정한 쿠키: { name, domain, path, expires, secure, http_only, same_site }. 값은 절대 반환되지 않습니다"
    },
    "trackers": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "페이지가 참조하는 알려진 도구: { name, category, match, evidence }"
    },
    "third_party_hosts": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "페이지가 리소스를 불러오는 다른 도메인"
    }
  }
}
GET /tools/utm-builder.json UTM 매개변수가 포함된 캠페인 URL 만들기 tools_utm_builder

권한: public

예시
curl https://privatusanalytics.com/tools/utm-builder.json
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "방문 페이지 URL",
      "examples": [
        "https://example.com/pricing"
      ]
    },
    "source": {
      "type": "string",
      "description": "utm_source: 트래픽이 오는 곳",
      "examples": [
        "newsletter"
      ]
    },
    "medium": {
      "type": "string",
      "description": "utm_medium: 채널, 예: email, cpc, social",
      "examples": [
        "email"
      ]
    },
    "campaign": {
      "type": "string",
      "description": "utm_campaign: 캠페인 이름",
      "examples": [
        "fall_launch"
      ]
    },
    "term": {
      "type": "string",
      "description": "utm_term: 유료 검색 키워드 (선택)"
    },
    "content": {
      "type": "string",
      "description": "utm_content: 어떤 링크 또는 소재인지 (선택)"
    }
  },
  "required": [
    "url",
    "source",
    "medium",
    "campaign"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "UTM 매개변수가 포함된 방문 페이지 URL"
    },
    "params": {
      "type": "object",
      "description": "추가된 UTM 매개변수"
    },
    "warnings": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "수정할 만한 문제 (대소문자, 공백, 개인 데이터)"
    }
  }
}
POST /waitlist.json 대기자 명단 등록 (EU 호스팅) waitlist_join

브라우저 클라이언트는 Cloudflare Turnstile 토큰을 `cf-turnstile-response`로 보냅니다. API 토큰을 쓰는 요청에는 필요하지 않습니다.

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/waitlist.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "email": {
      "type": "string",
      "description": "알림을 받을 이메일",
      "examples": [
        "[email protected]"
      ]
    },
    "list": {
      "type": "string",
      "description": "등록할 대기자 명단",
      "enum": [
        "eu_hosting"
      ],
      "default": "eu_hosting"
    },
    "website": {
      "type": "string",
      "description": "비워 두세요. 봇을 잡기 위한 스팸 트랩입니다. 채워진 제출은 폐기됩니다"
    }
  },
  "required": [
    "email"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "received": {
      "type": "boolean",
      "description": "제출이 접수되었으면 항상 true"
    },
    "message": {
      "type": "string",
      "description": "다음에 일어날 일"
    }
  }
}

웹훅

GET /workspaces/:workspace_id/webhooks/:webhook_id/deliveries.json 웹훅의 전송 기록 목록 보기 webhook_deliveries_list

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/webhooks/:webhook_id/deliveries.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "성공 또는 실패한 전송만",
      "enum": [
        "succeeded",
        "failed"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "webhook_id": {
      "type": "string",
      "description": "리소스의 Webhook"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id",
    "webhook_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "전송 ID, 예: whd_123"
      },
      "event": {
        "type": "string"
      },
      "status": {
        "type": "string",
        "description": "pending, succeeded 또는 failed"
      },
      "status_code": {
        "anyOf": [
          {
            "type": "integer",
            "description": "마지막 시도의 HTTP 상태"
          },
          {
            "type": "null"
          }
        ]
      },
      "error": {
        "anyOf": [
          {
            "type": "string",
            "description": "마지막 시도의 연결 오류"
          },
          {
            "type": "null"
          }
        ]
      },
      "attempt": {
        "type": "integer"
      },
      "duration_ms": {
        "anyOf": [
          {
            "type": "integer"
          },
          {
            "type": "null"
          }
        ]
      },
      "payload": {
        "type": "object"
      },
      "response_body": {
        "anyOf": [
          {
            "type": "string",
            "description": "처음 2,000자"
          },
          {
            "type": "null"
          }
        ]
      },
      "delivered_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /workspaces/:workspace_id/webhooks/:webhook_id/deliveries/:id/redeliver.json 전송 다시 보내기 webhook_deliveries_redeliver

권한: workspace.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/webhooks/:webhook_id/deliveries/:id/redeliver.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "webhook_id": {
      "type": "string",
      "description": "리소스의 Webhook"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "webhook_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "전송 ID, 예: whd_123"
    },
    "event": {
      "type": "string"
    },
    "status": {
      "type": "string",
      "description": "pending, succeeded 또는 failed"
    },
    "status_code": {
      "anyOf": [
        {
          "type": "integer",
          "description": "마지막 시도의 HTTP 상태"
        },
        {
          "type": "null"
        }
      ]
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "마지막 시도의 연결 오류"
        },
        {
          "type": "null"
        }
      ]
    },
    "attempt": {
      "type": "integer"
    },
    "duration_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "payload": {
      "type": "object"
    },
    "response_body": {
      "anyOf": [
        {
          "type": "string",
          "description": "처음 2,000자"
        },
        {
          "type": "null"
        }
      ]
    },
    "delivered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /workspaces/:workspace_id/webhooks.json 웹훅 엔드포인트 추가 webhooks_create

권한: workspace.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/webhooks.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "POST된 JSON을 받는 HTTPS 엔드포인트",
      "examples": [
        "https://example.com/hooks/privatus"
      ]
    },
    "events": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "alert.triggered",
          "alert.resolved",
          "goal.completed_threshold",
          "uptime.down",
          "uptime.up",
          "export.ready",
          "import.completed",
          "import.failed",
          "site.created",
          "site.deleted",
          "member.added",
          "usage.threshold"
        ]
      },
      "description": "보낼 이벤트"
    },
    "enabled": {
      "type": "boolean",
      "description": "전송 활성화",
      "default": true
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "url",
    "events",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "웹훅 ID, 예: wh_7Q2K9XH3AB"
    },
    "url": {
      "type": "string"
    },
    "events": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "enabled": {
      "type": "boolean"
    },
    "status": {
      "type": "string",
      "description": "active, failing 또는 disabled"
    },
    "secret": {
      "type": "string",
      "description": "Privatus-Signature용 서명 시크릿"
    },
    "consecutive_failures": {
      "type": "integer"
    },
    "last_success_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_failure_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /workspaces/:workspace_id/webhooks/:id.json 웹훅 삭제 webhooks_delete

권한: workspace.manage

예시
curl -X DELETE https://privatusanalytics.com/workspaces/:workspace_id/webhooks/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "웹훅 ID, 예: wh_7Q2K9XH3AB"
    },
    "url": {
      "type": "string"
    },
    "events": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "enabled": {
      "type": "boolean"
    },
    "status": {
      "type": "string",
      "description": "active, failing 또는 disabled"
    },
    "secret": {
      "type": "string",
      "description": "Privatus-Signature용 서명 시크릿"
    },
    "consecutive_failures": {
      "type": "integer"
    },
    "last_success_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_failure_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/webhooks.json 웹훅 목록 보기 webhooks_list

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/webhooks.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "웹훅 ID, 예: wh_7Q2K9XH3AB"
      },
      "url": {
        "type": "string"
      },
      "events": {
        "type": "array",
        "items": {
          "type": "string"
        }
      },
      "enabled": {
        "type": "boolean"
      },
      "status": {
        "type": "string",
        "description": "active, failing 또는 disabled"
      },
      "secret": {
        "type": "string",
        "description": "Privatus-Signature용 서명 시크릿"
      },
      "consecutive_failures": {
        "type": "integer"
      },
      "last_success_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "last_failure_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /workspaces/:workspace_id/webhooks/:id.json 웹훅 조회 webhooks_get

권한: workspace.manage

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/webhooks/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "웹훅 ID, 예: wh_7Q2K9XH3AB"
    },
    "url": {
      "type": "string"
    },
    "events": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "enabled": {
      "type": "boolean"
    },
    "status": {
      "type": "string",
      "description": "active, failing 또는 disabled"
    },
    "secret": {
      "type": "string",
      "description": "Privatus-Signature용 서명 시크릿"
    },
    "consecutive_failures": {
      "type": "integer"
    },
    "last_success_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_failure_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /workspaces/:workspace_id/webhooks/:id/test.json 테스트 전송 보내기 webhooks_test

권한: workspace.manage

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/webhooks/:id/test.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "전송 ID, 예: whd_123"
    },
    "event": {
      "type": "string"
    },
    "status": {
      "type": "string",
      "description": "pending, succeeded 또는 failed"
    },
    "status_code": {
      "anyOf": [
        {
          "type": "integer",
          "description": "마지막 시도의 HTTP 상태"
        },
        {
          "type": "null"
        }
      ]
    },
    "error": {
      "anyOf": [
        {
          "type": "string",
          "description": "마지막 시도의 연결 오류"
        },
        {
          "type": "null"
        }
      ]
    },
    "attempt": {
      "type": "integer"
    },
    "duration_ms": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "payload": {
      "type": "object"
    },
    "response_body": {
      "anyOf": [
        {
          "type": "string",
          "description": "처음 2,000자"
        },
        {
          "type": "null"
        }
      ]
    },
    "delivered_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /workspaces/:workspace_id/webhooks/:id.json 웹훅 수정 (이벤트, URL, 활성화, 시크릿 교체) webhooks_update

권한: workspace.manage

예시
curl -X PATCH https://privatusanalytics.com/workspaces/:workspace_id/webhooks/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "HTTPS 엔드포인트"
    },
    "events": {
      "type": "array",
      "items": {
        "type": "string",
        "enum": [
          "alert.triggered",
          "alert.resolved",
          "goal.completed_threshold",
          "uptime.down",
          "uptime.up",
          "export.ready",
          "import.completed",
          "import.failed",
          "site.created",
          "site.deleted",
          "member.added",
          "usage.threshold"
        ]
      },
      "description": "보낼 이벤트"
    },
    "enabled": {
      "type": "boolean",
      "description": "전송 활성화"
    },
    "rotate_secret": {
      "type": "boolean",
      "description": "서명 시크릿 교체",
      "default": false
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "workspace_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "웹훅 ID, 예: wh_7Q2K9XH3AB"
    },
    "url": {
      "type": "string"
    },
    "events": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "enabled": {
      "type": "boolean"
    },
    "status": {
      "type": "string",
      "description": "active, failing 또는 disabled"
    },
    "secret": {
      "type": "string",
      "description": "Privatus-Signature용 서명 시크릿"
    },
    "consecutive_failures": {
      "type": "integer"
    },
    "last_success_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_failure_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

이메일 리포트

DELETE /recipients/:id.json 이메일 리포트에서 수신자 제거 email_report_recipients_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/recipients/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
    },
    "email": {
      "type": "string",
      "description": "주소"
    },
    "status": {
      "type": "string",
      "description": "active, pending, declined 또는 unsubscribed"
    },
    "invited_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "마지막 초대를 보낸 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "대기 중인 초대가 만료되는 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "confirmed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "주소가 active가 된 시각"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
GET /reports/:report_id/recipients.json 이메일 리포트의 수신자와 상태 목록 보기 email_report_recipients_list

상태: active (리포트 수신), pending (초대됨, 아직 수락하지 않음), declined 또는 unsubscribed. 주소는 리포트의 수신자 목록에서 추가하거나 제거하세요.

권한: analytics.read

예시
curl https://privatusanalytics.com/reports/:report_id/recipients.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "이 상태의 수신자만",
      "enum": [
        "pending",
        "active",
        "declined",
        "unsubscribed"
      ]
    },
    "report_id": {
      "type": "string",
      "description": "리소스의 Report"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "report_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
      },
      "email": {
        "type": "string",
        "description": "주소"
      },
      "status": {
        "type": "string",
        "description": "active, pending, declined 또는 unsubscribed"
      },
      "invited_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time",
            "description": "마지막 초대를 보낸 시각"
          },
          {
            "type": "null"
          }
        ]
      },
      "expires_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time",
            "description": "대기 중인 초대가 만료되는 시각"
          },
          {
            "type": "null"
          }
        ]
      },
      "confirmed_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time",
            "description": "주소가 active가 된 시각"
          },
          {
            "type": "null"
          }
        ]
      }
    }
  }
}
POST /recipients/:id/resend.json 대기 중인 리포트 초대 다시 보내기 email_report_recipients_resend

새 링크로 초대를 다시 보냅니다. 리포트당 주소별로 7일에 한 번 가능합니다.

권한: content.write

예시
curl -X POST https://privatusanalytics.com/recipients/:id/resend.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
    },
    "email": {
      "type": "string",
      "description": "주소"
    },
    "status": {
      "type": "string",
      "description": "active, pending, declined 또는 unsubscribed"
    },
    "invited_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "마지막 초대를 보낸 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "대기 중인 초대가 만료되는 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "confirmed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "주소가 active가 된 시각"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /workspaces/:workspace_id/reports.json 이메일 리포트 만들기 email_reports_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/workspaces/:workspace_id/reports.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "리포트에 포함할 사이트 ID (pa_…)"
    },
    "frequency": {
      "type": "string",
      "description": "daily, weekly (요일 지정) 또는 monthly (1일)",
      "enum": [
        "daily",
        "weekly",
        "monthly"
      ]
    },
    "hour": {
      "type": "integer",
      "description": "발송 시각 (0에서 23, 워크스페이스 시간대)"
    },
    "weekday": {
      "type": "integer",
      "description": "주간 리포트: 0 = 일요일 … 6 = 토요일"
    },
    "recipients": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이메일 주소 (계정 불필요). 쉼표나 줄바꿈으로 구분할 수 있습니다. 워크스페이스 멤버는 즉시 추가됩니다. 그 외의 사람은 초대를 받고 수락한 뒤에만 리포트를 받습니다. 리포트 수신을 거부한 주소는 거절됩니다"
    },
    "blocks": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "내용: kpis, chart, pages, sources, goals, campaigns, vitals, uptime"
    },
    "attach_pdf": {
      "type": "boolean",
      "description": "PDF 버전 첨부"
    },
    "intro": {
      "type": "string",
      "description": "사용자 지정 소개 문구 (최대 2000자)"
    },
    "enabled": {
      "type": "boolean",
      "description": "일정에 따라 발송"
    },
    "name": {
      "type": "string",
      "description": "리포트 이름",
      "examples": [
        "Weekly traffic"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리포트 ID, 예: rep_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "리포트에 포함된 사이트 ID"
    },
    "frequency": {
      "type": "string",
      "description": "daily, weekly 또는 monthly"
    },
    "hour": {
      "type": "integer",
      "description": "발송 시각 (워크스페이스 시간대)"
    },
    "weekday": {
      "type": "integer",
      "description": "주간: 0 = 일요일 … 6 = 토요일"
    },
    "recipients": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "상태와 관계없이 리포트에 있는 모든 주소"
    },
    "recipient_details": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
          },
          "email": {
            "type": "string",
            "description": "주소"
          },
          "status": {
            "type": "string",
            "description": "active, pending, declined 또는 unsubscribed"
          },
          "invited_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "마지막 초대를 보낸 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "대기 중인 초대가 만료되는 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "confirmed_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "주소가 active가 된 시각"
              },
              {
                "type": "null"
              }
            ]
          }
        }
      },
      "description": "각 수신자와 수신 동의 상태 (active 수신자만 리포트를 받음)"
    },
    "blocks": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "콘텐츠 블록"
    },
    "attach_pdf": {
      "type": "boolean"
    },
    "intro": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "enabled": {
      "type": "boolean"
    },
    "last_sent_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /reports/:id/deliveries.json 이메일 리포트의 발송 로그 email_reports_deliveries

권한: analytics.read

예시
curl https://privatusanalytics.com/reports/:id/deliveries.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "이 상태의 발송만",
      "enum": [
        "sent",
        "test",
        "failed",
        "skipped"
      ]
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "status": {
        "type": "string",
        "description": "sent, test, failed 또는 skipped"
      },
      "recipients_count": {
        "type": "integer"
      },
      "error": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "sent_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
DELETE /reports/:id.json 이메일 리포트 삭제 email_reports_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/reports/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리포트 ID, 예: rep_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "리포트에 포함된 사이트 ID"
    },
    "frequency": {
      "type": "string",
      "description": "daily, weekly 또는 monthly"
    },
    "hour": {
      "type": "integer",
      "description": "발송 시각 (워크스페이스 시간대)"
    },
    "weekday": {
      "type": "integer",
      "description": "주간: 0 = 일요일 … 6 = 토요일"
    },
    "recipients": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "상태와 관계없이 리포트에 있는 모든 주소"
    },
    "recipient_details": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
          },
          "email": {
            "type": "string",
            "description": "주소"
          },
          "status": {
            "type": "string",
            "description": "active, pending, declined 또는 unsubscribed"
          },
          "invited_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "마지막 초대를 보낸 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "대기 중인 초대가 만료되는 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "confirmed_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "주소가 active가 된 시각"
              },
              {
                "type": "null"
              }
            ]
          }
        }
      },
      "description": "각 수신자와 수신 동의 상태 (active 수신자만 리포트를 받음)"
    },
    "blocks": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "콘텐츠 블록"
    },
    "attach_pdf": {
      "type": "boolean"
    },
    "intro": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "enabled": {
      "type": "boolean"
    },
    "last_sent_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /workspaces/:workspace_id/reports.json 이메일 리포트 목록 보기 email_reports_list

권한: analytics.read

예시
curl https://privatusanalytics.com/workspaces/:workspace_id/reports.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "frequency": {
      "type": "string",
      "description": "이 주기의 리포트만",
      "enum": [
        "daily",
        "weekly",
        "monthly"
      ]
    },
    "workspace_id": {
      "type": "string",
      "description": "워크스페이스 ID, 예: ws_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "workspace_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "리포트 ID, 예: rep_7Q2K9XH3AB"
      },
      "name": {
        "type": "string"
      },
      "site_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "리포트에 포함된 사이트 ID"
      },
      "frequency": {
        "type": "string",
        "description": "daily, weekly 또는 monthly"
      },
      "hour": {
        "type": "integer",
        "description": "발송 시각 (워크스페이스 시간대)"
      },
      "weekday": {
        "type": "integer",
        "description": "주간: 0 = 일요일 … 6 = 토요일"
      },
      "recipients": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "상태와 관계없이 리포트에 있는 모든 주소"
      },
      "recipient_details": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
            },
            "email": {
              "type": "string",
              "description": "주소"
            },
            "status": {
              "type": "string",
              "description": "active, pending, declined 또는 unsubscribed"
            },
            "invited_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "마지막 초대를 보낸 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "expires_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "대기 중인 초대가 만료되는 시각"
                },
                {
                  "type": "null"
                }
              ]
            },
            "confirmed_at": {
              "anyOf": [
                {
                  "type": "string",
                  "format": "date-time",
                  "description": "주소가 active가 된 시각"
                },
                {
                  "type": "null"
                }
              ]
            }
          }
        },
        "description": "각 수신자와 수신 동의 상태 (active 수신자만 리포트를 받음)"
      },
      "blocks": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "콘텐츠 블록"
      },
      "attach_pdf": {
        "type": "boolean"
      },
      "intro": {
        "anyOf": [
          {
            "type": "string"
          },
          {
            "type": "null"
          }
        ]
      },
      "enabled": {
        "type": "boolean"
      },
      "last_sent_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "next_run_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
POST /reports/:id/send_test.json 이메일 리포트를 테스트로 지금 보내기 email_reports_send_test

권한: content.write

예시
curl -X POST https://privatusanalytics.com/reports/:id/send_test.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "recipient": {
      "type": "string",
      "description": "테스트를 여기로 보내기 (기본값: 내 이메일)"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "sent, test, failed 또는 skipped"
    },
    "recipients_count": {
      "type": "integer"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "sent_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /reports/:id.json 이메일 리포트 조회 email_reports_get

권한: analytics.read

예시
curl https://privatusanalytics.com/reports/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리포트 ID, 예: rep_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "리포트에 포함된 사이트 ID"
    },
    "frequency": {
      "type": "string",
      "description": "daily, weekly 또는 monthly"
    },
    "hour": {
      "type": "integer",
      "description": "발송 시각 (워크스페이스 시간대)"
    },
    "weekday": {
      "type": "integer",
      "description": "주간: 0 = 일요일 … 6 = 토요일"
    },
    "recipients": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "상태와 관계없이 리포트에 있는 모든 주소"
    },
    "recipient_details": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
          },
          "email": {
            "type": "string",
            "description": "주소"
          },
          "status": {
            "type": "string",
            "description": "active, pending, declined 또는 unsubscribed"
          },
          "invited_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "마지막 초대를 보낸 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "대기 중인 초대가 만료되는 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "confirmed_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "주소가 active가 된 시각"
              },
              {
                "type": "null"
              }
            ]
          }
        }
      },
      "description": "각 수신자와 수신 동의 상태 (active 수신자만 리포트를 받음)"
    },
    "blocks": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "콘텐츠 블록"
    },
    "attach_pdf": {
      "type": "boolean"
    },
    "intro": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "enabled": {
      "type": "boolean"
    },
    "last_sent_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /reports/:id.json 이메일 리포트 수정 email_reports_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/reports/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "리포트에 포함할 사이트 ID (pa_…)"
    },
    "frequency": {
      "type": "string",
      "description": "daily, weekly (요일 지정) 또는 monthly (1일)",
      "enum": [
        "daily",
        "weekly",
        "monthly"
      ]
    },
    "hour": {
      "type": "integer",
      "description": "발송 시각 (0에서 23, 워크스페이스 시간대)"
    },
    "weekday": {
      "type": "integer",
      "description": "주간 리포트: 0 = 일요일 … 6 = 토요일"
    },
    "recipients": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이메일 주소 (계정 불필요). 쉼표나 줄바꿈으로 구분할 수 있습니다. 워크스페이스 멤버는 즉시 추가됩니다. 그 외의 사람은 초대를 받고 수락한 뒤에만 리포트를 받습니다. 리포트 수신을 거부한 주소는 거절됩니다"
    },
    "blocks": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "내용: kpis, chart, pages, sources, goals, campaigns, vitals, uptime"
    },
    "attach_pdf": {
      "type": "boolean",
      "description": "PDF 버전 첨부"
    },
    "intro": {
      "type": "string",
      "description": "사용자 지정 소개 문구 (최대 2000자)"
    },
    "enabled": {
      "type": "boolean",
      "description": "일정에 따라 발송"
    },
    "name": {
      "type": "string",
      "description": "리포트 이름"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "리포트 ID, 예: rep_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "site_ids": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "리포트에 포함된 사이트 ID"
    },
    "frequency": {
      "type": "string",
      "description": "daily, weekly 또는 monthly"
    },
    "hour": {
      "type": "integer",
      "description": "발송 시각 (워크스페이스 시간대)"
    },
    "weekday": {
      "type": "integer",
      "description": "주간: 0 = 일요일 … 6 = 토요일"
    },
    "recipients": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "상태와 관계없이 리포트에 있는 모든 주소"
    },
    "recipient_details": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
          },
          "email": {
            "type": "string",
            "description": "주소"
          },
          "status": {
            "type": "string",
            "description": "active, pending, declined 또는 unsubscribed"
          },
          "invited_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "마지막 초대를 보낸 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "대기 중인 초대가 만료되는 시각"
              },
              {
                "type": "null"
              }
            ]
          },
          "confirmed_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time",
                "description": "주소가 active가 된 시각"
              },
              {
                "type": "null"
              }
            ]
          }
        }
      },
      "description": "각 수신자와 수신 동의 상태 (active 수신자만 리포트를 받음)"
    },
    "blocks": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "콘텐츠 블록"
    },
    "attach_pdf": {
      "type": "boolean"
    },
    "intro": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "enabled": {
      "type": "boolean"
    },
    "last_sent_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "next_run_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /reports/invites/:token/accept.json 리포트 초대 수락 report_invites_accept

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/reports/invites/:token/accept.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
    },
    "email": {
      "type": "string",
      "description": "주소"
    },
    "status": {
      "type": "string",
      "description": "active, pending, declined 또는 unsubscribed"
    },
    "invited_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "마지막 초대를 보낸 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "대기 중인 초대가 만료되는 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "confirmed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "주소가 active가 된 시각"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /reports/invites/:token/decline.json 리포트 초대 거절 report_invites_decline

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/reports/invites/:token/decline.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "수신자 ID, 예: rcp_7Q2K9XH3AB"
    },
    "email": {
      "type": "string",
      "description": "주소"
    },
    "status": {
      "type": "string",
      "description": "active, pending, declined 또는 unsubscribed"
    },
    "invited_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "마지막 초대를 보낸 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "expires_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "대기 중인 초대가 만료되는 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "confirmed_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "주소가 active가 된 시각"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
POST /reports/resubscribe/:token.json 수신 거부 후 리포트 다시 받기 report_resubscribes_confirm

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/reports/resubscribe/:token.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /reports/unsubscribe/:token/resubscribe.json 리포트를 다시 받을 수 있는 링크를 주소로 이메일 전송 report_resubscribes_create

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/reports/unsubscribe/:token/resubscribe.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /reports/unsubscribe/:token.json 이메일 리포트에서 주소 수신 거부 report_unsubscribes_create

권한: public · HTTP 전용 (MCP 도구 아님)

예시
curl -X POST https://privatusanalytics.com/reports/unsubscribe/:token.json \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "description": "리소스의 Token"
    }
  },
  "required": [
    "token"
  ]
}
응답 데이터
{
  "type": "object"
}

이벤트

GET /sites/:site_id/events/properties.json 최근 30일 동안 확인된 이벤트 속성 키 목록 보기 event_properties_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/events/properties.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "event": {
      "type": "string",
      "description": "이 원본 이벤트 이름에서 확인된 키만"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
PATCH /sites/:site_id/events/properties.json 이벤트 속성 키 이름 변경 또는 숨기기 event_properties_update

권한: sites.manage

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/events/properties.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "key": {
      "type": "string",
      "description": "저장된 그대로의 속성 키, 예: plan"
    },
    "display_name": {
      "type": "string",
      "description": "대신 표시할 라벨 (비우면 삭제)"
    },
    "hidden": {
      "type": "boolean",
      "description": "리포트에서 이 키 숨기기"
    },
    "export_safe": {
      "type": "boolean",
      "description": "이 키에는 개인 데이터가 없으므로 원시 내보내기와 웨어하우스 동기화에 포함됨"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "key",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
DELETE /sites/:site_id/events.json 이벤트와 그 기록 삭제 (백그라운드에서 실행되며 이름을 입력해 확인) events_delete

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/events.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "삭제할 원본 이벤트 이름"
    },
    "confirm": {
      "type": "string",
      "description": "확인을 위해 이벤트 이름을 다시 입력하세요"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "confirm",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/events.json 완료 수, 방문 수, 전환율, 처음 및 마지막 확인 시점이 포함된 이벤트 목록 보기 events_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/events.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "search": {
      "type": "string",
      "description": "이름에 이 텍스트가 포함된 이벤트만"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
POST /sites/:site_id/events/merge.json 여러 이벤트를 하나의 표시 이름으로 병합 events_merge

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/events/merge.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "names": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "병합할 원본 이벤트 이름"
    },
    "into": {
      "type": "string",
      "description": "병합된 이벤트의 표시 이름",
      "examples": [
        "Signup"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "names",
    "into",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "트래커가 보낸 원본 이벤트 이름"
    },
    "display_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "리포트에 표시되는 이름"
        },
        {
          "type": "null"
        }
      ]
    },
    "hidden": {
      "type": "boolean",
      "description": "리포트에서 숨김"
    },
    "currency": {
      "anyOf": [
        {
          "type": "string",
          "description": "매출 통화"
        },
        {
          "type": "null"
        }
      ]
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/events/detail.json 이벤트 하나: 차트, 속성 피벗, 숫자 속성 집계, 페이지, 소스 events_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/events/detail.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "name": {
      "type": "string",
      "description": "표시되는 이벤트 이름 (이름 변경 후)",
      "examples": [
        "Signup"
      ]
    },
    "properties": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "피벗 기준으로 삼을 속성 키 최대 3개",
      "default": []
    },
    "interval": {
      "type": "string",
      "description": "차트 구간 크기",
      "enum": [
        "auto",
        "minute",
        "hour",
        "day",
        "week",
        "month",
        "quarter",
        "year"
      ],
      "default": "auto"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
PATCH /sites/:site_id/events/settings.json 이벤트 이름 변경, 숨기기 또는 숨기기 해제, 통화 설정 events_update

권한: sites.manage

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/events/settings.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "트래커가 보낸 원본 이벤트 이름",
      "examples": [
        "signup_click"
      ]
    },
    "display_name": {
      "type": "string",
      "description": "대신 표시할 이름 (비우면 이름 변경 해제)"
    },
    "hidden": {
      "type": "boolean",
      "description": "리포트에서 숨기기 (데이터는 유지됨)"
    },
    "currency": {
      "type": "string",
      "description": "이 이벤트의 매출 통화 (ISO 4217)"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "트래커가 보낸 원본 이벤트 이름"
    },
    "display_name": {
      "anyOf": [
        {
          "type": "string",
          "description": "리포트에 표시되는 이름"
        },
        {
          "type": "null"
        }
      ]
    },
    "hidden": {
      "type": "boolean",
      "description": "리포트에서 숨김"
    },
    "currency": {
      "anyOf": [
        {
          "type": "string",
          "description": "매출 통화"
        },
        {
          "type": "null"
        }
      ]
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

제휴 프로그램

GET /account/affiliate/commissions.json 제휴 수수료 목록 보기 affiliate_commissions_list

수수료, 환불 및 지불 거절에 따른 회수와 그 취소를 최신순으로 보여 줍니다. 금액은 센트 단위입니다.

권한: member

예시
curl https://privatusanalytics.com/account/affiliate/commissions.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "이 상태의 수수료만",
      "enum": [
        "pending",
        "approved",
        "paid",
        "void"
      ]
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": []
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid",
        "description": "수수료 ID"
      },
      "kind": {
        "type": "string",
        "description": "commission, clawback (환불 또는 지불 거절) 또는 reversal"
      },
      "status": {
        "type": "string",
        "description": "pending (보류 중), approved (지급 가능), paid 또는 void"
      },
      "amount_cents": {
        "type": "integer",
        "description": "센트 단위의 내 몫 (회수인 경우 음수)"
      },
      "basis_cents": {
        "type": "integer",
        "description": "계산의 기준이 된 순 결제액 (세금 제외), 센트 단위"
      },
      "currency": {
        "type": "string",
        "description": "ISO 통화 코드"
      },
      "earned_at": {
        "type": "string",
        "format": "date-time",
        "description": "결제 (또는 환불)가 발생한 시각"
      },
      "approved_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time",
            "description": "지급 가능해진 시각"
          },
          {
            "type": "null"
          }
        ]
      },
      "paid_at": {
        "anyOf": [
          {
            "type": "string",
            "format": "date-time",
            "description": "지급된 시각"
          },
          {
            "type": "null"
          }
        ]
      }
    }
  }
}
GET /account/affiliate.json 제휴 상태, 추천 링크, 통계 조회 affiliate_get

제휴 신청 상태, 추천 링크, 소개한 가입과 결제 고객, 통화별 잔액 (보류 중, 지급 가능, 지급 완료)입니다. 신청하지 않았다면 status는 none입니다.

권한: member

예시
curl https://privatusanalytics.com/account/affiliate.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {},
  "required": []
}
응답 데이터
{
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "description": "none (신청하지 않음), pending, approved, rejected 또는 suspended"
    },
    "code": {
      "anyOf": [
        {
          "type": "string",
          "description": "내 추천 코드"
        },
        {
          "type": "null"
        }
      ]
    },
    "referral_url": {
      "anyOf": [
        {
          "type": "string",
          "description": "공유할 링크 (승인된 제휴 회원만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "payout_method": {
      "anyOf": [
        {
          "type": "string",
          "description": "wise 또는 credit"
        },
        {
          "type": "null"
        }
      ]
    },
    "rejection_reason": {
      "anyOf": [
        {
          "type": "string",
          "description": "마지막 신청이 거절된 이유"
        },
        {
          "type": "null"
        }
      ]
    },
    "applied_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "신청한 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "approved_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "description": "신청이 승인된 시각"
        },
        {
          "type": "null"
        }
      ]
    },
    "credit_blocked": {
      "anyOf": [
        {
          "type": "string",
          "description": "계정 크레딧이 대기 중인 이유: program (워크스페이스가 할인 프로그램에 속함), no_subscription 또는 no_workspace. 막는 것이 없으면 null"
        },
        {
          "type": "null"
        }
      ]
    },
    "signups": {
      "type": "integer",
      "description": "내 링크나 코드를 통해 만들어진 계정"
    },
    "customers": {
      "type": "integer",
      "description": "소개한 워크스페이스 중 결제한 곳"
    },
    "balances": {
      "type": "array",
      "description": "통화별: pending_cents (보류 중), approved_cents (지급 가능), paid_cents"
    },
    "payouts": {
      "type": "array",
      "description": "최근 지급 내역으로 amount_cents, currency, payout_method, status (applied: 다음 갱신을 기다리는 계정 크레딧, 또는 paid), applied_at, paid_at을 포함"
    },
    "terms": {
      "type": "object",
      "description": "수수료 비율, 개월 수, 보류 일수, 센트 단위의 Wise 지급 기준액"
    }
  }
}

채널 규칙

POST /sites/:site_id/channel_rules.json 채널 규칙 추가 channel_rules_create

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/channel_rules.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "channel": {
      "type": "string",
      "description": "지정할 채널 이름, 예: Partners"
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        }
      },
      "description": "모두 일치해야 하는 조건: [{\"field\": \"utm_source\", \"operator\": \"is\", \"value\": \"newsletter\"}]. 필드: referrer_host, utm_source, utm_medium, utm_campaign, ref, path. 연산자: is, contains, starts_with, regex."
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "channel",
    "conditions",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "channel": {
      "type": "string",
      "description": "모든 조건이 일치할 때 지정되는 채널"
    },
    "position": {
      "type": "integer",
      "description": "평가 순서 (먼저 일치하는 규칙이 우선)"
    },
    "conditions": {
      "type": "array",
      "description": "조건: field, operator, value"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/channel_rules/:id.json 채널 규칙 삭제 channel_rules_delete

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/channel_rules/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "channel": {
      "type": "string",
      "description": "모든 조건이 일치할 때 지정되는 채널"
    },
    "position": {
      "type": "integer",
      "description": "평가 순서 (먼저 일치하는 규칙이 우선)"
    },
    "conditions": {
      "type": "array",
      "description": "조건: field, operator, value"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/channel_rules.json 채널 규칙을 순서대로 목록 보기 channel_rules_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/channel_rules.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "channel": {
      "type": "string",
      "description": "모든 조건이 일치할 때 지정되는 채널"
    },
    "position": {
      "type": "integer",
      "description": "평가 순서 (먼저 일치하는 규칙이 우선)"
    },
    "conditions": {
      "type": "array",
      "description": "조건: field, operator, value"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
PATCH /sites/:site_id/channel_rules/:id/move.json 채널 규칙을 위나 아래로 이동 channel_rules_move

권한: sites.manage

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/channel_rules/:id/move.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "direction": {
      "type": "string",
      "description": "규칙을 이동할 방향",
      "enum": [
        "up",
        "down",
        "top",
        "bottom"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "direction",
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "channel": {
      "type": "string",
      "description": "모든 조건이 일치할 때 지정되는 채널"
    },
    "position": {
      "type": "integer",
      "description": "평가 순서 (먼저 일치하는 규칙이 우선)"
    },
    "conditions": {
      "type": "array",
      "description": "조건: field, operator, value"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/channel_rules/preview.json 샘플 리퍼러와 UTM 태그에 대한 채널 미리 보기 channel_rules_preview

권한: analytics.read

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/channel_rules/preview.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "referrer": {
      "type": "string",
      "description": "리퍼러 URL 또는 호스트명"
    },
    "utm_source": {
      "type": "string",
      "description": "utm_source 값"
    },
    "utm_medium": {
      "type": "string",
      "description": "utm_medium 값"
    },
    "utm_campaign": {
      "type": "string",
      "description": "utm_campaign 값"
    },
    "ref": {
      "type": "string",
      "description": "ref / via / source 매개변수"
    },
    "path": {
      "type": "string",
      "description": "방문 페이지 경로, 예: /pricing"
    },
    "paid_click": {
      "type": "boolean",
      "description": "URL에 gclid 같은 클릭 ID가 있었음",
      "default": false
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
PATCH /sites/:site_id/channel_rules/:id.json 채널 규칙 변경 channel_rules_update

권한: sites.manage

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/channel_rules/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "channel": {
      "type": "string",
      "description": "지정할 채널 이름"
    },
    "conditions": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "field": {
            "type": "string"
          },
          "operator": {
            "type": "string"
          },
          "value": {
            "type": "string"
          }
        }
      },
      "description": "모두 일치해야 하는 조건: [{\"field\": \"utm_source\", \"operator\": \"is\", \"value\": \"newsletter\"}]. 필드: referrer_host, utm_source, utm_medium, utm_campaign, ref, path. 연산자: is, contains, starts_with, regex."
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "channel": {
      "type": "string",
      "description": "모든 조건이 일치할 때 지정되는 채널"
    },
    "position": {
      "type": "integer",
      "description": "평가 순서 (먼저 일치하는 규칙이 우선)"
    },
    "conditions": {
      "type": "array",
      "description": "조건: field, operator, value"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

추적

POST /sites/:site_id/tracking/ingest_key.json 서버 수집 키 만들기 또는 교체 (한 번만 표시됨) tracking_ingest_key_rotate

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/tracking/ingest_key.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID"
    },
    "key": {
      "type": "string",
      "description": "수집 키. 한 번만 표시되므로 지금 저장하세요. POST /api/events에 Bearer 토큰으로 보내세요"
    },
    "prefix": {
      "type": "string",
      "description": "설정에 표시되는 키 접두사"
    }
  }
}
DELETE /sites/:site_id/tracking/ingest_key.json 서버 수집 키 폐기 tracking_ingest_key_revoke

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/tracking/ingest_key.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "추적 스니펫에 사용되는 사이트 ID"
    },
    "workspace_id": {
      "type": "string"
    },
    "domain": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "extra_domains": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "multi_domain_mode": {
      "type": "string"
    },
    "timezone": {
      "type": "string"
    },
    "currency": {
      "type": "string"
    },
    "week_start": {
      "type": "integer"
    },
    "labels": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "honor_dnt": {
      "type": "boolean"
    },
    "honor_gpc": {
      "type": "boolean"
    },
    "pii_scrubber": {
      "type": "boolean"
    },
    "redaction_rules": {
      "type": "array"
    },
    "allowed_params": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "path_masks": {
      "type": "array"
    },
    "retention_months": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ]
    },
    "bot_filtering": {
      "type": "boolean"
    },
    "traffic_rule_modes": {
      "type": "object"
    },
    "vitals_sample_rate": {
      "type": "integer"
    },
    "conversion_denominator": {
      "type": "string"
    },
    "public_dashboard": {
      "type": "boolean"
    },
    "public_indexable": {
      "type": "boolean"
    },
    "ingest_key_prefix": {
      "anyOf": [
        {
          "type": "string",
          "description": "서버 수집 키의 앞부분"
        },
        {
          "type": "null"
        }
      ]
    },
    "verified_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "first_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "last_event_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ]
    },
    "snippet": {
      "type": "string",
      "description": "HTML 추적 스니펫"
    },
    "favorite": {
      "type": "boolean",
      "description": "내가 별표 표시함"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/tracking/verify.json 사이트에 트래커가 설치되었는지 확인 (스크립트 태그, 사이트 ID, CSP, 리퍼러 정책) tracking_verify

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/tracking/verify.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "확인할 페이지 (기본값은 https://<domain>/)"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
GET /sites/:site_id/tracking/snippet.json 선택한 옵션으로 추적 스니펫 만들기 tracking_snippet

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/tracking/snippet.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "modules": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "선택 모듈: auto (외부 링크, 다운로드, 폼, 404), engage (시간과 스크롤), vitals (웹 바이탈), clicks",
      "default": [
        "engage"
      ]
    },
    "manual": {
      "type": "boolean",
      "description": "자동 페이지뷰 끄기",
      "default": false
    },
    "spa": {
      "type": "string",
      "description": "싱글 페이지 앱 이동 추적",
      "enum": [
        "auto",
        "history",
        "hash",
        "off"
      ],
      "default": "auto"
    },
    "domains": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "이 호스트명에서만 추적",
      "default": []
    },
    "exclude": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "추적하지 않을 경로 글롭, 예: /admin/*",
      "default": []
    },
    "query_params": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "추가로 유지할 쿼리 매개변수, 예: page",
      "default": []
    },
    "mask": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "클라이언트 측 경로 마스크, 예: /u/*->/u/:id",
      "default": []
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}

캠페인

POST /sites/:site_id/campaigns/costs.json 월별 캠페인 지출 설정 campaign_costs_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/campaigns/costs.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "campaign": {
      "type": "string",
      "description": "지출이 속한 utm_campaign 값",
      "examples": [
        "spring_sale"
      ]
    },
    "month": {
      "type": "string",
      "description": "월, YYYY-MM",
      "examples": [
        "2026-09"
      ]
    },
    "amount": {
      "type": "number",
      "description": "기본 통화 단위의 지출, 예: 1250.50"
    },
    "currency": {
      "type": "string",
      "description": "ISO 4217 통화 (기본값은 사이트 통화)"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "campaign",
    "month",
    "amount",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "비용 항목 ID"
    },
    "campaign": {
      "type": "string",
      "description": "utm_campaign 값"
    },
    "month": {
      "type": "string",
      "description": "월, YYYY-MM"
    },
    "amount_minor": {
      "type": "integer",
      "description": "최소 단위의 지출"
    },
    "currency": {
      "type": "string",
      "description": "금액의 ISO 4217 통화"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/campaigns/costs/:id.json 캠페인 비용 항목 삭제 campaign_costs_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/campaigns/costs/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "비용 항목 ID"
    },
    "campaign": {
      "type": "string",
      "description": "utm_campaign 값"
    },
    "month": {
      "type": "string",
      "description": "월, YYYY-MM"
    },
    "amount_minor": {
      "type": "integer",
      "description": "최소 단위의 지출"
    },
    "currency": {
      "type": "string",
      "description": "금액의 ISO 4217 통화"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/campaigns/costs/import.json CSV에서 캠페인 비용 가져오기 (campaign,month,amount[,currency]) campaign_costs_import

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/campaigns/costs/import.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "file": {
      "type": "string",
      "format": "binary",
      "description": "CSV 파일 업로드 (멀티파트 폼)"
    },
    "csv": {
      "type": "string",
      "description": "CSV 텍스트: campaign,month,amount[,currency]"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "imported": {
      "type": "integer",
      "description": "저장된 행"
    },
    "failed": {
      "type": "integer",
      "description": "건너뛴 행"
    },
    "errors": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "행을 건너뛴 이유 (처음 50개)"
    }
  }
}
GET /sites/:site_id/campaigns/costs.json 캠페인 비용 항목 목록 보기 campaign_costs_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/campaigns/costs.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "campaign": {
      "type": "string",
      "description": "이 캠페인만"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "page": {
      "type": "integer",
      "description": "페이지 (1부터)"
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 결과 수 (최대 100)"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uuid",
        "description": "비용 항목 ID"
      },
      "campaign": {
        "type": "string",
        "description": "utm_campaign 값"
      },
      "month": {
        "type": "string",
        "description": "월, YYYY-MM"
      },
      "amount_minor": {
        "type": "integer",
        "description": "최소 단위의 지출"
      },
      "currency": {
        "type": "string",
        "description": "금액의 ISO 4217 통화"
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      },
      "updated_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
PATCH /sites/:site_id/campaigns/costs/:id.json 캠페인 비용 항목 변경 campaign_costs_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/campaigns/costs/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "campaign": {
      "type": "string",
      "description": "utm_campaign 값"
    },
    "month": {
      "type": "string",
      "description": "월, YYYY-MM"
    },
    "amount": {
      "type": "number",
      "description": "기본 통화 단위의 지출"
    },
    "currency": {
      "type": "string",
      "description": "ISO 4217 통화"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "비용 항목 ID"
    },
    "campaign": {
      "type": "string",
      "description": "utm_campaign 값"
    },
    "month": {
      "type": "string",
      "description": "월, YYYY-MM"
    },
    "amount_minor": {
      "type": "integer",
      "description": "최소 단위의 지출"
    },
    "currency": {
      "type": "string",
      "description": "금액의 ISO 4217 통화"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/campaigns/builder.json UTM 태그가 붙은 URL 만들기 및 검증 campaigns_builder

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/campaigns/builder.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "destination": {
      "type": "string",
      "description": "방문 페이지 URL (https://…)",
      "examples": [
        "https://example.com/pricing"
      ]
    },
    "preset": {
      "type": "string",
      "description": "비어 있으면 채널에 맞는 utm_source/utm_medium을 채움",
      "enum": [
        "newsletter",
        "social",
        "paid_search",
        "paid_social",
        "print",
        "partner"
      ]
    },
    "utm_source": {
      "type": "string",
      "description": "트래픽이 오는 곳"
    },
    "utm_medium": {
      "type": "string",
      "description": "마케팅 매체, 예: email, cpc"
    },
    "utm_campaign": {
      "type": "string",
      "description": "캠페인 이름, 예: spring_sale"
    },
    "utm_content": {
      "type": "string",
      "description": "변형, 예: header_button"
    },
    "utm_term": {
      "type": "string",
      "description": "유료 검색 키워드"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "url": {
      "anyOf": [
        {
          "type": "string",
          "description": "태그가 붙은 URL (오류가 있으면 null)"
        },
        {
          "type": "null"
        }
      ]
    },
    "valid": {
      "type": "boolean",
      "description": "오류가 없으면 true"
    },
    "destination": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "preset": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "utm_source": {
      "anyOf": [
        {
          "type": "string",
          "description": "정규화된 utm_source"
        },
        {
          "type": "null"
        }
      ]
    },
    "utm_medium": {
      "anyOf": [
        {
          "type": "string",
          "description": "정규화된 utm_medium"
        },
        {
          "type": "null"
        }
      ]
    },
    "utm_campaign": {
      "anyOf": [
        {
          "type": "string",
          "description": "정규화된 utm_campaign"
        },
        {
          "type": "null"
        }
      ]
    },
    "utm_content": {
      "anyOf": [
        {
          "type": "string",
          "description": "정규화된 utm_content"
        },
        {
          "type": "null"
        }
      ]
    },
    "utm_term": {
      "anyOf": [
        {
          "type": "string",
          "description": "정규화된 utm_term"
        },
        {
          "type": "null"
        }
      ]
    },
    "issues": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "field, level (error 또는 warning), message"
    },
    "presets": {
      "type": "object",
      "description": "채널 프리셋: 프리셋별 utm_source/utm_medium"
    }
  }
}
GET /sites/:site_id/campaigns/hygiene.json UTM 정리 상태: 거의 중복된 값, 스타일 문제, 알 수 없는 소스 campaigns_hygiene

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/campaigns/hygiene.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "period": {
      "type": "object",
      "description": "기간의 from/to (UTC)"
    },
    "duplicates": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "거의 중복된 값: field, suggestion, variants [{value, visits}]"
    },
    "style_issues": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "소문자와 밑줄 형식이 아닌 값: field, value, visits, suggestion"
    },
    "unknown_sources": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "인식하지 못한 utm_source 값: value, visits"
    }
  }
}
GET /sites/:site_id/campaigns.json 전환, 매출, 비용, CPA, ROAS가 포함된 캠페인 요약 campaigns_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/campaigns.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "goal_id": {
      "type": "string",
      "description": "전환을 집계할 목표 (goal_…). 기본값은 첫 번째 활성 목표"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "period": {
      "type": "object",
      "description": "기간의 from/to (UTC)"
    },
    "currency": {
      "type": "string",
      "description": "매출과 비용의 사이트 통화"
    },
    "goal_id": {
      "anyOf": [
        {
          "type": "string",
          "description": "전환으로 집계한 목표"
        },
        {
          "type": "null"
        }
      ]
    },
    "goal_name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "campaigns": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "utm_campaign별: visitors, visits, conversions, conversion_rate, revenue, cost, cpa (최소 단위), roas (매출 ÷ 비용), sources [{source, medium, visitors, visits, conversions, conversion_rate, revenue}]"
    },
    "totals": {
      "type": "object",
      "description": "나열된 모든 캠페인의 합계"
    }
  }
}

크롤러

GET /sites/:site_id/crawlers.json AI 크롤러 리포트: 시간별 크롤러 히트, 크롤러별 상위 경로, 카테고리별 crawlers_report

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/crawlers.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "category": {
      "type": "string",
      "description": "ai, search, seo, other 또는 all",
      "enum": [
        "all",
        "ai",
        "search",
        "seo",
        "other"
      ],
      "default": "ai"
    },
    "crawler": {
      "type": "string",
      "description": "이 크롤러만, 예: GPTBot"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}

트래픽 규칙

POST /sites/:site_id/traffic_rules.json 트래픽 규칙 추가 traffic_rules_create

권한: sites.manage

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/traffic_rules.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "list": {
      "type": "string",
      "description": "hostnames, paths, referrers, countries, ip_ranges, user_agents 또는 events",
      "enum": [
        "hostnames",
        "paths",
        "referrers",
        "countries",
        "ip_ranges",
        "user_agents",
        "events"
      ]
    },
    "pattern": {
      "type": "string",
      "description": "일치시킬 값. *는 와일드카드입니다. ip_ranges는 IP 또는 CIDR (v4/v6), countries는 ISO 코드를 받습니다",
      "examples": [
        "/admin/*"
      ]
    },
    "label": {
      "type": "string",
      "description": "선택 메모, 예: \"사무실\""
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "list",
    "pattern",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "list": {
      "type": "string",
      "description": "hostnames, paths, referrers, countries, ip_ranges, user_agents 또는 events"
    },
    "pattern": {
      "type": "string",
      "description": "패턴 (* 와일드카드, ip_ranges는 CIDR)"
    },
    "label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "mode": {
      "type": "string",
      "description": "block 또는 allow (해당 목록의 모드)"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/traffic_rules/:id.json 트래픽 규칙 삭제 traffic_rules_delete

권한: sites.manage

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/traffic_rules/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "list": {
      "type": "string",
      "description": "hostnames, paths, referrers, countries, ip_ranges, user_agents 또는 events"
    },
    "pattern": {
      "type": "string",
      "description": "패턴 (* 와일드카드, ip_ranges는 CIDR)"
    },
    "label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "mode": {
      "type": "string",
      "description": "block 또는 allow (해당 목록의 모드)"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/traffic_rules.json 트래픽 규칙 목록 보기 traffic_rules_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/traffic_rules.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "list": {
      "type": "string",
      "description": "이 목록의 규칙만",
      "enum": [
        "hostnames",
        "paths",
        "referrers",
        "countries",
        "ip_ranges",
        "user_agents",
        "events"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "list": {
      "type": "string",
      "description": "hostnames, paths, referrers, countries, ip_ranges, user_agents 또는 events"
    },
    "pattern": {
      "type": "string",
      "description": "패턴 (* 와일드카드, ip_ranges는 CIDR)"
    },
    "label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "mode": {
      "type": "string",
      "description": "block 또는 allow (해당 목록의 모드)"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
POST /sites/:site_id/traffic_rules/test.json 사이트의 현재 규칙에서 히트가 집계될지 테스트 traffic_rules_test

권한: analytics.read

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/traffic_rules/test.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "url": {
      "type": "string",
      "description": "페이지 URL, 예: https://example.com/a"
    },
    "referrer": {
      "type": "string",
      "description": "리퍼러 URL 또는 호스트명"
    },
    "country": {
      "type": "string",
      "description": "ISO 국가 코드, 예: US"
    },
    "ip": {
      "type": "string",
      "description": "ip_ranges와 비교해 테스트할 IP 주소 (저장되지 않음)"
    },
    "user_agent": {
      "type": "string",
      "description": "User-Agent 문자열 (수집 때처럼 브라우저와 주 버전으로 축약됨)"
    },
    "event": {
      "type": "string",
      "description": "사용자 지정 이벤트 이름"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "object"
}
PATCH /sites/:site_id/traffic_rules/:id.json 트래픽 규칙 변경 traffic_rules_update

권한: sites.manage

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/traffic_rules/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "pattern": {
      "type": "string",
      "description": "새 패턴"
    },
    "label": {
      "type": "string",
      "description": "새 라벨"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid",
      "description": "규칙 ID"
    },
    "list": {
      "type": "string",
      "description": "hostnames, paths, referrers, countries, ip_ranges, user_agents 또는 events"
    },
    "pattern": {
      "type": "string",
      "description": "패턴 (* 와일드카드, ip_ranges는 CIDR)"
    },
    "label": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "mode": {
      "type": "string",
      "description": "block 또는 allow (해당 목록의 모드)"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}

퍼널

POST /sites/:site_id/funnels.json 퍼널 만들기 funnels_create

권한: content.write

예시
curl -X POST https://privatusanalytics.com/sites/:site_id/funnels.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "퍼널 이름",
      "examples": [
        "Signup flow"
      ]
    },
    "steps": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true
      },
      "description": "순서대로 나열한 단계 (2개에서 요금제 한도까지): [{\"type\": \"page|event|goal\", \"value\": \"/pricing | Signup | goal_…\", \"match\": \"exact|prefix|glob|regex\" (page 단계), \"name\": \"optional label\"}]"
    },
    "order_mode": {
      "type": "string",
      "description": "strict: 이 순서대로, any: 순서 무관",
      "enum": [
        "strict",
        "any"
      ],
      "default": "strict"
    },
    "window": {
      "type": "string",
      "description": "전환 기간: visit, 또는 day (방문 안에서 측정하며 UTC 하루를 넘지 않음)",
      "enum": [
        "visit",
        "day"
      ],
      "default": "visit"
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "name",
    "steps",
    "site_id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "퍼널 ID, 예: fun_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "steps": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "단계: {type: page|event|goal, value, match, name}"
    },
    "order_mode": {
      "type": "string",
      "description": "strict 또는 any"
    },
    "window": {
      "type": "string",
      "description": "visit 또는 day"
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "entered": {
              "type": "integer",
              "description": "1단계에 도달한 방문"
            },
            "completed": {
              "type": "integer",
              "description": "마지막 단계에 도달한 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "완료 ÷ 진입, %"
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
DELETE /sites/:site_id/funnels/:id.json 퍼널 삭제 funnels_delete

권한: content.write

예시
curl -X DELETE https://privatusanalytics.com/sites/:site_id/funnels/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "퍼널 ID, 예: fun_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "steps": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "단계: {type: page|event|goal, value, match, name}"
    },
    "order_mode": {
      "type": "string",
      "description": "strict 또는 any"
    },
    "window": {
      "type": "string",
      "description": "visit 또는 day"
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "entered": {
              "type": "integer",
              "description": "1단계에 도달한 방문"
            },
            "completed": {
              "type": "integer",
              "description": "마지막 단계에 도달한 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "완료 ÷ 진입, %"
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}
GET /sites/:site_id/funnels.json 진입 수, 완료 수, 비율이 포함된 퍼널 목록 보기 funnels_list

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/funnels.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "page": {
      "type": "integer",
      "description": "페이지 번호",
      "default": 1
    },
    "per_page": {
      "type": "integer",
      "description": "페이지당 퍼널 수 (최대 100)",
      "default": 25
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    }
  },
  "required": [
    "site_id"
  ]
}
응답 데이터
{
  "type": "array",
  "items": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "description": "퍼널 ID, 예: fun_7Q2K9XH3AB"
      },
      "name": {
        "type": "string"
      },
      "steps": {
        "type": "array",
        "items": {
          "type": "object"
        },
        "description": "단계: {type: page|event|goal, value, match, name}"
      },
      "order_mode": {
        "type": "string",
        "description": "strict 또는 any"
      },
      "window": {
        "type": "string",
        "description": "visit 또는 day"
      },
      "stats": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "entered": {
                "type": "integer",
                "description": "1단계에 도달한 방문"
              },
              "completed": {
                "type": "integer",
                "description": "마지막 단계에 도달한 방문"
              },
              "conversion_rate": {
                "type": "number",
                "description": "완료 ÷ 진입, %"
              }
            },
            "description": "기간 통계 (목록에서만)"
          },
          {
            "type": "null"
          }
        ]
      },
      "created_at": {
        "type": "string",
        "format": "date-time"
      },
      "updated_at": {
        "type": "string",
        "format": "date-time"
      }
    }
  }
}
GET /sites/:site_id/funnels/:id.json 퍼널 리포트: 단계별 수, 전환, 이탈, 단계 사이 시간, 대신 방문이 이동한 곳 funnels_get

권한: analytics.read

예시
curl https://privatusanalytics.com/sites/:site_id/funnels/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN"
입력
{
  "type": "object",
  "properties": {
    "period": {
      "type": "string",
      "description": "날짜 범위 프리셋. from/to와 함께 custom 사용",
      "enum": [
        "today",
        "yesterday",
        "24h",
        "7d",
        "14d",
        "28d",
        "30d",
        "90d",
        "mtd",
        "last_month",
        "qtd",
        "last_quarter",
        "ytd",
        "12mo",
        "last_year",
        "all",
        "custom"
      ],
      "default": "30d"
    },
    "from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 시작 (사이트 시간대)"
    },
    "to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 범위 종료 (포함)"
    },
    "compare": {
      "type": "string",
      "description": "비교 기간",
      "enum": [
        "none",
        "previous_period",
        "previous_year",
        "custom"
      ],
      "default": "none"
    },
    "compare_from": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 시작"
    },
    "compare_to": {
      "type": "string",
      "format": "date",
      "description": "사용자 지정 비교 종료"
    },
    "match_weekday": {
      "type": "boolean",
      "description": "비교 기간의 요일을 맞춤",
      "default": false
    },
    "filters": {
      "type": "array",
      "items": {},
      "description": "필터: [[\"dimension\",\"operator\",\"value\"], …]. 연산자: is, is_not, any_of, none_of, contains, not_contains, starts_with, regex, not_regex, gt, lt, between. OR 조건은 {\"any\": [...]}로 감싸세요.",
      "default": []
    },
    "segment_id": {
      "type": "string",
      "description": "저장된 세그먼트 적용 (seg_…)"
    },
    "include_imported": {
      "type": "boolean",
      "description": "가져온 과거 데이터 추가 (첫 네이티브 이벤트 이전 날짜, 필터나 세그먼트를 적용하면 무시됨)",
      "default": false
    },
    "breakdown": {
      "type": "string",
      "description": "방문 차원으로 단계별 수를 나눔",
      "enum": [
        "channel",
        "device",
        "country",
        "utm_campaign",
        "utm_source",
        "browser",
        "os"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "period": {
      "type": "object",
      "description": "기간의 from/to (UTC)"
    },
    "funnel": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "퍼널 ID, 예: fun_7Q2K9XH3AB"
        },
        "name": {
          "type": "string"
        },
        "steps": {
          "type": "array",
          "items": {
            "type": "object"
          },
          "description": "단계: {type: page|event|goal, value, match, name}"
        },
        "order_mode": {
          "type": "string",
          "description": "strict 또는 any"
        },
        "window": {
          "type": "string",
          "description": "visit 또는 day"
        },
        "stats": {
          "anyOf": [
            {
              "type": "object",
              "properties": {
                "entered": {
                  "type": "integer",
                  "description": "1단계에 도달한 방문"
                },
                "completed": {
                  "type": "integer",
                  "description": "마지막 단계에 도달한 방문"
                },
                "conversion_rate": {
                  "type": "number",
                  "description": "완료 ÷ 진입, %"
                }
              },
              "description": "기간 통계 (목록에서만)"
            },
            {
              "type": "null"
            }
          ]
        },
        "created_at": {
          "type": "string",
          "format": "date-time"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time"
        }
      },
      "description": "퍼널 정의"
    },
    "order_mode": {
      "type": "string",
      "description": "strict 또는 any"
    },
    "window": {
      "type": "string",
      "description": "visit 또는 day (day는 방문 안에서 측정)"
    },
    "steps": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "단계별: index, name, type, value, count, step_conversion_rate, overall_conversion_rate, dropoff, dropoff_rate, median_seconds_from_previous, next_pages [{value, count}]"
    },
    "overall_conversion_rate": {
      "type": "number",
      "description": "마지막 단계 ÷ 첫 단계, %"
    },
    "breakdown": {
      "anyOf": [
        {
          "type": "object",
          "description": "dimension, label, rows [{value, counts, overall_conversion_rate}]"
        },
        {
          "type": "null"
        }
      ]
    },
    "comparison": {
      "anyOf": [
        {
          "type": "object",
          "description": "period, 단계별 count, overall_conversion_rate, 변화 (%)"
        },
        {
          "type": "null"
        }
      ]
    }
  }
}
PATCH /sites/:site_id/funnels/:id.json 퍼널 수정 funnels_update

권한: content.write

예시
curl -X PATCH https://privatusanalytics.com/sites/:site_id/funnels/:id.json \
  -H "Authorization: Bearer $PRIVATUS_TOKEN" \
  -H "Content-Type: application/json" -d '{…}'
입력
{
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "퍼널 이름",
      "examples": [
        "Signup flow"
      ]
    },
    "steps": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true
      },
      "description": "순서대로 나열한 단계 (2개에서 요금제 한도까지): [{\"type\": \"page|event|goal\", \"value\": \"/pricing | Signup | goal_…\", \"match\": \"exact|prefix|glob|regex\" (page 단계), \"name\": \"optional label\"}]"
    },
    "order_mode": {
      "type": "string",
      "description": "strict: 이 순서대로, any: 순서 무관",
      "enum": [
        "strict",
        "any"
      ]
    },
    "window": {
      "type": "string",
      "description": "전환 기간: visit, 또는 day (방문 안에서 측정하며 UTC 하루를 넘지 않음)",
      "enum": [
        "visit",
        "day"
      ]
    },
    "site_id": {
      "type": "string",
      "description": "사이트 ID, 예: pa_7Q2K9XH3AB"
    },
    "id": {
      "type": "string",
      "description": "리소스의 Id"
    }
  },
  "required": [
    "site_id",
    "id"
  ]
}
응답 데이터
{
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "퍼널 ID, 예: fun_7Q2K9XH3AB"
    },
    "name": {
      "type": "string"
    },
    "steps": {
      "type": "array",
      "items": {
        "type": "object"
      },
      "description": "단계: {type: page|event|goal, value, match, name}"
    },
    "order_mode": {
      "type": "string",
      "description": "strict 또는 any"
    },
    "window": {
      "type": "string",
      "description": "visit 또는 day"
    },
    "stats": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "entered": {
              "type": "integer",
              "description": "1단계에 도달한 방문"
            },
            "completed": {
              "type": "integer",
              "description": "마지막 단계에 도달한 방문"
            },
            "conversion_rate": {
              "type": "number",
              "description": "완료 ÷ 진입, %"
            }
          },
          "description": "기간 통계 (목록에서만)"
        },
        {
          "type": "null"
        }
      ]
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}