Feature Description
From the local machineupload the source videocreate a Chanjingcustomised digital human, and supports listing, querying, polling and deletion; the flow is consistent with the Open API:Get upload URL(create_upload_url) → to the returned sign_url initiate a PUT PUT upload body → create/list/get/poll/delete. Only the Chanjing Open API and the upload endpoint returned by the interface are used;do notintroduce credentials from other cloud providers. The scriptdoes notdepend on ffmpeg/ffprobe. Environment variablesare all optional(default ~/.chanjing and the official API base URL). For credentials, token persistence and network boundaries see manifest.yaml。
Runtime Dependencies
- python3 and, in the same repository,
scripts/*.py; it can read a local video file path and upload it
Environment Variables and Machine-Readable Declaration
- Environment variable key names and descriptions:
manifest.yaml(environmentsection) and this document - variable key names, credential model, compliance
permissions、clientPermissions、agentPolicy:manifest.yaml
Usage Commands
- ClawHub(slug is subject to the registry):
clawhub run chanjing-customised-person - This repository:
python skills/chanjing-customised-person/scripts/create_person.py …(see Standard Workflow)
Registration and Review (Single Source of Truth)
English registration, primary credentials,primaryEnv omission, optional env, sensitive fields and outbound boundaries:subject to the manifest.yaml in the same directory(consistent with credential_hint、description frontmatter ). This document starts from When to Use and describes business capabilities and flows;do not duplicate with manifest.yaml the long comparison tables。
When to Use This Skill
Use this Skill when the user wants to do these things:
- Upload a real-person source video and create a Chanjing customised digital human
- Query the customised digital human list or the details of a single avatar
- Poll the production progress of a customised digital human
- Delete customised digital humans that are no longer needed
If the requirement is "use an existing digital human to synthesise a talking-head video", prefer chanjing-video-compose。
If the requirement is "upload a real-person video for lip-sync driving", prefer chanjing-avatar。
Preconditions
Before executing this Skill, you must first complete AK/SK and Token verification via chanjing-credentials-guard .
This Skill is shared with guard:
~/.chanjing/credentials.jsonhttps://open-api.chanjing.cc
When there are no credentials, the script will automatically open the Chanjing login page and prompt for the configuration command.
Review and Security (Credentials and Boundaries)
For the item-by-item description related to Purpose / Credentials / Persistence / Network , see manifest.yaml(including permissions.network_mode: open and signUrlPutNote). The following is only the SKILL body supplement:
credentials.json: the script reads local credentials; the refreshedaccess_token/expire_inis written back to the same fileasexpected behaviour. Directory/file permissions must be restricted (e.g. directory0700, file0600), andensure it is never committed to the version control repository(see manifestdoNotCommitToVcs)。sign_urland PUT host:upload_file.py/get_upload_url.pyfirst requestopen-api.chanjing.cc'screate_upload_url, then initiate an HTTPS PUT to thesign_urlin the response; the host of this URL is often Chanjing-side object storage or CDN,may not be inthe fixed host allowlist; the manifest has been changed tonetwork_mode: opento declare this truthfully.create_person.py --callback: if a URL is passed in, the remote service may send to that endpoint POST Task result; the payload may contain status and resource references, etc.Sensitive information; you must trust this endpoint yourself and bear the risks of outbound requests and data exposure.- Local video: read only the video bytes from the path provided by the user and upload them to the API-specified endpoint; do not scan other unrelated system paths.
Standard Workflow
- Upload a local source video to obtain
file_id(recommendedupload_file.py: internallyGET …/create_upload_url→PUT sign_url(body is the file) → pollfile_detailuntil ready; alternatively, use it step by step withget_upload_url.py+ your own PUT + polling) - Call
create_person.pyto create a custom digital human task and obtainperson_id - Call
poll_person.pyto poll until successful and obtainpreview_url, or useget_person --field audio_man_idto get the voice id - To view historical avatars in batches, use
list_persons.py - To clean up resources, use
delete_person.py
Covered APIs
This Skill currently covers:
GET /open/v1/common/create_upload_urlGET /open/v1/common/file_detailPOST /open/v1/create_customised_personPOST /open/v1/list_customised_personGET /open/v1/customised_personPOST /open/v1/delete_customised_person
Scripts
Script directory:
skills/chanjing-customised-person/scripts/
| Script | Description |
|---|---|
_auth.py |
Read credentials, obtain or refresh access_token |
get_upload_url.py |
Call create_upload_url, output JSON such as sign_url、mime_type、file_id (you need to PUT it yourself) |
upload_file.py |
create_upload_url + HTTPS PUT sign_url + poll file_detail, output file_id |
create_person.py |
Create a custom digital human task, output person_id; optional --callback(the server may send to this URL POST sensitive task payload) |
list_persons.py |
List custom digital human avatars |
get_person.py |
Get details of a single digital human, output JSON by default |
poll_person.py |
Poll avatar details until complete, output by default preview_url |
delete_person.py |
Delete a custom digital human, output the deleted person_id |
Usage Examples
Example 1: Create a custom digital human from a local video
FILE_ID=$(python3 skills/chanjing-customised-person/scripts/upload_file.py \
--file ./source.mp4)
PERSON_ID=$(python3 skills/chanjing-customised-person/scripts/create_person.py \
--name "演示数字人" \
--file-id "$FILE_ID" \
--train-type figure)
python3 skills/chanjing-customised-person/scripts/poll_person.py --id "$PERSON_ID"
Example 2: View full details
python3 skills/chanjing-customised-person/scripts/get_person.py \
--id "C-ef91f3a6db3144ffb5d6c581ff13c7ec"
Example 3: List and delete
python3 skills/chanjing-customised-person/scripts/list_persons.py
python3 skills/chanjing-customised-person/scripts/delete_person.py \
--id "C-ef91f3a6db3144ffb5d6c581ff13c7ec"
Output Convention
By default, do not automatically download any preview video or cover image:
create_person.pyoutputperson_idpoll_person.pyoutputpreview_url, for continued preview or saving- Only when the user explicitly requests it should the returned resource URL be saved locally
If you later need to save preview resources to disk, it is recommended to use:
outputs/customised-person/
Additional Resources
For more API details and triggering examples, see:
skills/chanjing-customised-person/reference.mdskills/chanjing-customised-person/examples.md