Singing Pet API
Singing Pet には REST API があります。曲テンプレートと価格は誰でも取得できます。ユーザーの動画・クレジット・請求に関わるものはすべて Firebase の ID トークンが必要です。
OpenAPI 仕様
API 全体の機械可読な定義です。すべてのエンドポイントに一意の operation id、型付きパラメータ、レスポンススキーマがあります。クライアント生成ツールやエージェントの function calling ローダーをそのまま向けられます。
OpenAPI 仕様を見るhttps://singing.pet/openapi.json
認証
Firebase Authentication の ID トークンをベアラートークンとして送ります。このサイトで Google またはメールリンクでサインインすると発行されます。公開と記載されたエンドポイントにはヘッダーは不要です。
エンドポイント
https://api.singing.pet
| GET | / | getServiceIndex | 公開 |
| GET | /openapi.json | getOpenApiSpec | 公開 |
| GET | /health | getHealth | 公開 |
| GET | /templates | listTemplates | 公開 |
| GET | /subscription/pricing | getPricing | 公開 |
| GET | /user/me | getCurrentUser | トークン |
| GET | /user/videos | listUserVideos | トークン |
| POST | /create-with-template | createVideoFromTemplate | トークン |
| POST | /create-with-audio | createVideoFromAudio | トークン |
| DELETE | /delete-video | deleteVideo | トークン |
| GET | /tts/voices | listVoices | トークン |
| POST | /tts | generateSpeech | トークン |
| POST | /tiktok/extract-audio | extractTikTokAudio | トークン |
| GET | /subscription/status | getSubscriptionStatus | トークン |
| POST | /subscription/create-checkout-session | createCheckoutSession | トークン |
| POST | /subscription/create-one-time-checkout | createOneTimeCheckout | トークン |
| POST | /subscription/create-portal-session | createPortalSession | トークン |
| GET | /versions | listApiVersions | 公開 |
| GET | /v1/templates | listApiTemplates | トークン |
| GET | /v1/me | getApiAccount | トークン |
| GET | /v1/credits | getApiCredits | トークン |
| GET | /v1/videos | listApiVideos | トークン |
| POST | /v1/videos | createApiVideo | トークン |
| GET | /v1/videos/{id} | getApiVideo | トークン |
| DELETE | /v1/videos/{id} | deleteApiVideo | トークン |
| POST | /mcp | callMcpServer | トークン |
リクエスト例
curl https://api.singing.pet/templates
curl https://api.singing.pet/user/videos?page=1 \
-H "Authorization: Bearer $FIREBASE_ID_TOKEN"エラー
失敗はすべて JSON で返ります。個別のエンドポイントが処理しないものは、安定したコード、読めるメッセージ、次に何をすべきかのヒントを含む共通の形式を使います。
{
"error": {
"code": "not_found",
"message": "No route matches GET /nope",
"status": 404,
"hint": "Check the path against https://singing.pet/openapi.json.",
"documentation_url": "https://singing.pet/developers"
},
"message": "No route matches GET /nope"
}レンダリングは非同期です
作成 API はレンダリングがキューに入った時点で返ります。listUserVideos をポーリングして status が pending から completed または failed に変わるのを待つか、wss://api.singing.pet の WebSocket を購読してください。
制限
音声は2秒から30秒までで、動画の長さは音声とまったく同じです。テキスト読み上げは最大500文字です。無料アカウントは毎月2本、有料プランは無制限です。
エージェント向けの Markdown
このサイトのコンテンツページは、acceptmarkdown.com に従って Accept ヘッダーで要求すると、きれいな Markdown を返します。手書きのサイト索引は llms.txt にあります。