from magic_hour import Client
from os import getenv
client = Client(token=getenv("MAGIC_HOUR_API_KEY"))
res = client.v1.face_detection.get(id="uuid-example")
import { Client } from "magic-hour";
const client = new Client({ token: process.env["MAGIC_HOUR_API_KEY"] });
const res = await client.v1.faceDetection.get({ id: "uuid-example" });
Use this API to get the list of faces detected in the image or video to use in the face swap photo or face swap video API calls for multi-face swaps.
GET
/
v1
/
face-detection
/
{id}
Python
from magic_hour import Client
from os import getenv
client = Client(token=getenv("MAGIC_HOUR_API_KEY"))
res = client.v1.face_detection.get(id="uuid-example")
import { Client } from "magic-hour";
const client = new Client({ token: process.env["MAGIC_HOUR_API_KEY"] });
const res = await client.v1.faceDetection.get({ id: "uuid-example" });
Bearer authentication header of the form Bearer <api_key>, where <api_key> is your API key. To get your API key, go to Developer Hub and click "Create new API Key".
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Magic Hour API Docs","description":"Easily generate videos, images, and audio using Magic Hour's API. Follow our documentation to seamlessly integrate AI content creation into your applications.","colors":{"primary":"#3b82f6","light":"#0564ff","dark":"#3b82f6"},"logo":{"light":"https://mintcdn.com/magichour/5sgGJpuuipkw5s5v/icons/logo-light.svg?fit=max\u0026auto=format\u0026n=5sgGJpuuipkw5s5v\u0026q=85\u0026s=1f167e30baf11927bc2e0932411e455b","dark":"https://mintcdn.com/magichour/5sgGJpuuipkw5s5v/icons/logo-dark.svg?fit=max\u0026auto=format\u0026n=5sgGJpuuipkw5s5v\u0026q=85\u0026s=15c8bda28931ac4e1e2fab2c0ba6f0d5"},"favicon":"https://mintcdn.com/magichour/kbUwXh9ksnVyRSci/icons/favicon.png?fit=max\u0026auto=format\u0026n=kbUwXh9ksnVyRSci\u0026q=85\u0026s=c4fda903b24dd7067dadd1bb75508987","appearance":{"default":"dark","strict":false},"background":{"decoration":"gradient"},"navbar":{"links":[{"href":"mailto:support@magichour.ai","label":"Support"}],"primary":{"type":"button","label":"Get API key","href":"https://magichour.ai/developer?tab=api-keys\u0026ref=docs-navbar\u0026utm_source=docs\u0026utm_medium=referral\u0026utm_campaign=navbar"}},"footer":{"socials":{"website":"https://magichour.ai/?utm_source=docs\u0026utm_medium=referral\u0026utm_campaign=footer","x":"https://x.com/magichourai","github":"https://github.com/magichourhq","linkedin":"https://linkedin.com/company/magichour","instagram":"https://instagram.com/magichourai","youtube":"https://youtube.com/@magichourai"}},"seo":{"metatags":{"og:image":"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg","twitter:image":"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg"}},"integrations":{"ga4":{"measurementId":"G-CZ9Q9NBZB3"},"posthog":{"apiKey":"phc_EmzSy2RU0TOPhpouazMzxFedNdMyhze8HakyjffW2Wr","apiHost":"https://us.i.posthog.com"}},"contextual":{"options":["chatgpt","claude","perplexity","mcp","cursor","vscode","copy","view"],"display":"header"},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"API quickstart","icon":"forward-fast","href":"/get-started/quick-start"},{"anchor":"API pricing","icon":"credit-card","href":"/billing/overview"},{"anchor":"Community","icon":"discord","href":"https://discord.com/invite/JX5rgsZaJp"},{"anchor":"Status","icon":"wave-pulse","href":"https://status.magichour.ai"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"magichour","hasAudioNarration":false,"actualSubdomain":"magichour","customDomains":["docs.magichour.ai"],"gitSource":{"type":"github","owner":"magichourhq","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":false,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ae691a9326d1b59f41f1b7f","collectionId":"6c5ad854-cddd-4451-b527-ffa76ab72a43","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ae691a9326d1b59f41f1b7f"},"feedback":{"thumbs":true,"issues":true,"edits":true},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6ae69f25a0d878501ab62d9f","clientVersion":"0.0.4044","searchFilterCounts":[{"language":"default","tag":"Documentation","count":97},{"language":"default","tag":"Integration","count":56},{"language":"default","tag":"API Reference","count":45},{"language":"default","tag":"Tools","count":30},{"language":"default","tag":"Image Projects","count":16},{"language":"default","tag":"Video Projects","count":16},{"language":"default","tag":"Images","count":15},{"language":"default","tag":"Video","count":12},{"language":"default","tag":"Webhook Reference","count":10},{"language":"default","tag":"Get Started","count":7}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"#sidebar,#table-of-contents-content{scrollbar-width:thin;scrollbar-gutter:none;scrollbar-color:gray transparent}"}],"page":{"pagePath":"api-reference/files/get-face-detection-details","slug":"/api-reference/files/get-face-detection-details","pageMetadata":{"title":"Get face detection details","description":"Get the details of a face detection task. \n\nUse this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/image-projects/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/video-projects/face-swap-video) API calls for multi-face swaps.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/face-detection/{id}","href":"/api-reference/files/get-face-detection-details","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {Fragment: _Fragment, jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n a: \"a\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_Fragment, {\n children: [_jsx(_components.p, {\n children: \"Get the details of a face detection task.\"\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Use this API to get the list of faces detected in the image or video to use in the \", _jsx(_components.a, {\n href: \"https://docs.magichour.ai/api-reference/image-projects/face-swap-photo\",\n children: \"face swap photo\"\n }), \" or \", _jsx(_components.a, {\n href: \"https://docs.magichour.ai/api-reference/video-projects/face-swap-video\",\n children: \"face swap video\"\n }), \" API calls for multi-face swaps.\"]\n })]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Get face detection details","description":"Get the details of a face detection task. \n\nUse this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/image-projects/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/video-projects/face-swap-video) API calls for multi-face swaps.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/face-detection/{id}","href":"/api-reference/files/get-face-detection-details","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"description":"Get the details of a face detection task. \n\nUse this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/image-projects/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/video-projects/face-swap-video) API calls for multi-face swaps.","summary":"Get face detection details","tags":["Files"],"parameters":["999acec9-6870-45f4-aa6a-1bc764dab49d"],"operationId":"faceDetection.getDetails","responses":{"200":"d0354ba6-532b-405b-b7db-8d4a6266b42c","400":"904d29aa-9362-4b00-8d69-3c8eee43da1b","401":"5ae9af78-789b-4dab-9ec8-35180d94b17d","402":"d459b23f-d2e9-4a63-a60f-2fcd34d57c55","404":"ef8848e9-c23c-439c-a8fd-243a4e967842","422":"8f65d2f1-6fd6-4025-8e32-2a336db5d218","500":"6f1fd42d-5a2b-46dc-9d11-5db6d03e7c02"},"security":["6b4d4f66-c835-4f8c-b90b-ea520756d242"],"x-codeSamples":[{"lang":"python","source":"from magic_hour import Client\nfrom os import getenv\n\nclient = Client(token=getenv(\"MAGIC_HOUR_API_KEY\"))\nres = client.v1.face_detection.get(id=\"uuid-example\")"},{"lang":"javascript","source":"import { Client } from \"magic-hour\";\n\nconst client = new Client({ token: process.env[\"MAGIC_HOUR_API_KEY\"] });\nconst res = await client.v1.faceDetection.get({ id: \"uuid-example\" });"},{"lang":"go","source":"package main\n\nimport (\n\tos \"os\"\n\n\tsdk \"github.com/magichourhq/magic-hour-go/client\"\n\tface_detection \"github.com/magichourhq/magic-hour-go/resources/v1/face_detection\"\n)\n\nfunc main() {\n\tclient := sdk.NewClient(\n\t\tsdk.WithBearerAuth(os.Getenv(\"MAGIC_HOUR_API_KEY\")),\n\t)\n\tres, err := client.V1.FaceDetection.Get(face_detection.GetRequest{\n\t\tId: \"uuid-example\",\n\t})\n}"},{"lang":"rust","source":"let client = magic_hour::Client::default()\n .with_bearer_auth(\u0026std::env::var(\"MAGIC_HOUR_API_KEY\").unwrap());\nlet res = client\n .v1()\n .face_detection()\n .get(magic_hour::resources::v1::face_detection::GetRequest {\n id: \"uuid-example\".to_string(),\n })\n .await;"},{"lang":"curl","source":"curl --request GET \\\n --url https://api.magichour.ai/v1/face-detection/id \\\n --header 'accept: application/json' \\\n --header \"authorization: Bearer $MAGIC_HOUR_API_KEY\""},{"lang":"php","source":"\u003c?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n CURLOPT_URL => \"https://api.magichour.ai/v1/face-detection/id\",\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_ENCODING => \"\",\n CURLOPT_MAXREDIRS => 10,\n CURLOPT_TIMEOUT => 30,\n CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n CURLOPT_CUSTOMREQUEST => \"GET\",\n CURLOPT_HTTPHEADER => [\n \"accept: application/json\",\n \"authorization: Bearer \u003ctoken>\"\n ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n echo \"cURL Error #:\" . $err;\n} else {\n echo $response;\n}"},{"lang":"java","source":"HttpResponse\u003cString> response = Unirest.get(\"https://api.magichour.ai/v1/face-detection/id\")\n .header(\"accept\", \"application/json\")\n .header(\"authorization\", \"Bearer \u003ctoken>\")\n .asString();"}],"method":"get","type":"path","servers":["9d7d9813-e8f8-4d8d-bab1-aec4a4bedf19"],"path":"/v1/face-detection/{id}","baseUrlOptions":["https://api.magichour.ai"],"title":"Get face detection details","codeSamples":[{"lang":"python","source":"from magic_hour import Client\nfrom os import getenv\n\nclient = Client(token=getenv(\"MAGIC_HOUR_API_KEY\"))\nres = client.v1.face_detection.get(id=\"uuid-example\")"},{"lang":"javascript","source":"import { Client } from \"magic-hour\";\n\nconst client = new Client({ token: process.env[\"MAGIC_HOUR_API_KEY\"] });\nconst res = await client.v1.faceDetection.get({ id: \"uuid-example\" });"},{"lang":"go","source":"package main\n\nimport (\n\tos \"os\"\n\n\tsdk \"github.com/magichourhq/magic-hour-go/client\"\n\tface_detection \"github.com/magichourhq/magic-hour-go/resources/v1/face_detection\"\n)\n\nfunc main() {\n\tclient := sdk.NewClient(\n\t\tsdk.WithBearerAuth(os.Getenv(\"MAGIC_HOUR_API_KEY\")),\n\t)\n\tres, err := client.V1.FaceDetection.Get(face_detection.GetRequest{\n\t\tId: \"uuid-example\",\n\t})\n}"},{"lang":"rust","source":"let client = magic_hour::Client::default()\n .with_bearer_auth(\u0026std::env::var(\"MAGIC_HOUR_API_KEY\").unwrap());\nlet res = client\n .v1()\n .face_detection()\n .get(magic_hour::resources::v1::face_detection::GetRequest {\n id: \"uuid-example\".to_string(),\n })\n .await;"},{"lang":"curl","source":"curl --request GET \\\n --url https://api.magichour.ai/v1/face-detection/id \\\n --header 'accept: application/json' \\\n --header \"authorization: Bearer $MAGIC_HOUR_API_KEY\""},{"lang":"php","source":"\u003c?php\n\n$curl = curl_init();\n\ncurl_setopt_array($curl, [\n CURLOPT_URL => \"https://api.magichour.ai/v1/face-detection/id\",\n CURLOPT_RETURNTRANSFER => true,\n CURLOPT_ENCODING => \"\",\n CURLOPT_MAXREDIRS => 10,\n CURLOPT_TIMEOUT => 30,\n CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\n CURLOPT_CUSTOMREQUEST => \"GET\",\n CURLOPT_HTTPHEADER => [\n \"accept: application/json\",\n \"authorization: Bearer \u003ctoken>\"\n ],\n]);\n\n$response = curl_exec($curl);\n$err = curl_error($curl);\n\ncurl_close($curl);\n\nif ($err) {\n echo \"cURL Error #:\" . $err;\n} else {\n echo $response;\n}"},{"lang":"java","source":"HttpResponse\u003cString> response = Unirest.get(\"https://api.magichour.ai/v1/face-detection/id\")\n .header(\"accept\", \"application/json\")\n .header(\"authorization\", \"Bearer \u003ctoken>\")\n .asString();"}],"requiredOnlyExamples":false,"requestExampleType":"codeSamples","responseExampleType":"generated"},"dependencies":{"parameters":{"999acec9-6870-45f4-aa6a-1bc764dab49d":{"name":"id","in":"path","required":true,"schema":{"type":"string","example":"uuid-example","isRequired":true,"description":"The id of the task. This value is returned by the [face detection API](https://docs.magichour.ai/api-reference/files/face-detection#response-id).","uniqueKey":"","typeLabel":"string"},"description":"The id of the task. This value is returned by the [face detection API](https://docs.magichour.ai/api-reference/files/face-detection#response-id)."}},"responses":{"d0354ba6-532b-405b-b7db-8d4a6266b42c":{"description":"200","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","description":"The id of the task. This value is returned by the [face detection API](https://docs.magichour.ai/api-reference/files/face-detection#response-id).","example":"uuid-example","isRequired":true,"uniqueKey":"id","typeLabel":"string"},"credits_charged":{"type":"integer","description":"The credits charged for the task.","example":0,"isRequired":true,"uniqueKey":"credits_charged","typeLabel":"integer"},"status":{"type":"string","enum":["queued","rendering","complete","error"],"description":"The status of the detection.","example":"complete","isRequired":true,"uniqueKey":"status","typeLabel":"enum\u003cstring>"},"faces":{"type":"array","items":{"type":"object","properties":{"path":{"type":"string","description":"The path to the face image. This should be used in face swap photo/video API calls as `.assets.face_mappings.original_face`","example":"api-assets/id/0-0.png","isRequired":true,"uniqueKey":"faces.items.[INDEX].path","typeLabel":"string"},"url":{"type":"string","description":"The url to the face image. This is used to render the image in your applications.","example":"https://videos.magichour.ai/api-assets/id/0-0.png","isRequired":true,"uniqueKey":"faces.items.[INDEX].url","typeLabel":"string"}},"required":["path","url"],"uniqueKey":"faces.items.[INDEX]","typeLabel":"object"},"description":"The faces detected in the image or video. The list is populated as faces are detected.","example":[{"path":"api-assets/id/0-0.png","url":"https://videos.magichour.ai/api-assets/id/0-0.png"}],"isRequired":true,"uniqueKey":"faces","typeLabel":"object[]"}},"required":["id","credits_charged","status","faces"],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"id":"uuid-example","credits_charged":0,"status":"complete","faces":[{"path":"api-assets/id/0-0.png","url":"https://videos.magichour.ai/api-assets/id/0-0.png"}]}}},"exampleType":"generated"}},"exampleType":"generated"},"904d29aa-9362-4b00-8d69-3c8eee43da1b":{"description":"Invalid Request","content":{"application/json":{"schema":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["invalid_request"],"description":"Machine-readable error code.\n\n- `invalid_request`: Fix request syntax or validation errors before retrying.","isRequired":true,"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error message.","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"invalid_request","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"5ae9af78-789b-4dab-9ec8-35180d94b17d":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["unauthorized"],"description":"Machine-readable error code.\n\n- `unauthorized`: Provide a valid API key before retrying.","isRequired":true,"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error message.","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"unauthorized","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"d459b23f-d2e9-4a63-a60f-2fcd34d57c55":{"description":"Payment Required","content":{"application/json":{"schema":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["insufficient_credits","subscription_required","plan_upgrade_required"],"description":"Machine-readable error code.\n\n- `insufficient_credits`: Purchase credits before retrying.\n\n- `subscription_required`: Start a subscription before retrying.\n\n- `plan_upgrade_required`: Upgrade the subscription plan before retrying.","isRequired":true,"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error message.","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"insufficient_credits","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"ef8848e9-c23c-439c-a8fd-243a4e967842":{"description":"Not Found","content":{"application/json":{"schema":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["not_found"],"description":"Machine-readable error code.\n\n- `not_found`: Check the route or resource identifier.","isRequired":true,"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error message.","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"not_found","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"8f65d2f1-6fd6-4025-8e32-2a336db5d218":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["unprocessable_entity"],"description":"Machine-readable error code.\n\n- `unprocessable_entity`: Change the request values before retrying.","isRequired":true,"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error message.","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"unprocessable_entity","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"6f1fd42d-5a2b-46dc-9d11-5db6d03e7c02":{"description":"Internal Server Error","content":{"application/json":{"schema":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["internal_server_error"],"description":"Machine-readable error code.\n\n- `internal_server_error`: Retry later or contact support if the error continues.","isRequired":true,"uniqueKey":"code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error message.","isRequired":true,"uniqueKey":"message","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"code":"internal_server_error","message":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"6b4d4f66-c835-4f8c-b90b-ea520756d242":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Bearer authentication header of the form `Bearer \u003capi_key>`, where `\u003capi_key>` is your API key. To get your API key, go to [Developer Hub](https://magichour.ai/developer?tab=api-keys\u0026utm_source=docs\u0026utm_medium=referral\u0026utm_campaign=api-reference) and click \"Create new API Key\".","scopes":[],"schemeName":"bearerAuth"}}},"servers":{"9d7d9813-e8f8-4d8d-bab1-aec4a4bedf19":{"url":"https://api.magichour.ai"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","description":"Bearer authentication header of the form `Bearer \u003capi_key>`, where `\u003capi_key>` is your API key. To get your API key, go to [Developer Hub](https://magichour.ai/developer?tab=api-keys\u0026utm_source=docs\u0026utm_medium=referral\u0026utm_campaign=api-reference) and click \"Create new API Key\".","scopes":[],"schemeName":"bearerAuth"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Bearer authentication header of the form `Bearer \u003capi_key>`, where `\u003capi_key>` is your API key. To get your API key, go to [Developer Hub](https://magichour.ai/developer?tab=api-keys\u0026utm_source=docs\u0026utm_medium=referral\u0026utm_campaign=api-reference) and click \"Create new API Key\".","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"bearerAuth","name":"Authorization"}],"title":"bearerAuth"}]},"originalFileLocation":"api-reference/openapi.json"},"subdomain":"magichour","siteName":"Magic Hour API Docs","title":"Get face detection details - Magic Hour API Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-10-30T19:43:31.125Z","originalFileLocation":"api-reference/files/get-face-detection-details.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Get the details of a face detection task. Use this API to get the list of faces detected in the image or video to use in the face swap photo or face swap video API calls for multi-face swaps.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Magic Hour API Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Get face detection details - Magic Hour API Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Get the details of a face detection task. Use this API to get the list of faces detected in the image or video to use in the face swap photo or face swap video API calls for multi-face swaps.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Magic Hour API Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.magichour.ai/api-reference/files/get-face-detection-details\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Get face detection details - Magic Hour API Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Get the details of a face detection task. Use this API to get the list of faces detected in the image or video to use in the face swap photo or face swap video API calls for multi-face swaps.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/magichour/pV2W72GIHTaiOFzk/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Magic Hour API Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#3b82f6\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.magichour.ai/api-reference/files/get-face-detection-details\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/files/get-face-detection-details.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.magichour.ai/#organization\",\"name\":\"Magic Hour API Docs\",\"url\":\"https://docs.magichour.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/magichour/5sgGJpuuipkw5s5v/icons/logo-light.svg?fit=max\u0026auto=format\u0026n=5sgGJpuuipkw5s5v\u0026q=85\u0026s=1f167e30baf11927bc2e0932411e455b\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.magichour.ai#website\",\"name\":\"Magic Hour API Docs\",\"url\":\"https://docs.magichour.ai\",\"publisher\":{\"@id\":\"https://docs.magichour.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details#webpage\",\"url\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details\",\"name\":\"Get face detection details\",\"description\":\"Get the details of a face detection task. Use this API to get the list of faces detected in the image or video to use in the face swap photo or face swap video API calls for multi-face swaps.\",\"dateModified\":\"2026-10-30T19:43:31.125Z\",\"isPartOf\":{\"@id\":\"https://docs.magichour.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Files\",\"item\":\"https://docs.magichour.ai/api-reference/files/list-saved-items\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Get face detection details\",\"item\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details#apireference\",\"headline\":\"Get face detection details\",\"name\":\"Get face detection details\",\"description\":\"Get the details of a face detection task. Use this API to get the list of faces detected in the image or video to use in the face swap photo or face swap video API calls for multi-face swaps.\",\"url\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details\",\"mainEntityOfPage\":{\"@id\":\"https://docs.magichour.ai/api-reference/files/get-face-detection-details#webpage\"},\"image\":\"https://d28dkohlqf5vwj.cloudfront.net/open-graph/logo-social-noisy-spectrum.jpg\",\"dateModified\":\"2026-10-30T19:43:31.125Z\",\"publisher\":{\"@id\":\"https://docs.magichour.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.magichour.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Magic Hour API Docs\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Magic Hour API Docs","nav":{"global":{"anchors":[{"anchor":"API quickstart","icon":"forward-fast","href":"/get-started/quick-start"},{"anchor":"API pricing","icon":"credit-card","href":"/billing/overview"},{"anchor":"Community","icon":"discord","href":"https://discord.com/invite/JX5rgsZaJp"},{"anchor":"Status","icon":"wave-pulse","href":"https://status.magichour.ai"}]},"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":"/introduction"}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api-reference/overview"},{"title":"Models and Credit Costs","sidebarTitle":"Models","href":"/api-reference/models"},{"title":"Historical API Processing Times","sidebarTitle":"Processing Times","href":"/api-reference/processing-times"},{"group":"Account","pages":[{"title":"Get account details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/account","href":"/api-reference/account/get-account-details"}]},{"group":"Files","pages":[{"title":"List saved items","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/saved-items","href":"/api-reference/files/list-saved-items"},{"title":"Generate asset upload urls","description":"Generates a list of pre-signed upload URLs for the assets required. This API is only necessary if you want to upload to Magic Hour's storage. Refer to the [Input Files Guide](https://docs.magichour.ai/integration/inputs-and-outputs) for more details.\n\nThe response array will match the order of items in the request body.\n\n**Valid file extensions per asset type**:\n- video: mp4, m4v, mov, webm\n- audio: mp3, wav, aac, flac, webm, weba, m4a, opus, ogg, oga, aiff, amr\n- image: png, jpg, jpeg, jpe, jfif, heic, heif, webp, avif, jp2, tiff, tif, bmp\n- gif: gif, webp, webm\n\n> Note: `gif` is only supported for face swap API `video_file_path` field.\n\nOnce you receive an upload URL, send a `PUT` request to upload the file directly.\n\nExample:\n\n```\ncurl -X PUT --data '@/path/to/file/video.mp4' \\\n https://videos.magichour.ai/api-assets/id/video.mp4?\u003cauth params from the API response>\n```\n","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/files/upload-urls","href":"/api-reference/files/generate-asset-upload-urls"},{"title":"Get face detection details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/face-detection/{id}","href":"/api-reference/files/get-face-detection-details"},{"title":"Face Detection","description":"Detect faces in an image or video. \n \nUse this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/image-projects/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/video-projects/face-swap-video) API calls for multi-face swaps.\n\nNote: Face detection is free to use for the near future. Pricing may change in the future.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/face-detection","href":"/api-reference/files/face-detection"}]},{"group":"Video Projects","pages":[{"title":"Get video details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/video-projects/{id}","href":"/api-reference/video-projects/get-video-details"},{"title":"Delete video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json delete /v1/video-projects/{id}","href":"/api-reference/video-projects/delete-video"},{"title":"AI Talking Photo","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-talking-photo","href":"/api-reference/video-projects/ai-talking-photo"},{"title":"AI UGC Ad Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-ugc-ad","href":"/api-reference/video-projects/ai-ugc-ad-generator"},{"title":"AI Video Editor","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-video-editor","href":"/api-reference/video-projects/ai-video-editor"},{"title":"AI Video Translator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-video-translator","href":"/api-reference/video-projects/ai-video-translator"},{"title":"AI Video Upscaler","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-video-upscaler","href":"/api-reference/video-projects/ai-video-upscaler"},{"title":"Animation","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/animation","href":"/api-reference/video-projects/animation"},{"title":"Audio-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/audio-to-video","href":"/api-reference/video-projects/audio-to-video"},{"title":"Auto Subtitle Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/auto-subtitle-generator","href":"/api-reference/video-projects/auto-subtitle-generator"},{"title":"Character Replace","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/character-replace","href":"/api-reference/video-projects/character-replace"},{"title":"Face Swap Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/face-swap","href":"/api-reference/video-projects/face-swap-video"},{"title":"Image-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/image-to-video","href":"/api-reference/video-projects/image-to-video"},{"title":"Lip Sync","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/lip-sync","href":"/api-reference/video-projects/lip-sync"},{"title":"Text-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/text-to-video","href":"/api-reference/video-projects/text-to-video"},{"title":"Video-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/video-to-video","href":"/api-reference/video-projects/video-to-video"}]},{"group":"Image Projects","pages":[{"title":"Get image details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/image-projects/{id}","href":"/api-reference/image-projects/get-image-details"},{"title":"Delete image","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json delete /v1/image-projects/{id}","href":"/api-reference/image-projects/delete-image"},{"title":"AI Clothes Changer","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-clothes-changer","href":"/api-reference/image-projects/ai-clothes-changer"},{"title":"AI Face Editor","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-face-editor","href":"/api-reference/image-projects/ai-face-editor"},{"title":"AI GIF Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-gif-generator","href":"/api-reference/image-projects/ai-gif-generator"},{"title":"AI Image Editor","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-image-editor","href":"/api-reference/image-projects/ai-image-editor"},{"title":"AI Headshot Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-headshot-generator","href":"/api-reference/image-projects/ai-headshot-generator"},{"title":"AI Image Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-image-generator","href":"/api-reference/image-projects/ai-image-generator"},{"title":"AI Image Upscaler","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-image-upscaler","href":"/api-reference/image-projects/ai-image-upscaler"},{"title":"AI Meme Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-meme-generator","href":"/api-reference/image-projects/ai-meme-generator"},{"title":"AI QR Code Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-qr-code-generator","href":"/api-reference/image-projects/ai-qr-code-generator"},{"title":"Body Swap","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/body-swap","href":"/api-reference/image-projects/body-swap"},{"title":"Face Swap Photo","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/face-swap-photo","href":"/api-reference/image-projects/face-swap-photo"},{"title":"Head Swap","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/head-swap","href":"/api-reference/image-projects/head-swap"},{"title":"Image Background Remover","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/image-background-remover","href":"/api-reference/image-projects/image-background-remover"},{"title":"Photo Colorizer","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/photo-colorizer","href":"/api-reference/image-projects/photo-colorizer"}]},{"group":"Audio Projects","pages":[{"title":"Get audio details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/audio-projects/{id}","href":"/api-reference/audio-projects/get-audio-details"},{"title":"Delete audio","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json delete /v1/audio-projects/{id}","href":"/api-reference/audio-projects/delete-audio"},{"title":"AI Music Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-music-generator","href":"/api-reference/audio-projects/ai-music-generator"},{"title":"AI Voice Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-voice-generator","href":"/api-reference/audio-projects/ai-voice-generator"},{"title":"AI Voice Cloner","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-voice-cloner","href":"/api-reference/audio-projects/ai-voice-cloner"}]}],"groups":[{"group":"Account","pages":[{"title":"Get account details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/account","href":"/api-reference/account/get-account-details"}]},{"group":"Files","pages":[{"title":"List saved items","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/saved-items","href":"/api-reference/files/list-saved-items"},{"title":"Generate asset upload urls","description":"Generates a list of pre-signed upload URLs for the assets required. This API is only necessary if you want to upload to Magic Hour's storage. Refer to the [Input Files Guide](https://docs.magichour.ai/integration/inputs-and-outputs) for more details.\n\nThe response array will match the order of items in the request body.\n\n**Valid file extensions per asset type**:\n- video: mp4, m4v, mov, webm\n- audio: mp3, wav, aac, flac, webm, weba, m4a, opus, ogg, oga, aiff, amr\n- image: png, jpg, jpeg, jpe, jfif, heic, heif, webp, avif, jp2, tiff, tif, bmp\n- gif: gif, webp, webm\n\n> Note: `gif` is only supported for face swap API `video_file_path` field.\n\nOnce you receive an upload URL, send a `PUT` request to upload the file directly.\n\nExample:\n\n```\ncurl -X PUT --data '@/path/to/file/video.mp4' \\\n https://videos.magichour.ai/api-assets/id/video.mp4?\u003cauth params from the API response>\n```\n","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/files/upload-urls","href":"/api-reference/files/generate-asset-upload-urls"},{"title":"Get face detection details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/face-detection/{id}","href":"/api-reference/files/get-face-detection-details"},{"title":"Face Detection","description":"Detect faces in an image or video. \n \nUse this API to get the list of faces detected in the image or video to use in the [face swap photo](https://docs.magichour.ai/api-reference/image-projects/face-swap-photo) or [face swap video](https://docs.magichour.ai/api-reference/video-projects/face-swap-video) API calls for multi-face swaps.\n\nNote: Face detection is free to use for the near future. Pricing may change in the future.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/face-detection","href":"/api-reference/files/face-detection"}]},{"group":"Video Projects","pages":[{"title":"Get video details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/video-projects/{id}","href":"/api-reference/video-projects/get-video-details"},{"title":"Delete video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json delete /v1/video-projects/{id}","href":"/api-reference/video-projects/delete-video"},{"title":"AI Talking Photo","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-talking-photo","href":"/api-reference/video-projects/ai-talking-photo"},{"title":"AI UGC Ad Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-ugc-ad","href":"/api-reference/video-projects/ai-ugc-ad-generator"},{"title":"AI Video Editor","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-video-editor","href":"/api-reference/video-projects/ai-video-editor"},{"title":"AI Video Translator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-video-translator","href":"/api-reference/video-projects/ai-video-translator"},{"title":"AI Video Upscaler","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-video-upscaler","href":"/api-reference/video-projects/ai-video-upscaler"},{"title":"Animation","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/animation","href":"/api-reference/video-projects/animation"},{"title":"Audio-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/audio-to-video","href":"/api-reference/video-projects/audio-to-video"},{"title":"Auto Subtitle Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/auto-subtitle-generator","href":"/api-reference/video-projects/auto-subtitle-generator"},{"title":"Character Replace","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/character-replace","href":"/api-reference/video-projects/character-replace"},{"title":"Face Swap Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/face-swap","href":"/api-reference/video-projects/face-swap-video"},{"title":"Image-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/image-to-video","href":"/api-reference/video-projects/image-to-video"},{"title":"Lip Sync","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/lip-sync","href":"/api-reference/video-projects/lip-sync"},{"title":"Text-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/text-to-video","href":"/api-reference/video-projects/text-to-video"},{"title":"Video-to-Video","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/video-to-video","href":"/api-reference/video-projects/video-to-video"}]},{"group":"Image Projects","pages":[{"title":"Get image details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/image-projects/{id}","href":"/api-reference/image-projects/get-image-details"},{"title":"Delete image","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json delete /v1/image-projects/{id}","href":"/api-reference/image-projects/delete-image"},{"title":"AI Clothes Changer","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-clothes-changer","href":"/api-reference/image-projects/ai-clothes-changer"},{"title":"AI Face Editor","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-face-editor","href":"/api-reference/image-projects/ai-face-editor"},{"title":"AI GIF Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-gif-generator","href":"/api-reference/image-projects/ai-gif-generator"},{"title":"AI Image Editor","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-image-editor","href":"/api-reference/image-projects/ai-image-editor"},{"title":"AI Headshot Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-headshot-generator","href":"/api-reference/image-projects/ai-headshot-generator"},{"title":"AI Image Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-image-generator","href":"/api-reference/image-projects/ai-image-generator"},{"title":"AI Image Upscaler","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-image-upscaler","href":"/api-reference/image-projects/ai-image-upscaler"},{"title":"AI Meme Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-meme-generator","href":"/api-reference/image-projects/ai-meme-generator"},{"title":"AI QR Code Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-qr-code-generator","href":"/api-reference/image-projects/ai-qr-code-generator"},{"title":"Body Swap","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/body-swap","href":"/api-reference/image-projects/body-swap"},{"title":"Face Swap Photo","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/face-swap-photo","href":"/api-reference/image-projects/face-swap-photo"},{"title":"Head Swap","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/head-swap","href":"/api-reference/image-projects/head-swap"},{"title":"Image Background Remover","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/image-background-remover","href":"/api-reference/image-projects/image-background-remover"},{"title":"Photo Colorizer","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/photo-colorizer","href":"/api-reference/image-projects/photo-colorizer"}]},{"group":"Audio Projects","pages":[{"title":"Get audio details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json get /v1/audio-projects/{id}","href":"/api-reference/audio-projects/get-audio-details"},{"title":"Delete audio","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json delete /v1/audio-projects/{id}","href":"/api-reference/audio-projects/delete-audio"},{"title":"AI Music Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-music-generator","href":"/api-reference/audio-projects/ai-music-generator"},{"title":"AI Voice Cloner","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-voice-cloner","href":"/api-reference/audio-projects/ai-voice-cloner"},{"title":"AI Voice Generator","deprecated":null,"version":null,"openapi":"/api-reference/openapi.json post /v1/ai-voice-generator","href":"/api-reference/audio-projects/ai-voice-generator"}]}]},{"tab":"Webhook Reference","pages":[{"title":"Webhook Reference","href":"/webhook-reference/overview"}]},{"tab":"Changelog","pages":[{"title":"Changelog","href":"/changelog"}]}]},"basePath":"","title":"Get face detection details - Magic Hour API Docs","buildId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","deploymentId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CS552b7R.js","utils-DDTCYAF2.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-De8ttokP.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-DrwRDvAh.js","snippetPresets-DtAN0nWx.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-D5rWArI6.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-O2i12wsz.js","shallow-DV8xABTt.js","getApiPlaygroundDisplay-DBZ0B5Jx.js","CodeSnippet-BVi0tPUX.js","CodeSnippets-CqASbIwY.js","Page-m07pfKpT.js","getPastedJson-DG9vsMS8.js","icon-CXzRSCr8.js","MethodPill-BdKVtEuX.js","DuplicateIcon-CZlmBrJI.js","createIcon-biFEUKPL.js","DynamicMarkdown-B54_zNBF.js","SectionHeading-DwwHK3Pt.js","axios-vUo_bRtp.js","Markdown-DfhCTwyA.js","clsx-xpJZXxdP.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-BTZUMDnx.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-DqdKa2R4.js"]}