Skip to content

Commit cf748fd

Browse files
committed
feat: enhance audio analysis session API documentation with upload requirements and processing steps
1 parent 48f0e2d commit cf748fd

1 file changed

Lines changed: 14 additions & 3 deletions

File tree

README.md

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,17 +88,28 @@ Requires `Authorization: Bearer <token>`. Uses Cerberus token introspection, ret
8888

8989
### POST `/api/sessions`
9090

91+
Creates a new audio analysis session. Requires authentication.
92+
93+
**Important**: The `uploadUrl` must point to a publicly accessible audio file hosted on cloud storage (S3, CDN, etc.). The API does not handle file uploads directly - users must upload their files separately and provide the URL.
94+
9195
Body:
9296

9397
```jsonc
9498
{
9599
"sessionId": "mix-42",
96-
"uploadUrl": "https://cdn.example.com/mix.wav",
97-
"userContext": { "daw": "Ableton Live" },
100+
"uploadUrl": "https://cdn.example.com/mix.wav", // Must be publicly accessible HTTPS URL
101+
"userContext": { "daw": "Ableton Live", "genre": "House", "experienceLevel": "intermediate" }
98102
}
99103
```
100104

101-
Response: `EngineState` from `@auralyze/engine`. Include `Authorization: Bearer <token>` obtained from Cerberus (or the local JWT fallback).
105+
The API will:
106+
107+
1. Extract metadata (duration, format, sample rate) via metadata service
108+
2. Perform audio analysis (loudness, dynamics, spectrum, stereo) via analysis service
109+
3. Generate AI feedback via feedback service (OpenAI GPT-4)
110+
4. Store complete results in database
111+
112+
Response: `EngineState` from `@auralyze/engine` with all analysis results. Include `Authorization: Bearer <token>` or authenticate via httpOnly cookie.
102113

103114
## Security & Release
104115

0 commit comments

Comments
 (0)