API reference / Uploads

Get file capabilities

GET/v1/files/capabilities

Each supported file extension with its kind, content type, size limit, dimension and duration limits and suggested folder, plus the upload, ZIP and edit limits. Cache it for up to 5 minutes; the server checks every file when you send it.

Request

curl -s $BLITFRAME/files/capabilities -H "Authorization: Bearer $BLITFRAME_API_KEY"
import os, requests

response = requests.get(
    f"{os.environ['BLITFRAME']}/files/capabilities",
    headers={"Authorization": f"Bearer {os.environ['BLITFRAME_API_KEY']}"},
)
print(response.json())
const response = await fetch(`${process.env.BLITFRAME}/files/capabilities`, {
  headers: { Authorization: `Bearer ${process.env.BLITFRAME_API_KEY}` },
});
console.log(await response.json());
<?php
$request = curl_init(getenv("BLITFRAME") . "/files/capabilities");
curl_setopt_array($request, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        "Authorization: Bearer " . getenv("BLITFRAME_API_KEY"),
    ],
]);
$response = curl_exec($request);
echo $response;
require "net/http"

uri = URI(ENV["BLITFRAME"] + '/files/capabilities')
request = Net::HTTP::Get.new(uri)
request["Authorization"] = "Bearer " + ENV["BLITFRAME_API_KEY"]
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: uri.scheme == "https") { |http| http.request(request) }
puts response.body
package main

import (
	"fmt"
	"io"
	"net/http"
	"os"
)

func main() {
	request, err := http.NewRequest("GET", os.Getenv("BLITFRAME")+"/files/capabilities", nil)
	if err != nil {
		panic(err)
	}
	request.Header.Set("Authorization", "Bearer "+os.Getenv("BLITFRAME_API_KEY"))
	response, err := http.DefaultClient.Do(request)
	if err != nil {
		panic(err)
	}
	defer response.Body.Close()
	text, _ := io.ReadAll(response.Body)
	fmt.Println(string(text))
}
using System.Net.Http.Headers;

using var client = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get,
    Environment.GetEnvironmentVariable("BLITFRAME") + "/files/capabilities");
request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("BLITFRAME_API_KEY"));
using var response = await client.SendAsync(request);
Console.WriteLine(await response.Content.ReadAsStringAsync());
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;

public class Example {
    public static void main(String[] args) throws Exception {
        var request = HttpRequest.newBuilder(URI.create(System.getenv("BLITFRAME") + "/files/capabilities"))
            .header("Authorization", "Bearer " + System.getenv("BLITFRAME_API_KEY"))
            .method("GET", HttpRequest.BodyPublishers.noBody())
            .build();
        var response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
        System.out.println(response.body());
    }
}

Headers

  • AuthorizationBearer Blitframe API keyrequired

    API key from the developer console.

Try it

GET/v1/files/capabilities

Used for the requests you send from this page only. It is not saved.

This sends a real request to your workspace: a render spends render seconds, and a delete is final.

Response

Send the request to see the answer here.

Responses

  • 200 OK

application/json · FileCapabilitiesDto

  • UploadCapabilities fields
    • maxSizeBytesinteger (int64)
    • singlePutMaxBytesinteger (int64)
    • multipartPartSizeBytesinteger (int64)
    • singleUploadLifetimeSecondsinteger
    • multipartUploadLifetimeSecondsinteger
    • partUrlLifetimeSecondsinteger
  • ZipCapabilities fields
    • maxFilesinteger
    • maxUncompressedBytesinteger (int64)
    • maxCompressionRatiointeger
  • maxFilesPerVersioninteger
  • maxInlineEditBytesinteger (int64)
  • compositionPathstring
  • textFittingPathstring
  • filesarray of FileTypeCapability
    FileTypeCapability fields
    • extensionstring
    • One of composition json image video audio font model

    • contentTypestring
    • maxSizeBytesinteger (int64)
    • defaultFolderstring
    • maxWidthinteger or null
    • maxHeightinteger or null
    • maxDurationSecondsnumber or null
    • fontLicenseRequiredboolean

Errors

  • 400 Bad Request
  • 401 Unauthorized
  • 404 Not Found
  • 429 Too Many Requests

application/json · ErrorResponse

  • ApiError fields
    • codestring
    • messagestring

Errors lists the error codes and says when to retry.