Generate previews
curl --request POST \
--url https://api.filecheck.io/jobs/previews \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"sources": [
{
"url": "<string>",
"file": "<string>",
"fileRef": "<string>",
"params": {}
}
],
"sync": false,
"webhook": "<string>",
"metaData": {}
}
'import requests
url = "https://api.filecheck.io/jobs/previews"
payload = {
"sources": [
{
"url": "<string>",
"file": "<string>",
"fileRef": "<string>",
"params": {}
}
],
"sync": False,
"webhook": "<string>",
"metaData": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
sources: [{url: '<string>', file: '<string>', fileRef: '<string>', params: {}}],
sync: false,
webhook: '<string>',
metaData: {}
})
};
fetch('https://api.filecheck.io/jobs/previews', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.filecheck.io/jobs/previews",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'sources' => [
[
'url' => '<string>',
'file' => '<string>',
'fileRef' => '<string>',
'params' => [
]
]
],
'sync' => false,
'webhook' => '<string>',
'metaData' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.filecheck.io/jobs/previews"
payload := strings.NewReader("{\n \"sources\": [\n {\n \"url\": \"<string>\",\n \"file\": \"<string>\",\n \"fileRef\": \"<string>\",\n \"params\": {}\n }\n ],\n \"sync\": false,\n \"webhook\": \"<string>\",\n \"metaData\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.filecheck.io/jobs/previews")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"sources\": [\n {\n \"url\": \"<string>\",\n \"file\": \"<string>\",\n \"fileRef\": \"<string>\",\n \"params\": {}\n }\n ],\n \"sync\": false,\n \"webhook\": \"<string>\",\n \"metaData\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.filecheck.io/jobs/previews")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"sources\": [\n {\n \"url\": \"<string>\",\n \"file\": \"<string>\",\n \"fileRef\": \"<string>\",\n \"params\": {}\n }\n ],\n \"sync\": false,\n \"webhook\": \"<string>\",\n \"metaData\": {}\n}"
response = http.request(request)
puts response.read_body{
"job": {
"id": "<string>",
"createdAt": "<string>",
"modifiedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"ruleId": "<string>",
"workflowId": "<string>",
"metaData": {},
"tasks": [
{
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"fileType": "<string>",
"mimeType": "<string>",
"source": "<string>",
"fileRef": "<string>",
"clientRef": "<string>",
"jobId": "<string>",
"originalArtifact": {},
"outputArtifacts": [
{
"kind": "<string>",
"role": "<string>",
"bucket": "<string>",
"key": "<string>",
"downloadUrl": "<string>",
"expiresIn": 123
}
],
"steps": [
{
"id": "<string>",
"type": "<string>",
"status": "<string>",
"reason": "<string>",
"params": {},
"runtimeParams": {},
"started": "<string>",
"ended": "<string>",
"duration": 123,
"outputs": [
{}
]
}
]
}
],
"orderId": "<string>",
"customerId": "<string>",
"customerEmail": "<string>",
"summary": {},
"results": {}
}
}{
"job": {
"id": "<string>",
"createdAt": "<string>",
"modifiedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"ruleId": "<string>",
"workflowId": "<string>",
"metaData": {},
"tasks": [
{
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"fileType": "<string>",
"mimeType": "<string>",
"source": "<string>",
"fileRef": "<string>",
"clientRef": "<string>",
"jobId": "<string>",
"originalArtifact": {},
"outputArtifacts": [
{
"kind": "<string>",
"role": "<string>",
"bucket": "<string>",
"key": "<string>",
"downloadUrl": "<string>",
"expiresIn": 123
}
],
"steps": [
{
"id": "<string>",
"type": "<string>",
"status": "<string>",
"reason": "<string>",
"params": {},
"runtimeParams": {},
"started": "<string>",
"ended": "<string>",
"duration": 123,
"outputs": [
{}
]
}
]
}
],
"orderId": "<string>",
"customerId": "<string>",
"customerEmail": "<string>",
"summary": {},
"results": {}
}
}{
"pending": true,
"job": {
"id": "<string>",
"createdAt": "<string>",
"modifiedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"ruleId": "<string>",
"workflowId": "<string>",
"metaData": {},
"tasks": [
{
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"fileType": "<string>",
"mimeType": "<string>",
"source": "<string>",
"fileRef": "<string>",
"clientRef": "<string>",
"jobId": "<string>",
"originalArtifact": {},
"outputArtifacts": [
{
"kind": "<string>",
"role": "<string>",
"bucket": "<string>",
"key": "<string>",
"downloadUrl": "<string>",
"expiresIn": 123
}
],
"steps": [
{
"id": "<string>",
"type": "<string>",
"status": "<string>",
"reason": "<string>",
"params": {},
"runtimeParams": {},
"started": "<string>",
"ended": "<string>",
"duration": 123,
"outputs": [
{}
]
}
]
}
],
"orderId": "<string>",
"customerId": "<string>",
"customerEmail": "<string>",
"summary": {},
"results": {}
}
}{
"error": true,
"message": "<string>"
}{
"error": true,
"message": "<string>"
}{
"error": true,
"message": "<string>"
}Jobs
Generate previews
Sugar wrapper. Renders preview images for a file. Async (201) by default; sync: true waits for the result.
POST
/
jobs
/
previews
Generate previews
curl --request POST \
--url https://api.filecheck.io/jobs/previews \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"sources": [
{
"url": "<string>",
"file": "<string>",
"fileRef": "<string>",
"params": {}
}
],
"sync": false,
"webhook": "<string>",
"metaData": {}
}
'import requests
url = "https://api.filecheck.io/jobs/previews"
payload = {
"sources": [
{
"url": "<string>",
"file": "<string>",
"fileRef": "<string>",
"params": {}
}
],
"sync": False,
"webhook": "<string>",
"metaData": {}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
sources: [{url: '<string>', file: '<string>', fileRef: '<string>', params: {}}],
sync: false,
webhook: '<string>',
metaData: {}
})
};
fetch('https://api.filecheck.io/jobs/previews', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.filecheck.io/jobs/previews",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'sources' => [
[
'url' => '<string>',
'file' => '<string>',
'fileRef' => '<string>',
'params' => [
]
]
],
'sync' => false,
'webhook' => '<string>',
'metaData' => [
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.filecheck.io/jobs/previews"
payload := strings.NewReader("{\n \"sources\": [\n {\n \"url\": \"<string>\",\n \"file\": \"<string>\",\n \"fileRef\": \"<string>\",\n \"params\": {}\n }\n ],\n \"sync\": false,\n \"webhook\": \"<string>\",\n \"metaData\": {}\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.filecheck.io/jobs/previews")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"sources\": [\n {\n \"url\": \"<string>\",\n \"file\": \"<string>\",\n \"fileRef\": \"<string>\",\n \"params\": {}\n }\n ],\n \"sync\": false,\n \"webhook\": \"<string>\",\n \"metaData\": {}\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.filecheck.io/jobs/previews")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"sources\": [\n {\n \"url\": \"<string>\",\n \"file\": \"<string>\",\n \"fileRef\": \"<string>\",\n \"params\": {}\n }\n ],\n \"sync\": false,\n \"webhook\": \"<string>\",\n \"metaData\": {}\n}"
response = http.request(request)
puts response.read_body{
"job": {
"id": "<string>",
"createdAt": "<string>",
"modifiedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"ruleId": "<string>",
"workflowId": "<string>",
"metaData": {},
"tasks": [
{
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"fileType": "<string>",
"mimeType": "<string>",
"source": "<string>",
"fileRef": "<string>",
"clientRef": "<string>",
"jobId": "<string>",
"originalArtifact": {},
"outputArtifacts": [
{
"kind": "<string>",
"role": "<string>",
"bucket": "<string>",
"key": "<string>",
"downloadUrl": "<string>",
"expiresIn": 123
}
],
"steps": [
{
"id": "<string>",
"type": "<string>",
"status": "<string>",
"reason": "<string>",
"params": {},
"runtimeParams": {},
"started": "<string>",
"ended": "<string>",
"duration": 123,
"outputs": [
{}
]
}
]
}
],
"orderId": "<string>",
"customerId": "<string>",
"customerEmail": "<string>",
"summary": {},
"results": {}
}
}{
"job": {
"id": "<string>",
"createdAt": "<string>",
"modifiedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"ruleId": "<string>",
"workflowId": "<string>",
"metaData": {},
"tasks": [
{
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"fileType": "<string>",
"mimeType": "<string>",
"source": "<string>",
"fileRef": "<string>",
"clientRef": "<string>",
"jobId": "<string>",
"originalArtifact": {},
"outputArtifacts": [
{
"kind": "<string>",
"role": "<string>",
"bucket": "<string>",
"key": "<string>",
"downloadUrl": "<string>",
"expiresIn": 123
}
],
"steps": [
{
"id": "<string>",
"type": "<string>",
"status": "<string>",
"reason": "<string>",
"params": {},
"runtimeParams": {},
"started": "<string>",
"ended": "<string>",
"duration": 123,
"outputs": [
{}
]
}
]
}
],
"orderId": "<string>",
"customerId": "<string>",
"customerEmail": "<string>",
"summary": {},
"results": {}
}
}{
"pending": true,
"job": {
"id": "<string>",
"createdAt": "<string>",
"modifiedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"ruleId": "<string>",
"workflowId": "<string>",
"metaData": {},
"tasks": [
{
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"status": "<string>",
"outcome": "<string>",
"fileType": "<string>",
"mimeType": "<string>",
"source": "<string>",
"fileRef": "<string>",
"clientRef": "<string>",
"jobId": "<string>",
"originalArtifact": {},
"outputArtifacts": [
{
"kind": "<string>",
"role": "<string>",
"bucket": "<string>",
"key": "<string>",
"downloadUrl": "<string>",
"expiresIn": 123
}
],
"steps": [
{
"id": "<string>",
"type": "<string>",
"status": "<string>",
"reason": "<string>",
"params": {},
"runtimeParams": {},
"started": "<string>",
"ended": "<string>",
"duration": 123,
"outputs": [
{}
]
}
]
}
],
"orderId": "<string>",
"customerId": "<string>",
"customerEmail": "<string>",
"summary": {},
"results": {}
}
}{
"error": true,
"message": "<string>"
}{
"error": true,
"message": "<string>"
}{
"error": true,
"message": "<string>"
}Authorizations
Your secret key as a bearer token, e.g. Authorization: Bearer sk_live_…. Secret keys are server-side only.
Body
application/json
Response
Sync completion (sync: true)
Show child attributes
Show child attributes
⌘I