{"openapi":"3.1.0","info":{"title":"Lingolix Pronunciation API","description":"Syllable-level pronunciation scoring. Markdown reference: https://lingolix.com/api-docs.md","version":"3"},"paths":{"/api/pronunciation/v3/check":{"post":{"summary":"Score pronunciation (syllable-level)","description":"V3 pronunciation check using API key authentication with syllable-level analysis.\n\n**Authentication**: Requires API key in Authorization header:\n```\nAuthorization: Bearer lx_your_api_key_here\n```\n\n**Supported Languages** (16 languages):\nbg, cs, de, el, en, es, fi, fr, hu, it, ja, ko, nl, pl, pt, sv, uk\n\n**Response**: Returns detailed syllable-level pronunciation analysis including:\n- `accuracy`: Overall pronunciation accuracy (0-1)\n- `completeness`: How complete the utterance was (0-1)\n- `speaking_rate`: Speech rate\n- `words`: Per-word and per-syllable analysis with IPA, pitch, and timing\n\n**Quota**: Usage is tracked against your subscription's monthly audio minutes.\n\n**Audio length**: up to 60 seconds; longer clips are rejected with 400.","operationId":"check_pronunciation_v3_api_api_pronunciation_v3_check_post","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_check_pronunciation_v3_api_api_pronunciation_v3_check_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PronunciationAnalysisResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"bearerAuth":[]}]}}},"components":{"schemas":{"Body_check_pronunciation_v3_api_api_pronunciation_v3_check_post":{"properties":{"speechdata":{"type":"string","contentMediaType":"application/octet-stream","title":"Speechdata","description":"Audio file containing speech to analyze"},"sentence":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sentence","description":"Expected sentence/text to compare against. If not provided, audio is transcribed first."},"language_code":{"type":"string","title":"Language Code","description":"Language code (bg, cs, de, el, en, es, fi, fr, hu, it, ja, ko, nl, pl, pt, sv, uk)","default":"ja"}},"type":"object","required":["speechdata"],"title":"Body_check_pronunciation_v3_api_api_pronunciation_v3_check_post"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"PronunciationAnalysisResponse":{"properties":{"text":{"type":"string","title":"Text"},"speaking_rate":{"type":"number","title":"Speaking Rate"},"accuracy":{"type":"number","title":"Accuracy"},"completeness":{"type":"number","title":"Completeness"},"words":{"items":{"$ref":"#/components/schemas/WordV3"},"type":"array","title":"Words"},"overall":{"type":"number","title":"Overall"},"fluency":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Fluency"},"target_speaking_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Target Speaking Rate"},"model_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model Version"}},"type":"object","required":["text","speaking_rate","accuracy","completeness","words","overall"],"title":"PronunciationAnalysisResponse"},"Syllable":{"properties":{"text":{"type":"string","title":"Text"},"expected_ipa":{"type":"string","title":"Expected Ipa"},"detected_ipa":{"type":"string","title":"Detected Ipa"},"accuracy":{"type":"number","title":"Accuracy"},"completeness":{"type":"number","title":"Completeness"},"pitch":{"type":"string","enum":["high","flat","low","unknown"],"title":"Pitch"},"duration_ms":{"type":"number","title":"Duration Ms"},"start_ms":{"type":"number","title":"Start Ms"},"end_ms":{"type":"number","title":"End Ms"},"is_missing":{"type":"boolean","title":"Is Missing"},"is_extra":{"type":"boolean","title":"Is Extra"},"is_scored":{"type":"boolean","title":"Is Scored","default":true}},"type":"object","required":["text","expected_ipa","detected_ipa","accuracy","completeness","pitch","duration_ms","start_ms","end_ms","is_missing","is_extra"],"title":"Syllable"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"WordV3":{"properties":{"text":{"type":"string","title":"Text"},"syllables":{"items":{"$ref":"#/components/schemas/Syllable"},"type":"array","title":"Syllables"},"accuracy":{"type":"number","title":"Accuracy"},"completeness":{"type":"number","title":"Completeness"},"start_ms":{"type":"number","title":"Start Ms"},"end_ms":{"type":"number","title":"End Ms"},"char_start":{"type":"integer","title":"Char Start","default":-1},"char_end":{"type":"integer","title":"Char End","default":-1},"is_scored":{"type":"boolean","title":"Is Scored","default":true},"hesitation_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hesitation Ms"}},"type":"object","required":["text","syllables","accuracy","completeness","start_ms","end_ms"],"title":"WordV3"}},"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}}}}