D-ID API Python Library
Project description
D_ID Python Package
The D_ID
Python package is designed to interact with the D-ID API, allowing you to access various functionalities such as retrieving actor lists, creating text-to-video clips, and more.
Installation
You can install the package via pip:
pip install d-id
Getting Started
-
Import the
Clips
class from theD_ID
package:from D_ID.D_ID import Clips
-
Initialize the
Clips
class with your D-ID API key:api_key = "<your_api_key>" clip = Clips(api_key)
Usage Examples
Get Actor List
actor_list = clip.get_actor_list()
print(actor_list)
This function retrieves a list of actors available in the D-ID API.
Create Text-to-Video Clip
text = "This is the text you want to convert into a video clip."
presenter_id = "amy-jcwCkr1grs"
driver_id = "uM00QMwJ9x"
microsoft_voice_id = "en-US-JennyNeural"
result = clip.create_text_to_video_clip(text, presenter_id, driver_id, microsoft_voice_id)
print(result)
This function creates a video clip from the provided text using the specified presenter, driver, and Microsoft voice.
Additional Functions
You can also use other functions provided by the Clips
class to interact with the D-ID API, such as retrieving driver lists, presenter details, clips, and more.
[comment]: <> ## Documentation
[comment]: <> For detailed documentation on each function and its parameters, please refer to the inline comments in the Clips
class definition within the package code.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Contributing
If you would like to contribute to this project, please open an issue or submit a pull request.
Support
If you encounter any issues or have questions about using this package, please open an issue on the GitHub repository.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.