[ 01 / 04 ]·API Documentation

Integrate ephemeral sharing into your apps.

Temp File provides a simple, robust API for developers to upload, manage, and share files programmatically. Whether you're building a CLI tool, a mobile app, or a web platform, our API is designed for speed and security.

Introduction

The Temp File API is organized around REST. Our API has predictable resource-oriented URLs, accepts JSON-encoded request bodies, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

Base URL: https://tfile.freecustom.email/api
All requests should be made over HTTPS.

Authentication

The Temp File API uses API keys to authenticate requests. You can view and manage your API keys in the Dashboard Settings.

Your API keys carry many privileges, so be sure to keep them secure! Do not share your secret API keys in publicly accessible areas such as GitHub, client-side code, and so forth.

Example Header
Authorization: Bearer tf_sk_...

POST /upload

POST

Request a signed URL to upload a file directly to our CDN. This approach ensures maximum speed and minimal latency.

Body Parameters

filename

string

The original name of the file.

Required
mimeType

string

The MIME type of the file (e.g. image/png).

Required
size

number

Size of the file in bytes.

Required
sha256

string

SHA-256 hash of the file for deduplication.

Required
expiryHours

number

Custom expiry time (1-720 hours).

Request Example (cURL)
curl -X POST https://tfile.freecustom.email/api/upload \
  -H "Authorization: Bearer tf_sk_..." \
  -H "Content-Type: application/json" \
  -d '{
    "filename": "backup.zip",
    "size": 102456,
    "sha256": "e3b0c442...",
    "mimeType": "application/zip"
  }'

Changelog

March 2026 — v1.1.0

Added SHA-256 Deduplication

Improved upload speeds for existing files by checking hashes before initiating storage transfers.

February 2026 — v1.0.0

Initial API Release

Core upload and download endpoints released to production.