In August 2022, we rolled out the new JSON2Video API v2.0 that completely replaces the previous v1.0.
The specification of the new API does not change substantially and users of the previous version should have no problem migrating easily to v2.0.
New features
The new JSON2Video API v2.0 introduces new and exciting features:
- New Component elements that add out-of-the-box designs
- Simplified Text elements that provide new animation effects
- Improved error handling that helps debugging possible errors
- Support for paid plans for professional applications
New plans and pricing
The new API introduces paid plans for the first time after 9 months of Beta phase.
The video editing API is also available for free for these users that want to test or evaluate the service on a limited quota.
Introducing video drafts
To streamline the use of the API and facilitate the use of payment plans, the API can now generate video drafts or final videos: Video drafts include a small watermark, while final videos are clean.
Video drafts are intended for development testing, and final videos for videos to be published. Each usage plan includes a number of video drafts and final videos.
By default, the API generates video drafts. If you want to generate a final video, add the property
draft: false
to the Movie object.
Improved error handling
The new API also handles errors much better and provides better messages to facilitate error debugging.
Migration steps
Version 1.0 and 2.0 are very similar, and it should be pretty easy for you to migrate any script or application using JSON2Video.
The main differences are:
- project is now an auto-generated random string
- text elements have a new format
- component elements are a new type of element that partially replaces the old text element features
New approach for projects
In API v2.0, project names are no longer provided by you but are automatically generated for each movie. Unlike before, now there is no limitation on the number of projects.
POST requests to /v2/movies
now return the project name as a random string. For example:
{
"success": true,
"project": "7eRDwa8MgqC6yfEd",
"timestamp": "2022-08-01T10:49:52.924Z"
}
Once submitted, you can check the status of the movie encoding by GET-quering
/v2/movies
passing the project as query parameter:
/v2/movies?project=7eRDwa8MgqC6yfEd
If everything went fine, the response should look like this:
{
"success": true,
"movie": {
"success": true,
"status": "done",
"message": "",
"url": "https://assets.json2video.com/clients/[your-user-id]/renders/2022-08-01-99359.mp4",
"created_at": "2022-08-01T10:49:52.924Z",
"ended_at": "2022-08-01T10:50:58.142Z",
"duration": 20.32,
"size": 26551424,
"width": 1920,
"height": 1080
},
"remaining_quota": {
"movies": 14,
"drafts": 42
}
}
You can notice the differences with the previous version. Now, the response includes the remaining_quota object that shows how many movies and drafts are still available for you.
Simplified Text elements
In v1.0, Text elements included not only text animations but lower-thirds and other pre-designed features. Now, all these features have been converted to Component elements and Text elements include only text animations.
You can browse all available text animations.
New Component elements
Component elements are a new type of element that allows you to add pre-defined features to your videos, like buttona, a lower-thirda, ratings, scene designs, transitions, etc.
You can customise these components with CSS styling.
Components are organized in different packs that are available depending on the subscription plan. We will add new packs and components to the free and paid plans in the coming weeks and months.
You can browse the currently available templates: