magic_hour 0.39.0__tar.gz → 0.41.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of magic_hour might be problematic. Click here for more details.
- {magic_hour-0.39.0 → magic_hour-0.41.0}/PKG-INFO +11 -1
- {magic_hour-0.39.0 → magic_hour-0.41.0}/README.md +10 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/environment.py +1 -1
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_clothes_changer/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_face_editor/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_gif_generator/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_headshot_generator/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_editor/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_generator/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_upscaler/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_meme_generator/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_photo_editor/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_qr_code_generator/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_talking_photo/README.md +4 -2
- magic_hour-0.41.0/magic_hour/resources/v1/ai_voice_generator/README.md +56 -0
- magic_hour-0.41.0/magic_hour/resources/v1/ai_voice_generator/__init__.py +4 -0
- magic_hour-0.41.0/magic_hour/resources/v1/ai_voice_generator/client.py +119 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/animation/README.md +2 -0
- magic_hour-0.41.0/magic_hour/resources/v1/audio_projects/README.md +90 -0
- magic_hour-0.41.0/magic_hour/resources/v1/audio_projects/__init__.py +4 -0
- magic_hour-0.41.0/magic_hour/resources/v1/audio_projects/client.py +173 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/auto_subtitle_generator/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/client.py +14 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_detection/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_swap/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_swap_photo/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/files/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_background_remover/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_projects/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_to_video/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/lip_sync/README.md +4 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/lip_sync/client.py +10 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/photo_colorizer/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/text_to_video/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/video_projects/README.md +2 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/video_to_video/README.md +7 -7
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/video_to_video/client.py +0 -2
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/__init__.py +10 -0
- magic_hour-0.41.0/magic_hour/types/models/v1_ai_voice_generator_create_response.py +27 -0
- magic_hour-0.41.0/magic_hour/types/models/v1_audio_projects_get_response.py +72 -0
- magic_hour-0.41.0/magic_hour/types/models/v1_audio_projects_get_response_downloads_item.py +19 -0
- magic_hour-0.41.0/magic_hour/types/models/v1_audio_projects_get_response_error.py +25 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/__init__.py +18 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_talking_photo_create_body_style.py +6 -4
- magic_hour-0.41.0/magic_hour/types/params/v1_ai_voice_generator_create_body.py +40 -0
- magic_hour-0.41.0/magic_hour/types/params/v1_ai_voice_generator_create_body_style.py +60 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_lip_sync_create_body.py +12 -0
- magic_hour-0.41.0/magic_hour/types/params/v1_lip_sync_create_body_style.py +37 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_video_to_video_create_body_style.py +19 -19
- {magic_hour-0.39.0 → magic_hour-0.41.0}/pyproject.toml +1 -1
- {magic_hour-0.39.0 → magic_hour-0.41.0}/LICENSE +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/helpers/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/helpers/download.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/helpers/logger.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_clothes_changer/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_clothes_changer/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_face_editor/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_face_editor/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_gif_generator/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_gif_generator/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_headshot_generator/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_headshot_generator/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_editor/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_editor/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_generator/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_generator/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_upscaler/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_image_upscaler/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_meme_generator/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_meme_generator/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_photo_editor/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_photo_editor/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_qr_code_generator/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_qr_code_generator/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_talking_photo/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/ai_talking_photo/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/animation/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/animation/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/auto_subtitle_generator/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/auto_subtitle_generator/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_detection/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_detection/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_swap/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_swap/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_swap_photo/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/face_swap_photo/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/files/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/files/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/files/client_test.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/files/upload_urls/README.md +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/files/upload_urls/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/files/upload_urls/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_background_remover/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_background_remover/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_projects/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_projects/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_projects/client_test.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_to_video/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/image_to_video/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/lip_sync/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/photo_colorizer/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/photo_colorizer/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/text_to_video/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/text_to_video/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/video_projects/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/video_projects/client.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/video_projects/client_test.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/resources/v1/video_to_video/__init__.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_clothes_changer_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_face_editor_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_gif_generator_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_headshot_generator_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_image_editor_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_image_generator_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_image_upscaler_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_meme_generator_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_photo_editor_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_qr_code_generator_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_ai_talking_photo_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_animation_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_auto_subtitle_generator_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_face_detection_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_face_detection_get_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_face_detection_get_response_faces_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_face_swap_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_face_swap_photo_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_files_upload_urls_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_files_upload_urls_create_response_items_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_image_background_remover_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_image_projects_get_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_image_projects_get_response_downloads_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_image_projects_get_response_error.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_image_to_video_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_lip_sync_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_photo_colorizer_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_text_to_video_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_video_projects_get_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_video_projects_get_response_download.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_video_projects_get_response_downloads_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_video_projects_get_response_error.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/models/v1_video_to_video_create_response.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_clothes_changer_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_clothes_changer_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_clothes_changer_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_face_editor_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_face_editor_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_face_editor_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_face_editor_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_gif_generator_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_gif_generator_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_headshot_generator_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_headshot_generator_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_headshot_generator_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_headshot_generator_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_editor_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_editor_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_editor_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_editor_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_generator_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_generator_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_upscaler_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_upscaler_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_upscaler_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_image_upscaler_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_meme_generator_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_meme_generator_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_photo_editor_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_photo_editor_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_photo_editor_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_photo_editor_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_qr_code_generator_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_qr_code_generator_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_talking_photo_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_talking_photo_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_ai_talking_photo_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_animation_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_animation_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_animation_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_animation_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_auto_subtitle_generator_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_auto_subtitle_generator_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_auto_subtitle_generator_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_auto_subtitle_generator_create_body_style_custom_config.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_auto_subtitle_generator_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_detection_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_detection_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_detection_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_create_body_assets_face_mappings_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_generate_body_assets_face_mappings_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_photo_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_photo_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_photo_create_body_assets_face_mappings_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_photo_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_face_swap_photo_generate_body_assets_face_mappings_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_files_upload_urls_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_files_upload_urls_create_body_items_item.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_image_background_remover_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_image_background_remover_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_image_background_remover_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_image_to_video_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_image_to_video_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_image_to_video_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_image_to_video_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_lip_sync_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_lip_sync_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_photo_colorizer_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_photo_colorizer_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_photo_colorizer_generate_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_text_to_video_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_text_to_video_create_body_style.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_video_to_video_create_body.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_video_to_video_create_body_assets.py +0 -0
- {magic_hour-0.39.0 → magic_hour-0.41.0}/magic_hour/types/params/v1_video_to_video_generate_body_assets.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: magic_hour
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.41.0
|
|
4
4
|
Summary: Python SDK for Magic Hour API
|
|
5
5
|
Requires-Python: >=3.8,<4.0
|
|
6
6
|
Classifier: Programming Language :: Python :: 3
|
|
@@ -223,11 +223,21 @@ download_urls = result.downloads
|
|
|
223
223
|
* [create](magic_hour/resources/v1/ai_talking_photo/README.md#create) - AI Talking Photo
|
|
224
224
|
* [generate](magic_hour/resources/v1/ai_talking_photo/README.md#generate) - Ai Talking Photo Generate Workflow
|
|
225
225
|
|
|
226
|
+
### [v1.ai_voice_generator](magic_hour/resources/v1/ai_voice_generator/README.md)
|
|
227
|
+
|
|
228
|
+
* [create](magic_hour/resources/v1/ai_voice_generator/README.md#create) - AI Voice Generator
|
|
229
|
+
|
|
226
230
|
### [v1.animation](magic_hour/resources/v1/animation/README.md)
|
|
227
231
|
|
|
228
232
|
* [create](magic_hour/resources/v1/animation/README.md#create) - Animation
|
|
229
233
|
* [generate](magic_hour/resources/v1/animation/README.md#generate) - Animation Generate Workflow
|
|
230
234
|
|
|
235
|
+
### [v1.audio_projects](magic_hour/resources/v1/audio_projects/README.md)
|
|
236
|
+
|
|
237
|
+
* [delete](magic_hour/resources/v1/audio_projects/README.md#delete) - Delete audio
|
|
238
|
+
* [get](magic_hour/resources/v1/audio_projects/README.md#get) - Get audio details
|
|
239
|
+
|
|
240
|
+
|
|
231
241
|
### [v1.auto_subtitle_generator](magic_hour/resources/v1/auto_subtitle_generator/README.md)
|
|
232
242
|
|
|
233
243
|
* [create](magic_hour/resources/v1/auto_subtitle_generator/README.md#create) - Auto Subtitle Generator
|
|
@@ -208,11 +208,21 @@ download_urls = result.downloads
|
|
|
208
208
|
* [create](magic_hour/resources/v1/ai_talking_photo/README.md#create) - AI Talking Photo
|
|
209
209
|
* [generate](magic_hour/resources/v1/ai_talking_photo/README.md#generate) - Ai Talking Photo Generate Workflow
|
|
210
210
|
|
|
211
|
+
### [v1.ai_voice_generator](magic_hour/resources/v1/ai_voice_generator/README.md)
|
|
212
|
+
|
|
213
|
+
* [create](magic_hour/resources/v1/ai_voice_generator/README.md#create) - AI Voice Generator
|
|
214
|
+
|
|
211
215
|
### [v1.animation](magic_hour/resources/v1/animation/README.md)
|
|
212
216
|
|
|
213
217
|
* [create](magic_hour/resources/v1/animation/README.md#create) - Animation
|
|
214
218
|
* [generate](magic_hour/resources/v1/animation/README.md#generate) - Animation Generate Workflow
|
|
215
219
|
|
|
220
|
+
### [v1.audio_projects](magic_hour/resources/v1/audio_projects/README.md)
|
|
221
|
+
|
|
222
|
+
* [delete](magic_hour/resources/v1/audio_projects/README.md#delete) - Delete audio
|
|
223
|
+
* [get](magic_hour/resources/v1/audio_projects/README.md#get) - Get audio details
|
|
224
|
+
|
|
225
|
+
|
|
216
226
|
### [v1.auto_subtitle_generator](magic_hour/resources/v1/auto_subtitle_generator/README.md)
|
|
217
227
|
|
|
218
228
|
* [create](magic_hour/resources/v1/auto_subtitle_generator/README.md#create) - Auto Subtitle Generator
|
|
@@ -14,7 +14,9 @@
|
|
|
14
14
|
- [ai_photo_editor](resources/v1/ai_photo_editor/README.md) - ai_photo_editor
|
|
15
15
|
- [ai_qr_code_generator](resources/v1/ai_qr_code_generator/README.md) - ai_qr_code_generator
|
|
16
16
|
- [ai_talking_photo](resources/v1/ai_talking_photo/README.md) - ai_talking_photo
|
|
17
|
+
- [ai_voice_generator](resources/v1/ai_voice_generator/README.md) - ai_voice_generator
|
|
17
18
|
- [animation](resources/v1/animation/README.md) - animation
|
|
19
|
+
- [audio_projects](resources/v1/audio_projects/README.md) - audio_projects
|
|
18
20
|
- [auto_subtitle_generator](resources/v1/auto_subtitle_generator/README.md) - auto_subtitle_generator
|
|
19
21
|
- [face_detection](resources/v1/face_detection/README.md) - face_detection
|
|
20
22
|
- [face_swap](resources/v1/face_swap/README.md) - face_swap
|
|
@@ -6,7 +6,7 @@ class Environment(enum.Enum):
|
|
|
6
6
|
"""Pre-defined base URLs for the API"""
|
|
7
7
|
|
|
8
8
|
ENVIRONMENT = "https://api.magichour.ai"
|
|
9
|
-
MOCK_SERVER = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.
|
|
9
|
+
MOCK_SERVER = "https://api.sideko.dev/v1/mock/magichour/magic-hour/0.41.0"
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
def _get_base_url(
|
|
@@ -14,7 +14,9 @@
|
|
|
14
14
|
- [ai_photo_editor](ai_photo_editor/README.md) - ai_photo_editor
|
|
15
15
|
- [ai_qr_code_generator](ai_qr_code_generator/README.md) - ai_qr_code_generator
|
|
16
16
|
- [ai_talking_photo](ai_talking_photo/README.md) - ai_talking_photo
|
|
17
|
+
- [ai_voice_generator](ai_voice_generator/README.md) - ai_voice_generator
|
|
17
18
|
- [animation](animation/README.md) - animation
|
|
19
|
+
- [audio_projects](audio_projects/README.md) - audio_projects
|
|
18
20
|
- [auto_subtitle_generator](auto_subtitle_generator/README.md) - auto_subtitle_generator
|
|
19
21
|
- [face_detection](face_detection/README.md) - face_detection
|
|
20
22
|
- [face_swap](face_swap/README.md) - face_swap
|
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
## Module Functions
|
|
4
4
|
|
|
5
5
|
|
|
6
|
+
|
|
7
|
+
|
|
6
8
|
<!-- CUSTOM DOCS START -->
|
|
7
9
|
|
|
8
10
|
### Ai Talking Photo Generate Workflow <a name="generate"></a>
|
|
@@ -84,8 +86,8 @@ Create a talking photo from an image and audio or text input.
|
|
|
84
86
|
| `end_seconds` | ✓ | The end time of the input audio in seconds. The maximum duration allowed is 60 seconds. | `15.0` |
|
|
85
87
|
| `start_seconds` | ✓ | The start time of the input audio in seconds. The maximum duration allowed is 60 seconds. | `0.0` |
|
|
86
88
|
| `name` | ✗ | The name of image. This value is mainly used for your own identification of the image. | `"Talking Photo image"` |
|
|
87
|
-
| `style` | ✗ | Attributes used to dictate the style of the output | `{"generation_mode": "
|
|
88
|
-
| `└─ generation_mode` | ✗ | Controls overall motion style. * `pro` -
|
|
89
|
+
| `style` | ✗ | Attributes used to dictate the style of the output | `{"generation_mode": "pro", "intensity": 1.5}` |
|
|
90
|
+
| `└─ generation_mode` | ✗ | Controls overall motion style. * `pro` - Higher fidelity, realistic detail, accurate lip sync, and faster generation. * `standard` - More expressive motion, but lower visual fidelity. * `expressive` - More motion and facial expressiveness; may introduce visual artifacts. (Deprecated: passing this value will be treated as `standard`) * `stable` - Reduced motion for cleaner output; may result in minimal animation. (Deprecated: passing this value will be treated as `pro`) | `"pro"` |
|
|
89
91
|
| `└─ intensity` | ✗ | Note: this value is only applicable when generation_mode is `expressive`. The value can include up to 2 decimal places. * Lower values yield more stability but can suppress mouth movement. * Higher values increase motion and expressiveness, with a higher risk of distortion. | `1.5` |
|
|
90
92
|
|
|
91
93
|
#### Synchronous Client
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# v1.ai_voice_generator
|
|
2
|
+
|
|
3
|
+
## Module Functions
|
|
4
|
+
|
|
5
|
+
### AI Voice Generator <a name="create"></a>
|
|
6
|
+
|
|
7
|
+
Generate speech from text. Each character costs 0.05 credits. The cost is rounded up to the nearest whole number.
|
|
8
|
+
|
|
9
|
+
**API Endpoint**: `POST /v1/ai-voice-generator`
|
|
10
|
+
|
|
11
|
+
#### Parameters
|
|
12
|
+
|
|
13
|
+
| Parameter | Required | Description | Example |
|
|
14
|
+
|-----------|:--------:|-------------|--------|
|
|
15
|
+
| `style` | ✓ | The content used to generate speech. | `{"prompt": "Hello, how are you?", "voice_name": "Elon Musk"}` |
|
|
16
|
+
| `└─ prompt` | ✓ | Text used to generate speech. Starter tier users can use up to 200 characters, while Creator, Pro, or Business users can use up to 1000. | `"Hello, how are you?"` |
|
|
17
|
+
| `└─ voice_name` | ✓ | The voice to use for the speech. Available voices: Elon Musk, Mark Zuckerberg, Joe Rogan, Barack Obama, Morgan Freeman, Kanye West, Donald Trump, Joe Biden, Kim Kardashian, Taylor Swift | `"Elon Musk"` |
|
|
18
|
+
| `name` | ✗ | The name of audio. This value is mainly used for your own identification of the audio. | `"Voice Generator audio"` |
|
|
19
|
+
|
|
20
|
+
#### Synchronous Client
|
|
21
|
+
|
|
22
|
+
```python
|
|
23
|
+
from magic_hour import Client
|
|
24
|
+
from os import getenv
|
|
25
|
+
|
|
26
|
+
client = Client(token=getenv("API_TOKEN"))
|
|
27
|
+
res = client.v1.ai_voice_generator.create(
|
|
28
|
+
style={"prompt": "Hello, how are you?", "voice_name": "Elon Musk"},
|
|
29
|
+
name="Voice Generator audio",
|
|
30
|
+
)
|
|
31
|
+
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
#### Asynchronous Client
|
|
35
|
+
|
|
36
|
+
```python
|
|
37
|
+
from magic_hour import AsyncClient
|
|
38
|
+
from os import getenv
|
|
39
|
+
|
|
40
|
+
client = AsyncClient(token=getenv("API_TOKEN"))
|
|
41
|
+
res = await client.v1.ai_voice_generator.create(
|
|
42
|
+
style={"prompt": "Hello, how are you?", "voice_name": "Elon Musk"},
|
|
43
|
+
name="Voice Generator audio",
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
#### Response
|
|
49
|
+
|
|
50
|
+
##### Type
|
|
51
|
+
[V1AiVoiceGeneratorCreateResponse](/magic_hour/types/models/v1_ai_voice_generator_create_response.py)
|
|
52
|
+
|
|
53
|
+
##### Example
|
|
54
|
+
`{"credits_charged": 1, "id": "cuid-example"}`
|
|
55
|
+
|
|
56
|
+
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import typing
|
|
2
|
+
|
|
3
|
+
from magic_hour.types import models, params
|
|
4
|
+
from make_api_request import (
|
|
5
|
+
AsyncBaseClient,
|
|
6
|
+
RequestOptions,
|
|
7
|
+
SyncBaseClient,
|
|
8
|
+
default_request_options,
|
|
9
|
+
to_encodable,
|
|
10
|
+
type_utils,
|
|
11
|
+
)
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class AiVoiceGeneratorClient:
|
|
15
|
+
def __init__(self, *, base_client: SyncBaseClient):
|
|
16
|
+
self._base_client = base_client
|
|
17
|
+
|
|
18
|
+
def create(
|
|
19
|
+
self,
|
|
20
|
+
*,
|
|
21
|
+
style: params.V1AiVoiceGeneratorCreateBodyStyle,
|
|
22
|
+
name: typing.Union[
|
|
23
|
+
typing.Optional[str], type_utils.NotGiven
|
|
24
|
+
] = type_utils.NOT_GIVEN,
|
|
25
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
26
|
+
) -> models.V1AiVoiceGeneratorCreateResponse:
|
|
27
|
+
"""
|
|
28
|
+
AI Voice Generator
|
|
29
|
+
|
|
30
|
+
Generate speech from text. Each character costs 0.05 credits. The cost is rounded up to the nearest whole number.
|
|
31
|
+
|
|
32
|
+
POST /v1/ai-voice-generator
|
|
33
|
+
|
|
34
|
+
Args:
|
|
35
|
+
name: The name of audio. This value is mainly used for your own identification of the audio.
|
|
36
|
+
style: The content used to generate speech.
|
|
37
|
+
request_options: Additional options to customize the HTTP request
|
|
38
|
+
|
|
39
|
+
Returns:
|
|
40
|
+
Success
|
|
41
|
+
|
|
42
|
+
Raises:
|
|
43
|
+
ApiError: A custom exception class that provides additional context
|
|
44
|
+
for API errors, including the HTTP status code and response body.
|
|
45
|
+
|
|
46
|
+
Examples:
|
|
47
|
+
```py
|
|
48
|
+
client.v1.ai_voice_generator.create(
|
|
49
|
+
style={"prompt": "Hello, how are you?", "voice_name": "Elon Musk"},
|
|
50
|
+
name="Voice Generator audio",
|
|
51
|
+
)
|
|
52
|
+
```
|
|
53
|
+
"""
|
|
54
|
+
_json = to_encodable(
|
|
55
|
+
item={"name": name, "style": style},
|
|
56
|
+
dump_with=params._SerializerV1AiVoiceGeneratorCreateBody,
|
|
57
|
+
)
|
|
58
|
+
return self._base_client.request(
|
|
59
|
+
method="POST",
|
|
60
|
+
path="/v1/ai-voice-generator",
|
|
61
|
+
auth_names=["bearerAuth"],
|
|
62
|
+
json=_json,
|
|
63
|
+
cast_to=models.V1AiVoiceGeneratorCreateResponse,
|
|
64
|
+
request_options=request_options or default_request_options(),
|
|
65
|
+
)
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
class AsyncAiVoiceGeneratorClient:
|
|
69
|
+
def __init__(self, *, base_client: AsyncBaseClient):
|
|
70
|
+
self._base_client = base_client
|
|
71
|
+
|
|
72
|
+
async def create(
|
|
73
|
+
self,
|
|
74
|
+
*,
|
|
75
|
+
style: params.V1AiVoiceGeneratorCreateBodyStyle,
|
|
76
|
+
name: typing.Union[
|
|
77
|
+
typing.Optional[str], type_utils.NotGiven
|
|
78
|
+
] = type_utils.NOT_GIVEN,
|
|
79
|
+
request_options: typing.Optional[RequestOptions] = None,
|
|
80
|
+
) -> models.V1AiVoiceGeneratorCreateResponse:
|
|
81
|
+
"""
|
|
82
|
+
AI Voice Generator
|
|
83
|
+
|
|
84
|
+
Generate speech from text. Each character costs 0.05 credits. The cost is rounded up to the nearest whole number.
|
|
85
|
+
|
|
86
|
+
POST /v1/ai-voice-generator
|
|
87
|
+
|
|
88
|
+
Args:
|
|
89
|
+
name: The name of audio. This value is mainly used for your own identification of the audio.
|
|
90
|
+
style: The content used to generate speech.
|
|
91
|
+
request_options: Additional options to customize the HTTP request
|
|
92
|
+
|
|
93
|
+
Returns:
|
|
94
|
+
Success
|
|
95
|
+
|
|
96
|
+
Raises:
|
|
97
|
+
ApiError: A custom exception class that provides additional context
|
|
98
|
+
for API errors, including the HTTP status code and response body.
|
|
99
|
+
|
|
100
|
+
Examples:
|
|
101
|
+
```py
|
|
102
|
+
await client.v1.ai_voice_generator.create(
|
|
103
|
+
style={"prompt": "Hello, how are you?", "voice_name": "Elon Musk"},
|
|
104
|
+
name="Voice Generator audio",
|
|
105
|
+
)
|
|
106
|
+
```
|
|
107
|
+
"""
|
|
108
|
+
_json = to_encodable(
|
|
109
|
+
item={"name": name, "style": style},
|
|
110
|
+
dump_with=params._SerializerV1AiVoiceGeneratorCreateBody,
|
|
111
|
+
)
|
|
112
|
+
return await self._base_client.request(
|
|
113
|
+
method="POST",
|
|
114
|
+
path="/v1/ai-voice-generator",
|
|
115
|
+
auth_names=["bearerAuth"],
|
|
116
|
+
json=_json,
|
|
117
|
+
cast_to=models.V1AiVoiceGeneratorCreateResponse,
|
|
118
|
+
request_options=request_options or default_request_options(),
|
|
119
|
+
)
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
# v1.audio_projects
|
|
2
|
+
|
|
3
|
+
## Module Functions
|
|
4
|
+
|
|
5
|
+
### Delete audio <a name="delete"></a>
|
|
6
|
+
|
|
7
|
+
Permanently delete the rendered audio file(s). This action is not reversible, please be sure before deleting.
|
|
8
|
+
|
|
9
|
+
**API Endpoint**: `DELETE /v1/audio-projects/{id}`
|
|
10
|
+
|
|
11
|
+
#### Parameters
|
|
12
|
+
|
|
13
|
+
| Parameter | Required | Description | Example |
|
|
14
|
+
|-----------|:--------:|-------------|--------|
|
|
15
|
+
| `id` | ✓ | Unique ID of the audio project. This value is returned by all of the POST APIs that create an audio. | `"cuid-example"` |
|
|
16
|
+
|
|
17
|
+
#### Synchronous Client
|
|
18
|
+
|
|
19
|
+
```python
|
|
20
|
+
from magic_hour import Client
|
|
21
|
+
from os import getenv
|
|
22
|
+
|
|
23
|
+
client = Client(token=getenv("API_TOKEN"))
|
|
24
|
+
res = client.v1.audio_projects.delete(id="cuid-example")
|
|
25
|
+
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
#### Asynchronous Client
|
|
29
|
+
|
|
30
|
+
```python
|
|
31
|
+
from magic_hour import AsyncClient
|
|
32
|
+
from os import getenv
|
|
33
|
+
|
|
34
|
+
client = AsyncClient(token=getenv("API_TOKEN"))
|
|
35
|
+
res = await client.v1.audio_projects.delete(id="cuid-example")
|
|
36
|
+
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### Get audio details <a name="get"></a>
|
|
40
|
+
|
|
41
|
+
Get the details of a audio project. The `downloads` field will be empty unless the audio was successfully rendered.
|
|
42
|
+
|
|
43
|
+
The audio can be one of the following status
|
|
44
|
+
- `draft` - not currently used
|
|
45
|
+
- `queued` - the job is queued and waiting for a GPU
|
|
46
|
+
- `rendering` - the generation is in progress
|
|
47
|
+
- `complete` - the audio is successful created
|
|
48
|
+
- `error` - an error occurred during rendering
|
|
49
|
+
- `canceled` - audio render is canceled by the user
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
**API Endpoint**: `GET /v1/audio-projects/{id}`
|
|
53
|
+
|
|
54
|
+
#### Parameters
|
|
55
|
+
|
|
56
|
+
| Parameter | Required | Description | Example |
|
|
57
|
+
|-----------|:--------:|-------------|--------|
|
|
58
|
+
| `id` | ✓ | Unique ID of the audio project. This value is returned by all of the POST APIs that create an audio. | `"cuid-example"` |
|
|
59
|
+
|
|
60
|
+
#### Synchronous Client
|
|
61
|
+
|
|
62
|
+
```python
|
|
63
|
+
from magic_hour import Client
|
|
64
|
+
from os import getenv
|
|
65
|
+
|
|
66
|
+
client = Client(token=getenv("API_TOKEN"))
|
|
67
|
+
res = client.v1.audio_projects.get(id="cuid-example")
|
|
68
|
+
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
#### Asynchronous Client
|
|
72
|
+
|
|
73
|
+
```python
|
|
74
|
+
from magic_hour import AsyncClient
|
|
75
|
+
from os import getenv
|
|
76
|
+
|
|
77
|
+
client = AsyncClient(token=getenv("API_TOKEN"))
|
|
78
|
+
res = await client.v1.audio_projects.get(id="cuid-example")
|
|
79
|
+
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
#### Response
|
|
83
|
+
|
|
84
|
+
##### Type
|
|
85
|
+
[V1AudioProjectsGetResponse](/magic_hour/types/models/v1_audio_projects_get_response.py)
|
|
86
|
+
|
|
87
|
+
##### Example
|
|
88
|
+
`{"created_at": "1970-01-01T00:00:00", "credits_charged": 2, "downloads": [{"expires_at": "2024-10-19T05:16:19.027Z", "url": "https://videos.magichour.ai/id/output.wav"}], "enabled": True, "error": {"code": "no_source_face", "message": "Please use an image with a detectable face"}, "id": "cuid-example", "name": "Example Name", "status": "complete", "type_": "VOICE_GENERATOR"}`
|
|
89
|
+
|
|
90
|
+
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
import typing
|
|
2
|
+
|
|
3
|
+
from magic_hour.types import models
|
|
4
|
+
from make_api_request import (
|
|
5
|
+
AsyncBaseClient,
|
|
6
|
+
RequestOptions,
|
|
7
|
+
SyncBaseClient,
|
|
8
|
+
default_request_options,
|
|
9
|
+
)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class AudioProjectsClient:
|
|
13
|
+
def __init__(self, *, base_client: SyncBaseClient):
|
|
14
|
+
self._base_client = base_client
|
|
15
|
+
|
|
16
|
+
def delete(
|
|
17
|
+
self, *, id: str, request_options: typing.Optional[RequestOptions] = None
|
|
18
|
+
) -> None:
|
|
19
|
+
"""
|
|
20
|
+
Delete audio
|
|
21
|
+
|
|
22
|
+
Permanently delete the rendered audio file(s). This action is not reversible, please be sure before deleting.
|
|
23
|
+
|
|
24
|
+
DELETE /v1/audio-projects/{id}
|
|
25
|
+
|
|
26
|
+
Args:
|
|
27
|
+
id: Unique ID of the audio project. This value is returned by all of the POST APIs that create an audio.
|
|
28
|
+
request_options: Additional options to customize the HTTP request
|
|
29
|
+
|
|
30
|
+
Returns:
|
|
31
|
+
204
|
|
32
|
+
|
|
33
|
+
Raises:
|
|
34
|
+
ApiError: A custom exception class that provides additional context
|
|
35
|
+
for API errors, including the HTTP status code and response body.
|
|
36
|
+
|
|
37
|
+
Examples:
|
|
38
|
+
```py
|
|
39
|
+
client.v1.audio_projects.delete(id="cuid-example")
|
|
40
|
+
```
|
|
41
|
+
"""
|
|
42
|
+
self._base_client.request(
|
|
43
|
+
method="DELETE",
|
|
44
|
+
path=f"/v1/audio-projects/{id}",
|
|
45
|
+
auth_names=["bearerAuth"],
|
|
46
|
+
cast_to=type(None),
|
|
47
|
+
request_options=request_options or default_request_options(),
|
|
48
|
+
)
|
|
49
|
+
|
|
50
|
+
def get(
|
|
51
|
+
self, *, id: str, request_options: typing.Optional[RequestOptions] = None
|
|
52
|
+
) -> models.V1AudioProjectsGetResponse:
|
|
53
|
+
"""
|
|
54
|
+
Get audio details
|
|
55
|
+
|
|
56
|
+
Get the details of a audio project. The `downloads` field will be empty unless the audio was successfully rendered.
|
|
57
|
+
|
|
58
|
+
The audio can be one of the following status
|
|
59
|
+
- `draft` - not currently used
|
|
60
|
+
- `queued` - the job is queued and waiting for a GPU
|
|
61
|
+
- `rendering` - the generation is in progress
|
|
62
|
+
- `complete` - the audio is successful created
|
|
63
|
+
- `error` - an error occurred during rendering
|
|
64
|
+
- `canceled` - audio render is canceled by the user
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
GET /v1/audio-projects/{id}
|
|
68
|
+
|
|
69
|
+
Args:
|
|
70
|
+
id: Unique ID of the audio project. This value is returned by all of the POST APIs that create an audio.
|
|
71
|
+
request_options: Additional options to customize the HTTP request
|
|
72
|
+
|
|
73
|
+
Returns:
|
|
74
|
+
Success
|
|
75
|
+
|
|
76
|
+
Raises:
|
|
77
|
+
ApiError: A custom exception class that provides additional context
|
|
78
|
+
for API errors, including the HTTP status code and response body.
|
|
79
|
+
|
|
80
|
+
Examples:
|
|
81
|
+
```py
|
|
82
|
+
client.v1.audio_projects.get(id="cuid-example")
|
|
83
|
+
```
|
|
84
|
+
"""
|
|
85
|
+
return self._base_client.request(
|
|
86
|
+
method="GET",
|
|
87
|
+
path=f"/v1/audio-projects/{id}",
|
|
88
|
+
auth_names=["bearerAuth"],
|
|
89
|
+
cast_to=models.V1AudioProjectsGetResponse,
|
|
90
|
+
request_options=request_options or default_request_options(),
|
|
91
|
+
)
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
class AsyncAudioProjectsClient:
|
|
95
|
+
def __init__(self, *, base_client: AsyncBaseClient):
|
|
96
|
+
self._base_client = base_client
|
|
97
|
+
|
|
98
|
+
async def delete(
|
|
99
|
+
self, *, id: str, request_options: typing.Optional[RequestOptions] = None
|
|
100
|
+
) -> None:
|
|
101
|
+
"""
|
|
102
|
+
Delete audio
|
|
103
|
+
|
|
104
|
+
Permanently delete the rendered audio file(s). This action is not reversible, please be sure before deleting.
|
|
105
|
+
|
|
106
|
+
DELETE /v1/audio-projects/{id}
|
|
107
|
+
|
|
108
|
+
Args:
|
|
109
|
+
id: Unique ID of the audio project. This value is returned by all of the POST APIs that create an audio.
|
|
110
|
+
request_options: Additional options to customize the HTTP request
|
|
111
|
+
|
|
112
|
+
Returns:
|
|
113
|
+
204
|
|
114
|
+
|
|
115
|
+
Raises:
|
|
116
|
+
ApiError: A custom exception class that provides additional context
|
|
117
|
+
for API errors, including the HTTP status code and response body.
|
|
118
|
+
|
|
119
|
+
Examples:
|
|
120
|
+
```py
|
|
121
|
+
await client.v1.audio_projects.delete(id="cuid-example")
|
|
122
|
+
```
|
|
123
|
+
"""
|
|
124
|
+
await self._base_client.request(
|
|
125
|
+
method="DELETE",
|
|
126
|
+
path=f"/v1/audio-projects/{id}",
|
|
127
|
+
auth_names=["bearerAuth"],
|
|
128
|
+
cast_to=type(None),
|
|
129
|
+
request_options=request_options or default_request_options(),
|
|
130
|
+
)
|
|
131
|
+
|
|
132
|
+
async def get(
|
|
133
|
+
self, *, id: str, request_options: typing.Optional[RequestOptions] = None
|
|
134
|
+
) -> models.V1AudioProjectsGetResponse:
|
|
135
|
+
"""
|
|
136
|
+
Get audio details
|
|
137
|
+
|
|
138
|
+
Get the details of a audio project. The `downloads` field will be empty unless the audio was successfully rendered.
|
|
139
|
+
|
|
140
|
+
The audio can be one of the following status
|
|
141
|
+
- `draft` - not currently used
|
|
142
|
+
- `queued` - the job is queued and waiting for a GPU
|
|
143
|
+
- `rendering` - the generation is in progress
|
|
144
|
+
- `complete` - the audio is successful created
|
|
145
|
+
- `error` - an error occurred during rendering
|
|
146
|
+
- `canceled` - audio render is canceled by the user
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
GET /v1/audio-projects/{id}
|
|
150
|
+
|
|
151
|
+
Args:
|
|
152
|
+
id: Unique ID of the audio project. This value is returned by all of the POST APIs that create an audio.
|
|
153
|
+
request_options: Additional options to customize the HTTP request
|
|
154
|
+
|
|
155
|
+
Returns:
|
|
156
|
+
Success
|
|
157
|
+
|
|
158
|
+
Raises:
|
|
159
|
+
ApiError: A custom exception class that provides additional context
|
|
160
|
+
for API errors, including the HTTP status code and response body.
|
|
161
|
+
|
|
162
|
+
Examples:
|
|
163
|
+
```py
|
|
164
|
+
await client.v1.audio_projects.get(id="cuid-example")
|
|
165
|
+
```
|
|
166
|
+
"""
|
|
167
|
+
return await self._base_client.request(
|
|
168
|
+
method="GET",
|
|
169
|
+
path=f"/v1/audio-projects/{id}",
|
|
170
|
+
auth_names=["bearerAuth"],
|
|
171
|
+
cast_to=models.V1AudioProjectsGetResponse,
|
|
172
|
+
request_options=request_options or default_request_options(),
|
|
173
|
+
)
|