API Reference
コンテスト
コンテストの詳細を一覧表示および取得
コンテスト
コンテストの管理および情報取得を行います。
コンテスト一覧
GET
/api/v1/contests Public or Private API Key
APIキーに関連付けられたチームのすべてのコンテストの一覧を返します。
リクエスト
パラメータは不要です。
bash
curl -X GET https://blitzrocket.com/api/v1/contests \
-H "x-api-key: your_api_key_here"
レスポンス
json
{
"success": true,
"data": [
{
"id": "clx1abc123def456",
"title": "Summer Giveaway 2025",
"description": "この夏、素晴らしい賞品を獲得しよう!",
"status": "active",
"startDate": "2025-06-01T00:00:00.000Z",
"endDate": "2025-08-31T23:59:59.000Z",
"isEvergreen": false,
"mode": "giveaway",
"slug": "summer-giveaway-2025",
"entriesCount": 1523
},
{
"id": "clx2def456ghi789",
"title": "Product Launch Contest",
"description": null,
"status": "draft",
"startDate": null,
"endDate": null,
"isEvergreen": true,
"mode": "leaderboard",
"slug": "product-launch",
"entriesCount": 0
}
]
}
レスポンスフィールド
idstringコンテストの一意識別子
titlestringコンテストのタイトル
descriptionstring | nullコンテストの説明文
statusstring現在のステータス:draft, active, ended, または paused
startDatestring | nullISO 8601形式の開始日、未設定の場合はnull
endDatestring | nullISO 8601形式の終了日、未設定の場合はnull
isEvergreenbooleanコンテストが無期限に開催されるかどうか
modestringコンテストモード:giveaway, leaderboard, または waitlist
slugstringURLフレンドリーな一意識別子
entriesCountnumberコンテストへのエントリー総数
コンテスト取得
GET
/api/v1/contests/:contestId Public or Private API Key
特定のコンテストの詳細情報を取得します。
パスパラメータ
contestIdstring required コンテストの一意識別子
リクエスト
bash
curl -X GET https://blitzrocket.com/api/v1/contests/clx1abc123def456 \
-H "x-api-key: your_api_key_here"
レスポンス
json
{
"success": true,
"data": {
"id": "clx1abc123def456",
"title": "Summer Giveaway 2025",
"description": "この夏、素晴らしい賞品を獲得しよう!",
"status": "active",
"startDate": "2025-06-01T00:00:00.000Z",
"endDate": "2025-08-31T23:59:59.000Z",
"isEvergreen": false,
"mode": "giveaway",
"slug": "summer-giveaway-2025",
"entriesCount": 1523,
"viewsCount": 12847
}
}
エラー応答
| ステータス | エラー | 説明 |
|---|---|---|
400 | contestIdが不足 | contestIdパスパラメータは必須です |
401 | 無効なAPIキー | APIキーが存在しないか無効です |
404 | コンテストが見つかりません | 指定されたIDのコンテストは存在しません |