Skip to content

Commit 4907343

Browse files
Merge pull request #105 from apivideo/add-new-webhooks
Add new webhooks
2 parents ddffa6e + cf068a7 commit 4907343

File tree

1 file changed

+149
-0
lines changed

1 file changed

+149
-0
lines changed

api/openapi.yaml

Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1568,4 +1568,153 @@ x-webhooks:
15681568
summary: Accepted
15691569
description: Your webhook server may return this response to api.video to
15701570
signal that the webhook is accepted.
1571+
video.caption.generated:
1572+
post:
1573+
tags:
1574+
- Webhooks
1575+
summary: Video caption generated
1576+
description: This webhook triggers when the API finishes generating a caption
1577+
for a video.
1578+
operationId: POST-webhooks
1579+
parameters:
1580+
- in: header
1581+
name: X-Api-Video-WebhookID
1582+
schema:
1583+
type: string
1584+
description: The unique ID of your webhook.
1585+
required: true
1586+
- in: header
1587+
name: X-Api-Video-Signature
1588+
schema:
1589+
type: string
1590+
description: The webhook's body encrypted using the webhook's signature secret,
1591+
in HMAC SHA256. Use this hash to verify that api.video is the origin of
1592+
this webhook notification.
1593+
required: true
1594+
requestBody:
1595+
content:
1596+
application/json:
1597+
schema:
1598+
type: object
1599+
properties:
1600+
type:
1601+
type: string
1602+
description: The name of the webhook event that occurred.
1603+
example: video.caption.generated
1604+
emittedAt:
1605+
description: Returns the date-time when the webhook event occurred.
1606+
type: string
1607+
format: date-time
1608+
example: 2024-08-151T10:18:47+00:00
1609+
videoId:
1610+
description: The ID of the video for which the caption was generated.
1611+
type: string
1612+
example: vi4blUQJFrYWbaG44NCh1234
1613+
captionId:
1614+
description: The ID of the caption that was generated.
1615+
type: string
1616+
example: caption_1CHAfLFHT5B5EV4vzT1234
1617+
generationMode:
1618+
description: Returns the method used to generate the caption. `transcript`
1619+
means that the caption was generated based on the transcription
1620+
of the video. Learn more about transcripts [here](https://docs.api.video/vod/generate-transcripts).
1621+
type: string
1622+
enum:
1623+
- transcript
1624+
example: transcript
1625+
language:
1626+
description: Returns the language of the captions in [IETF language
1627+
tag](https://en.wikipedia.org/wiki/IETF_language_tag) format.
1628+
example: en
1629+
type: string
1630+
enum:
1631+
- ar
1632+
- ca
1633+
- cs
1634+
- da
1635+
- de
1636+
- el
1637+
- en
1638+
- es
1639+
- fa
1640+
- fi
1641+
- fr
1642+
- he
1643+
- hi
1644+
- hr
1645+
- hu
1646+
- it
1647+
- ja
1648+
- ko
1649+
- ml
1650+
- nl
1651+
- nn
1652+
- false
1653+
- pl
1654+
- pt
1655+
- ru
1656+
- sk
1657+
- sl
1658+
- te
1659+
- tr
1660+
- uk
1661+
- ur
1662+
- vi
1663+
- zh
1664+
responses:
1665+
"202":
1666+
summary: Accepted
1667+
description: Your webhook server may return this response to api.video to
1668+
signal that the webhook is accepted.
1669+
video.summary.generated:
1670+
post:
1671+
tags:
1672+
- Webhooks
1673+
summary: Video summary generated
1674+
description: This webhook triggers when the API finishes generating a summary
1675+
for a video.
1676+
operationId: POST-webhooks
1677+
parameters:
1678+
- in: header
1679+
name: X-Api-Video-WebhookID
1680+
schema:
1681+
type: string
1682+
description: The unique ID of your webhook.
1683+
required: true
1684+
- in: header
1685+
name: X-Api-Video-Signature
1686+
schema:
1687+
type: string
1688+
description: The webhook's body encrypted using the webhook's signature secret,
1689+
in HMAC SHA256. Use this hash to verify that api.video is the origin of
1690+
this webhook notification.
1691+
required: true
1692+
requestBody:
1693+
content:
1694+
application/json:
1695+
schema:
1696+
type: object
1697+
properties:
1698+
type:
1699+
type: string
1700+
description: The name of the webhook event that occurred.
1701+
example: video.caption.generated
1702+
emittedAt:
1703+
description: Returns the date-time when the webhook event occurred.
1704+
type: string
1705+
format: date-time
1706+
example: 2024-08-151T10:18:47+00:00
1707+
videoId:
1708+
description: The ID of the video for which the summary was generated.
1709+
type: string
1710+
example: vi4blUQJFrYWbaG44NCh1234
1711+
summaryId:
1712+
description: The ID of the summary that was generated.
1713+
type: string
1714+
example: summary_1CGyYoB9XCgBk4iQna8ocT
1715+
responses:
1716+
"202":
1717+
summary: Accepted
1718+
description: Your webhook server may return this response to api.video to
1719+
signal that the webhook is accepted.
15711720

0 commit comments

Comments
 (0)