New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@kassellabs/corellia-api

Package Overview
Dependencies
Maintainers
2
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@kassellabs/corellia-api - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

dist/api.d.ts

30

package.json
{
"name": "@kassellabs/corellia-api",
"version": "0.0.1",
"version": "0.0.2",
"description": "Corellia's External API to render After Effects Videos",
"keywords": [
"corellia",
"after",
"effects",
"video"
],
"author": "Nihey Takizawa <nihey.takizawa@gmail.com>",
"author": "Kassel Labs Team",
"homepage": "https://kassellabs.io",
"license": "MIT",
"main": "dist/index.js",
"directories": {
"lib": "lib",
"test": "__tests__"
},
"files": [
"lib"
],
"publishConfig": {
"access": "public"
},
"types": "dist/index.d.ts",
"scripts": {
"build": "tsc",
"test": "echo \"Error: run tests from root\" && exit 1"
},
"bugs": {
"url": "https://kassellabs.io/contact"
},
"dependencies": {
"axios": "^0.19.2"
"axios": "^0.19.0"
},
"devDependencies": {
"ts-node": "^8.6.2"
}
}

@@ -1,11 +0,127 @@

# `@corellia/api`
# Corellia API
> TODO: description
This module provides easy access to Corellia's API to render videos based on
After Effects Templates.
## Usage
# Installation
```bash
npm i --save @corellia/api
```
const api = require('@corellia/api');
// TODO: DEMONSTRATE API
# Usage
First you should get your Corellia API **Client ID** and **Client Secret**, then
you can start using this project by instantiating the main class
```javascript
import CorelliaAPI from '@corellia/api';
const api = new CorelliaAPI({
host: 'https://my-own-api', // Defaults to the production server
clientId: '< your corellia client id >',
clientSecret: '< your corellia client secret >',
});
```
After that you can start calling the main methods:
## requestNewVideo(customJSON)
Requests a new video to be rendered based on a custom JSON
```javascript
const videoRequest = await api.requestNewVideo(customJSON);
// Example:
//
// {
// "lastModified":"2020-01-24T18:08:13.654Z",
// "userId":"XXXX",
// "actions":[
// ...,
// ],
// "templateId":"my-template-id",
// "customJSON":{
// "videoURL":"<my-video-url>",
// "timeToBeContinued":9.731636028610229,
// "videoStartAt":0,
// "videoEndAt":14.731636028610229
// },
// "renderJob":{
// "id":"WWWWWWWWWWW",
// "state":"started",
// "downloadURL":null
// },
// "id":"IIIIIIIIIIIIII"
// }
```
## getAllVideoRequests()
Retrieve a list of all requestd videos so far
```javascript
const videoRequests = await api.getAllVideoRequests(customJSON);
// Example:
//
// [{
// "lastModified":"2020-01-24T18:08:13.654Z",
// "userId":"XXXX",
// "actions":[
// ...,
// ],
// "templateId":"my-template-id",
// "customJSON":{
// "videoURL":"<my-video-url>",
// "timeToBeContinued":9.731636028610229,
// "videoStartAt":0,
// "videoEndAt":14.731636028610229
// },
// "renderJob":{
// "id":"WWWWWWWWWWW",
// "state":"started",
// "downloadURL":null
// },
// "id":"IIIIIIIIIIIIII"
// }, ...]
```
## getVideoRequest(id)
Retrieve the status of a already created videoRequest
```javascript
const videoRequest = await api.getVideoRequest('<your-video-request-id>');
// Example:
//
// {
// "lastModified":"2020-01-24T18:08:13.654Z",
// "userId":"XXXX",
// "actions":[
// ...,
// ],
// "templateId":"my-template-id",
// "customJSON":{
// "videoURL":"<my-video-url>",
// "timeToBeContinued":9.731636028610229,
// "videoStartAt":0,
// "videoEndAt":14.731636028610229
// },
// "renderJob":{
// "id":"WWWWWWWWWWW",
// "state":"started",
// "downloadURL":null
// },
// "id":"IIIIIIIIIIIIII"
// }
```
## deleteVideoRequest(id)
Remove a specific video request
```javascript
const { success } = await api.deleteVideoRequest('<your-video-request-id>');
// success === true -> deleted
// success === false -> not deleted
```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc