> For the complete documentation index, see [llms.txt](https://docs.videograph.ai/llms.txt).
> Use it to discover all available pages before exploring further.

# Advance Video Editing

**Use this endpoint to create a content with watermarks and overlays**


<PlaygroundComponent />

<AuthParams schemes={["basicAuth"]}>
<AuthType scheme="basicAuth">
<ParamField header="Authorization" param-type="string" required="true">
Basic authentication credentials. Provide username and password encoded in Base64 format: Basic base64(username:password)
</ParamField>
</AuthType>
</AuthParams>

### Headers

<ParamField showLocation="false" header="Accept" param-type="string" required="false">

</ParamField>

<BodyParams contentTypes={["application/json"]} defaultType="application/json">
  <ContentType type="application/json">
<ParamField showLocation="false" body="title" param-type="string" required="true">
Provide a title for your content.
</ParamField>

<ParamField showLocation="false" body="description" param-type="string" required="false">
Describe your content.
</ParamField>

<ParamField showLocation="false" body="video" param-type="array" required="true">
Provide the source url to download the content. If you want to create video clips from the video then pass on the start time and end time of the clip along with source url.

<Expandable title="Array Items" default-open="false">

  <ParamField showLocation="false" body="layer" param-type="integer" required="false">
  Layer of the video
  </ParamField>

  <ParamField showLocation="false" body="src" param-type="string" required="true">
  Video source
  </ParamField>

  <ParamField showLocation="false" body="settings" param-type="object" required="true">
  Advance Create Setting

  <Expandable title="Object Properties" default-open="false">

    <ParamField showLocation="false" body="start" param-type="integer" required="true">
    Start position in secs
    </ParamField>

    <ParamField showLocation="false" body="end" param-type="integer" required="true">
    End position in secs
    </ParamField>

  </Expandable>
  </ParamField>

</Expandable>
</ParamField>

<ParamField showLocation="false" body="overlay" param-type="object" required="false">
Watermark details on video content

<Expandable title="Object Properties" default-open="false">

  <ParamField showLocation="false" body="text" param-type="array" required="false">
  Overlay texts to display

  <Expandable title="Array Items" default-open="false">

    <ParamField showLocation="false" body="layer" param-type="integer" required="false">
    Layer of the video
    </ParamField>

    <ParamField showLocation="false" body="src" param-type="string" required="false">
    Video source
    </ParamField>

    <ParamField showLocation="false" body="settings" param-type="object" required="false">
    Advance Create Setting

    <Expandable title="Object Properties" default-open="false">

      <ParamField showLocation="false" body="start" param-type="integer" required="true">
      Start position in secs
      </ParamField>

      <ParamField showLocation="false" body="end" param-type="integer" required="true">
      End position in secs
      </ParamField>

    </Expandable>
    </ParamField>

    <ParamField showLocation="false" body="config" param-type="object" required="false">
    Config

    <Expandable title="Object Properties" default-open="false">

      <ParamField showLocation="false" body="h" param-type="integer" required="true">
      Height in px of overlay. Ex 50
      </ParamField>

      <ParamField showLocation="false" body="w" param-type="integer" required="true">
      Weight in px of overlay. Ex 50
      </ParamField>

      <ParamField showLocation="false" body="x" param-type="integer" required="true">
      X axis position from left top corner. Ex 10
      </ParamField>

      <ParamField showLocation="false" body="y" param-type="integer" required="true">
      Y axis position from left top corner. Ex 10
      </ParamField>

    </Expandable>
    </ParamField>

    <ParamField showLocation="false" body="fontfile" param-type="string" required="false">
    Font file
    </ParamField>

    <ParamField showLocation="false" body="fontcolor" param-type="string" required="false">
    Font Color
    </ParamField>

    <ParamField showLocation="false" body="fontsize" param-type="integer" required="false">
    Font size
    </ParamField>

  </Expandable>
  </ParamField>

  <ParamField showLocation="false" body="logo" param-type="array" required="false">
  Overlay image or videos to display

  <Expandable title="Array Items" default-open="false">

    <ParamField showLocation="false" body="layer" param-type="integer" required="false">
    Layer of the video
    </ParamField>

    <ParamField showLocation="false" body="src" param-type="string" required="false">
    Video source
    </ParamField>

    <ParamField showLocation="false" body="settings" param-type="object" required="false">
    Advance Create Setting

    <Expandable title="Object Properties" default-open="false">

      <ParamField showLocation="false" body="start" param-type="integer" required="true">
      Start position in secs
      </ParamField>

      <ParamField showLocation="false" body="end" param-type="integer" required="true">
      End position in secs
      </ParamField>

    </Expandable>
    </ParamField>

    <ParamField showLocation="false" body="config" param-type="object" required="false">
    Config

    <Expandable title="Object Properties" default-open="false">

      <ParamField showLocation="false" body="h" param-type="integer" required="true">
      Height in px of overlay. Ex 50
      </ParamField>

      <ParamField showLocation="false" body="w" param-type="integer" required="true">
      Weight in px of overlay. Ex 50
      </ParamField>

      <ParamField showLocation="false" body="x" param-type="integer" required="true">
      X axis position from left top corner. Ex 10
      </ParamField>

      <ParamField showLocation="false" body="y" param-type="integer" required="true">
      Y axis position from left top corner. Ex 10
      </ParamField>

    </Expandable>
    </ParamField>

    <ParamField showLocation="false" body="fontfile" param-type="string" required="false">
    Font file
    </ParamField>

    <ParamField showLocation="false" body="fontcolor" param-type="string" required="false">
    Font Color
    </ParamField>

    <ParamField showLocation="false" body="fontsize" param-type="integer" required="false">
    Font size
    </ParamField>

  </Expandable>
  </ParamField>

</Expandable>
</ParamField>

<ParamField showLocation="false" body="tags" param-type="array" required="false">
Provide a list of tags that best describe your content.
</ParamField>

<ParamField showLocation="false" body="metadata" param-type="array" required="false">
Provide content metadata as key value pairs.

<Expandable title="Array Items" default-open="false">

  <ParamField showLocation="false" body="key" param-type="string" required="true">
  The constant that defines the data set ex-color
  </ParamField>

  <ParamField showLocation="false" body="value" param-type="string" required="true">
  A variable whihc belongs to the data set ex-blue
  </ParamField>

</Expandable>
</ParamField>

<ParamField showLocation="false" body="playback_policy" param-type="array" required="true">
Playback policies. Allowed are public, signed or both
</ParamField>

<ParamField showLocation="false" body="mp4_support" param-type="boolean" required="false">
Is MP4 generation supported
</ParamField>
  </ContentType>
</BodyParams>

<Request tabs="curl,python,javascript,go,ruby">

```bash
curl -X POST "https://api.videograph.ai/video/services/api/v1/contents/adv" \
  -H "Content-Type: application/json" \
  -H "Accept: example_string" \
  -H "Authorization: Basic YOUR_CREDENTIALS" \
  -d '{
  "title": "Phani Adv",
  "description": "Video description",
  "tags": [
    "tag1",
    "tag2"
  ],
  "metadata": [
    {
      "key": "abc",
      "value": "pqr"
    }
  ],
  "playback_policy": [
    "public",
    "signed"
  ],
  "mp4_support": true,
  "overlay": {
    "logo": [
      {
        "config": {
          "h": 240,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "layer": 1,
        "settings": null,
        "end": 4,
        "start": 0,
        "src": "https://videographond.akamaized.net/thumb/700x700/enc/yupptv/development/yupptv/3395/mp4/image/1.jpg"
      }
    ],
    "text": [
      {
        "config": {
          "h": 80,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "fontcolor": "red",
        "fontfile": "Times New Roman",
        "fontsize": 80,
        "layer": 2,
        "settings": {
          "end": 3,
          "start": 0
        },
        "src": "Hello adv"
      }
    ]
  },
  "video": [
    {
      "layer": 0,
      "settings": {
        "duration": 3,
        "start": 0
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    },
    {
      "layer": 0,
      "settings": {
        "end": 6,
        "start": 4
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    }
  ]
}'
```

```python
import requests
import json

url = "https://api.videograph.ai/video/services/api/v1/contents/adv"
headers = {
  "Content-Type": "application/json",
  "Accept": "example_string",
  "Authorization": "Basic YOUR_CREDENTIALS"
}
data = {
  "title": "Phani Adv",
  "description": "Video description",
  "tags": [
    "tag1",
    "tag2"
  ],
  "metadata": [
    {
      "key": "abc",
      "value": "pqr"
    }
  ],
  "playback_policy": [
    "public",
    "signed"
  ],
  "mp4_support": true,
  "overlay": {
    "logo": [
      {
        "config": {
          "h": 240,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "layer": 1,
        "settings": null,
        "end": 4,
        "start": 0,
        "src": "https://videographond.akamaized.net/thumb/700x700/enc/yupptv/development/yupptv/3395/mp4/image/1.jpg"
      }
    ],
    "text": [
      {
        "config": {
          "h": 80,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "fontcolor": "red",
        "fontfile": "Times New Roman",
        "fontsize": 80,
        "layer": 2,
        "settings": {
          "end": 3,
          "start": 0
        },
        "src": "Hello adv"
      }
    ]
  },
  "video": [
    {
      "layer": 0,
      "settings": {
        "duration": 3,
        "start": 0
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    },
    {
      "layer": 0,
      "settings": {
        "end": 6,
        "start": 4
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    }
  ]
}

response = requests.post(url, headers=headers, json=data)
print(response.json())
```

```javascript
const response = await fetch("https://api.videograph.ai/video/services/api/v1/contents/adv", {
  method: "POST",
  headers: {
  "Content-Type": "application/json",
  "Accept": "example_string",
  "Authorization": "Basic YOUR_CREDENTIALS"
},
  body: JSON.stringify({
  "title": "Phani Adv",
  "description": "Video description",
  "tags": [
    "tag1",
    "tag2"
  ],
  "metadata": [
    {
      "key": "abc",
      "value": "pqr"
    }
  ],
  "playback_policy": [
    "public",
    "signed"
  ],
  "mp4_support": true,
  "overlay": {
    "logo": [
      {
        "config": {
          "h": 240,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "layer": 1,
        "settings": null,
        "end": 4,
        "start": 0,
        "src": "https://videographond.akamaized.net/thumb/700x700/enc/yupptv/development/yupptv/3395/mp4/image/1.jpg"
      }
    ],
    "text": [
      {
        "config": {
          "h": 80,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "fontcolor": "red",
        "fontfile": "Times New Roman",
        "fontsize": 80,
        "layer": 2,
        "settings": {
          "end": 3,
          "start": 0
        },
        "src": "Hello adv"
      }
    ]
  },
  "video": [
    {
      "layer": 0,
      "settings": {
        "duration": 3,
        "start": 0
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    },
    {
      "layer": 0,
      "settings": {
        "end": 6,
        "start": 4
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    }
  ]
})
});

const data = await response.json();
console.log(data);
```

```go
package main

import (
    "fmt"
    "net/http"
    "bytes"
    "encoding/json"
)

func main() {
    data := []byte(`{
  "title": "Phani Adv",
  "description": "Video description",
  "tags": [
    "tag1",
    "tag2"
  ],
  "metadata": [
    {
      "key": "abc",
      "value": "pqr"
    }
  ],
  "playback_policy": [
    "public",
    "signed"
  ],
  "mp4_support": true,
  "overlay": {
    "logo": [
      {
        "config": {
          "h": 240,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "layer": 1,
        "settings": null,
        "end": 4,
        "start": 0,
        "src": "https://videographond.akamaized.net/thumb/700x700/enc/yupptv/development/yupptv/3395/mp4/image/1.jpg"
      }
    ],
    "text": [
      {
        "config": {
          "h": 80,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "fontcolor": "red",
        "fontfile": "Times New Roman",
        "fontsize": 80,
        "layer": 2,
        "settings": {
          "end": 3,
          "start": 0
        },
        "src": "Hello adv"
      }
    ]
  },
  "video": [
    {
      "layer": 0,
      "settings": {
        "duration": 3,
        "start": 0
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    },
    {
      "layer": 0,
      "settings": {
        "end": 6,
        "start": 4
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    }
  ]
}`)
    
    req, err := http.NewRequest("POST", "https://api.videograph.ai/video/services/api/v1/contents/adv", bytes.NewBuffer(data))
    if err != nil {
        panic(err)
    }
    
    req.Header.Set("Content-Type", "application/json")
    req.Header.Set("Accept", "example_string")
    req.Header.Set("Authorization", "Basic YOUR_CREDENTIALS")

    client := &http.Client{}
    resp, err := client.Do(req)
    if err != nil {
        panic(err)
    }
    defer resp.Body.Close()
    
    fmt.Println("Response Status:", resp.Status)
}
```

```ruby
require 'net/http'
require 'json'

uri = URI('https://api.videograph.ai/video/services/api/v1/contents/adv')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true

request = Net::HTTP::Post.new(uri)
request['Content-Type'] = 'application/json'
request['Accept'] = 'example_string'
request['Authorization'] = 'Basic YOUR_CREDENTIALS'
request.body = '{
  "title": "Phani Adv",
  "description": "Video description",
  "tags": [
    "tag1",
    "tag2"
  ],
  "metadata": [
    {
      "key": "abc",
      "value": "pqr"
    }
  ],
  "playback_policy": [
    "public",
    "signed"
  ],
  "mp4_support": true,
  "overlay": {
    "logo": [
      {
        "config": {
          "h": 240,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "layer": 1,
        "settings": null,
        "end": 4,
        "start": 0,
        "src": "https://videographond.akamaized.net/thumb/700x700/enc/yupptv/development/yupptv/3395/mp4/image/1.jpg"
      }
    ],
    "text": [
      {
        "config": {
          "h": 80,
          "w": 120,
          "x": 0,
          "y": 0
        },
        "fontcolor": "red",
        "fontfile": "Times New Roman",
        "fontsize": 80,
        "layer": 2,
        "settings": {
          "end": 3,
          "start": 0
        },
        "src": "Hello adv"
      }
    ]
  },
  "video": [
    {
      "layer": 0,
      "settings": {
        "duration": 3,
        "start": 0
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    },
    {
      "layer": 0,
      "settings": {
        "end": 6,
        "start": 4
      },
      "src": "https://d19nx8bm4jzw4h.cloudfront.net/Tears-of-steel.mp4"
    }
  ]
}'

response = http.request(request)
puts response.body
```

</Request>

### Responses

<div data-component="ResponsesCollection"><Expandable title="200 - OK" default-open="true">

*OK*

</Expandable>

</div>

<Response tabs="200">

```json
{
  "code": 200,
  "message": "Data success",
  "status": "Success",
  "data": {
    "contentId": "75615af3-2e97-4c8a-af98-92ab14df0965",
    "created_at": 1676204780126,
    "description": "Video description",
    "duration": 0,
    "isAdvanced": true,
    "metadata": [
      {
        "key": "abc",
        "value": "pqr"
      }
    ],
    "mp4_support": true,
    "playbackPolicy": [
      "public",
      "signed"
    ],
    "save_original_copy": false,
    "status": "Pending",
    "statusId": 1,
    "tags": [
      "tag1",
      "tag2"
    ],
    "test_video": false,
    "title": "Phani Adv"
  }
}
```

</Response>

