Replace Photar In Template

Examples

Replace photar in Template

Template video:
5cd0ff74ab9346de9704fd5944d138f9

Variables:

{
  "code": 100,
  "data": {
    "scenes": [
      {
        "variables": [
          {
            "name": "photar_0",
            "properties": [
              {
                "default": "e369e7deb3294abb88e4618ff319d47e",
                "name": "id"
              },
              {
                "default": "Welcome to the new era of video creation with HeyGen! Simply type your scripts to get started!",
                "name": "text"
              },
              {
                "default": "1bd001e7e50f421d891986aad5158bc8",
                "name": "voice_id"
              }
            ],
            "type": "photar"
          }
        ]
      }
    ],
    "template_id": "5cd0ff74ab9346de9704fd5944d138f9",
    "video_id": "5cd0ff74ab9346de9704fd5944d138f9"
  },
  "message": "Success"
}

template geenrate req:(curl)

curl --request POST \
     --url https://api.heygen.com/v1/template.generate \
     --header 'Accept: application/json' \
     --header 'Content-Type: application/json' \
     --header 'x-api-key: O/rgPJbuWtusgyBOfYBHytyIuL2DeGowXB7rTBwLpxY=' \
     --data '
{
     "template_id": "5cd0ff74ab9346de9704fd5944d138f9",
     "title": "video_title",
     "variables": [
          {
               "properties": {
                    "id": "b20a9dbedbf04f1595fada8393b72c45",
                    "text": "HeyGen api支持更换photar了",
                    "voice_id": "118e0e91a87a4e60a1353a438b3601ac"
               },
               "name": "photar_0"
          }
     ],
     "test": false
}
'

Result