이 페이지 내용
빠른 시작
Hypereal API는 강력한 미디어 생성 모델에 대한 접근을 제공합니다. 모든 요청에는 API 키를 사용한 Bearer 인증이 필요합니다.
curl -X POST https://api.hypereal.tech/v1/images/generate \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"prompt": "a sunset over the ocean",
"model": "nano-banana-t2i"
}'curl -X POST https://api.hypereal.tech/v1/videos/generate \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "wan-2-6-i2v",
"input": {
"prompt": "a cat walking",
"image": "https://example.com/cat.jpg"
}
}'/api/v1/chatLLM Chat
스트리밍을 지원하는 강력한 LLM Chat API입니다. 챗봇, 콘텐츠 생성, 코드 지원 및 모든 대화형 AI 애플리케이션 구축에 적합합니다.
요청 본문
role and content요금
Base: 2 credits per message (scales with conversation length)
curl -X POST https://api.hypereal.tech/v1/chat \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"messages": [
{"role": "user", "content": "Hello, how are you?"}
],
"stream": false
}'{
"id": "chatcmpl-abc123",
"choices": [{
"index": 0,
"message": {
"role": "assistant",
"content": "Hello! I'm doing great..."
},
"finish_reason": "stop"
}],
"creditsUsed": 2
}const response = await fetch('https://api.hypereal.tech/v1/chat', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer YOUR_API_KEY'
},
body: JSON.stringify({
messages: [{ role: 'user', content: 'Hi!' }],
stream: true
})
});
const reader = response.body.getReader();
while (true) {
const { done, value } = await reader.read();
if (done) break;
// Process SSE chunks
}/api/v1/images/generate이미지 생성
최신 AI 모델을 사용하여 이미지를 생성합니다. 이 엔드포인트는 요청을 동기적으로 처리하고 생성된 이미지 URL을 응답에 직접 반환합니다.
요청 본문
nano-banana-t2i)응답 필드
url and modelcurl -X POST https://api.hypereal.tech/v1/images/generate \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"prompt": "A futuristic cityscape at sunset with flying cars",
"model": "nano-banana-t2i",
"aspect_ratio": "16:9"
}'{
"created": 1766841456,
"data": [
{
"url": "https://pub-xxx.r2.dev/generated/images/xxx.png",
"model": "nano-banana-t2i"
}
],
"resultId": "res_abc123456",
"creditsUsed": 4
}/api/v1/videos/generate동영상 생성
최신 AI 모델을 사용하여 동영상을 생성합니다. 이 엔드포인트는 텍스트-투-비디오 및 이미지-투-비디오 생성을 모두 지원하며 비동기 전달을 위한 웹훅 콜백을 제공합니다.
요청 본문
sora-2-i2v)응답 필드
curl -X POST https://api.hypereal.tech/v1/videos/generate \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model": "sora-2-i2v",
"input": {
"prompt": "Camera slowly pans across the scene",
"image": "https://hypereal.tech/demo-girl.webp",
"duration": 5
},
"webhook_url": "https://your-server.com/webhook"
}'{
"jobId": "job_abc123456",
"status": "processing",
"message": "Generation started. Result will be sent to your webhook URL.",
"creditsUsed": 69
}/api/media/generateGenerate Audio
Text-to-speech, voice cloning, and speech recognition. Supports 64+ emotional expressions for natural-sounding speech synthesis.
사용 가능한 모델
Emotion Syntax
Wrap emotions in parentheses at the start of text:
(happy) Hello! • (sad) I miss you • (excited)(laughing) Amazing!curl -X POST https://api.hypereal.tech/api/media/generate \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model": "audio-tts",
"input": {
"text": "(happy) Welcome to Hypereal!",
"format": "mp3"
}
}'{
"model": "audio-clone",
"input": {
"text": "Clone my voice!",
"audio": "https://example.com/voice.mp3"
}
}{
"success": true,
"text": "Hello, welcome to Hypereal.",
"duration": 2.5,
"segments": [
{"text": "Hello,", "start": 0.0, "end": 0.8},
{"text": "welcome to Hypereal.", "start": 0.9, "end": 2.5}
]
}/api/media/generateGenerate 3D Models
Convert images to 3D models using state-of-the-art AI. Generate high-quality GLB models ready for use in games, AR/VR, and web applications.
사용 가능한 모델
Output Format
All 3D models are returned in GLB format, which is widely supported by 3D viewers, game engines, and web frameworks.
curl -X POST https://api.hypereal.tech/api/media/generate \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model": "hunyuan3d-v2-base",
"input": {
"image": "https://example.com/object.png"
}
}'{
"model": "tripo3d-multiview-to-3d",
"input": {
"front_image_url": "https://example.com/front.png",
"back_image_url": "https://example.com/back.png",
"left_image_url": "https://example.com/left.png",
"right_image_url": "https://example.com/right.png"
}
}{
"success": true,
"outputUrl": "https://cdn.hypereal.tech/3d/model.glb",
"creditsUsed": 45
}Processing Modes
Synchronous (Images)
The /api/v1/images/generate endpoint processes requests synchronously. The generated image URL is returned directly in the response.
Asynchronous (Videos)
The /api/v1/videos/generate endpoint processes requests asynchronously. Provide a webhook_url to receive results when complete, or poll the job status endpoint.
Webhook Delivery
Provide a webhook_url in your request to receive the result when generation completes. We'll POST the result directly to your server.
Webhook Payload
{
"status": "completed",
"outputUrl": "https://cdn.hypereal.tech/output/video.mp4",
"jobId": "job_abc123456",
"type": "video",
"model": "sora-2-i2v",
"creditsUsed": 69
}Example: Node.js Webhook Handler
app.post('/webhook/hypereal', express.json(), (req, res) => {
const { status, outputUrl, jobId, error } = req.body;
if (status === 'completed') {
console.log(`Job ${jobId} completed: ${outputUrl}`);
// Save to database, notify user, etc.
} else if (status === 'failed') {
console.error(`Job ${jobId} failed: ${error}`);
}
// Always return 200 to acknowledge receipt
res.status(200).json({ received: true });
});Return 200 immediately
Process asynchronously if needed, but respond quickly to avoid timeouts.
Handle idempotency
Use jobId to prevent duplicate processing.
/api/v1/jobs/{id}Job Polling
If you can't receive webhooks, use the pollUrl returned in the initial response to check job status until complete.
Query Parameters
video or imageGET /api/v1/jobs/job_abc123?model=sora-2-i2v&type=video
{
"status": "completed",
"outputUrl": "https://cdn.hypereal.tech/output/video.mp4",
"jobId": "job_abc123"
}Supported Models
All available models with their parameters and pricing.
Video Generation (19 models)
Image Generation (7 models)
Image Editing (5 models)
Audio Generation (7 models)
3D Model Generation (6 models)
Error Responses
All endpoints return standard HTTP status codes with error details in JSON format.
Unauthorized
{
"error": "Unauthorized. Please log in..."
}Bad Request
{
"error": "Model is required"
}Insufficient Credits
{
"error": "Insufficient credits",
"required": 69,
"available": 10
}Not Found
{
"error": "Job not found"
}Rate Limits
Rate limits are enforced per API key on a rolling 1-hour window.
Each API key has a default rate limit of 1000 requests per hour. Exceeding returns 429.
Credits
Credits are deducted when you submit a request (before processing).
LLM Chat
New2+ credits per message
Video Generation
20-150 credits per video
Image Generation
4-25 credits per image
Image Editing
4-14 credits per edit
Audio Generation
107 credits per voice clone
3D Model Generation
45 credits per 3D model
