Skip to content

Menu

  • Media
  • Pricing
  • Docs
  • Language: English

    This page isn’t available in the greyed-out languages.

    • English
    • Español
    • Português
    • Français
    • Deutsch
    • Italiano
    • Nederlands
    • Polski
    • 日本語
    • 한국어
    • Bahasa Indonesia
    • Tiếng Việt
    • Türkçe
    • العربية
    • ไทย
    • Български
    • Català
    • Hrvatski
    • Eesti
    • Magyar
    • Latviešu
    • Lietuvių
    • Srpski
    • Slovenčina
    • Slovenščina
    • Українська
    • Čeština
    • Română
    • Svenska
    • Dansk
    • Norsk bokmål
    • Suomi
    • עברית
    • हिन्दी
    • Tagalog
    • Bahasa Melayu
    • Ελληνικά
    • 简体中文
    • 繁體中文

Files

An uploaded file, its check and a fresh download link. A job’s results come with the job: see results and downloads.

On this page

Get a file

GET/v1/files/{id}

The file, its check and, once it's uploaded, a fresh download link. Each call gives a new link, valid for the shorter of 7 days and the time left before the file is deleted.

Path parameters

  • idstringRequired

Returns

  • 200The file.
18 fields
  • idstringRequired
  • namestringRequired
  • operationstringRequired

    The operation it was uploaded for.

  • statestringRequired

    One of uploading or uploaded

  • sizeintegerRequired
  • created_atstring (date-time)Required
  • uploaded_atstring (date-time)
  • delete_atstring (date-time)

    When it's deleted. Left out while a job uses it.

  • checkobject

    The check of the file's content when its upload completed.

  • check.statestringRequired

    proceed: an operation can use it. refuse: it can't, for reason. couldnt_read: the check couldn't read all of it; a job reads it in full. check_failed: a problem on our side; complete the upload again to retry.

    One of checking, proceed, refuse, couldnt_read, or check_failed

  • check.reasonstring
  • check.detailobject
  • check.kindstring

    What the file really is, such as video.

  • check.typestring

    Its real format, such as mp4, whatever its name says.

  • check.factsobject

    What the check read, such as a video's length, size and codecs.

  • check.facts_completeboolean
  • download_urlstring (URL)

    Only on GET /v1/files/{id}, once it's uploaded.

  • download_expires_atstring (date-time)

Example

curl https://api.filesokay.com/v1/files/file_3cf0737aefa34b89b7b4443c9467d60c \
  -H "Authorization: Bearer $FILESOKAY_KEY"
const res = await fetch("https://api.filesokay.com/v1/files/file_3cf0737aefa34b89b7b4443c9467d60c", {
  headers: {
    Authorization: `Bearer ${process.env.FILESOKAY_KEY}`,
  },
});
const file = await res.json();
import os

import requests

res = requests.get(
    "https://api.filesokay.com/v1/files/file_3cf0737aefa34b89b7b4443c9467d60c",
    headers={
        "Authorization": f"Bearer {os.environ['FILESOKAY_KEY']}",
    },
)
file = res.json()
Response
{
  "id": "file_3cf0737aefa34b89b7b4443c9467d60c",
  "name": "lecture.mp4",
  "operation": "video.compress",
  "state": "uploaded",
  "size": 12417467,
  "created_at": "2026-12-03T09:22:53Z",
  "uploaded_at": "2026-12-03T09:23:02Z",
  "delete_at": "2026-12-04T09:23:02Z",
  "check": {
    "state": "proceed",
    "kind": "video",
    "type": "mp4",
    "facts": {
      "container": "mp4",
      "protection": "none",
      "attachments": [],
      "duration_ms": 20023,
      "frame_count": 600,
      "audio_tracks": [
        {
          "codec": "aac",
          "channels": 1,
          "sample_rate": 44100
        }
      ],
      "video_tracks": [
        {
          "hdr": "none",
          "codec": "h264",
          "width": 1280,
          "chroma": "420",
          "height": 720,
          "profile": "High",
          "rotation": 0,
          "bit_depth": 8,
          "frame_rate": 30,
          "interlaced": false,
          "variable_frame_rate": false
        }
      ],
      "data_end_bytes": 12417467,
      "subtitle_tracks": []
    },
    "facts_complete": true
  },
  "download_url": "https://…",
  "download_expires_at": "2026-12-04T09:23:02Z"
}

Delete a file

DELETE/v1/files/{id}

Deletes the file now, from storage too.

Path parameters

  • idstringRequired

Returns

  • 204Deleted.

Example

curl -X DELETE https://api.filesokay.com/v1/files/file_3cf0737aefa34b89b7b4443c9467d60c \
  -H "Authorization: Bearer $FILESOKAY_KEY"
const res = await fetch("https://api.filesokay.com/v1/files/file_3cf0737aefa34b89b7b4443c9467d60c", {
  method: "DELETE",
  headers: {
    Authorization: `Bearer ${process.env.FILESOKAY_KEY}`,
  },
});
console.log(res.status);
import os

import requests

res = requests.delete(
    "https://api.filesokay.com/v1/files/file_3cf0737aefa34b89b7b4443c9467d60c",
    headers={
        "Authorization": f"Bearer {os.environ['FILESOKAY_KEY']}",
    },
)
print(res.status_code)