CLI Usage with curl

A comprehensive guide to using this pastebin from the command line. For the full HTTP API reference, see api.md.

Conventions

Uploading

Upload text content

$ curl -Fc='hello, world' https://f.950414.xyz
{
  "url": "https://f.950414.xyz/abcd",
  "manageUrl": "https://f.950414.xyz/abcd:w2eHqyZGc@CQzWLN=BiJiQxZ",
  "expirationSeconds": 1209600,
  "expireAt": "2026-05-21T10:33:06.114Z"
}

Save url for sharing and manageUrl for later updates or deletion.

Upload a file

$ curl -Fc=@panty.jpg https://f.950414.xyz

The original filename will be sent back as the Content-Disposition header when the paste is fetched.

Upload from stdin

$ echo 'hello' | curl -Fc=@- https://f.950414.xyz
$ cat panty.jpg | curl -Fc=@- https://f.950414.xyz

Set an expiration

$ curl -Fc='kawaii' -Fe=300 https://f.950414.xyz      # 300 seconds
$ curl -Fc='kawaii' -Fe=2h  https://f.950414.xyz      # 2 hours
$ curl -Fc=@big.bin -Fe=30d https://f.950414.xyz      # 30 days

If e is not specified, the default expiration of the deployment is used. The maximum expiration is also enforced by the deployment.

Use a custom name

$ curl -Fc='kawaii' -Fn=hitagi https://f.950414.xyz
{
  "url": "https://f.950414.xyz/~hitagi",
  ...
}

The custom name is at least 3 characters long and may consist of letters, digits, and +_-[]*$=@,;/. Note the leading ~ in the returned URL.

Because curl uses ; and , as field separators, names containing those characters need to be wrapped in extra quotes:

$ curl -Fc=@panty.jpg -Fn='"hi/hello;g,ood"' https://f.950414.xyz

Set a custom password

$ curl -Fc='kawaii' -Fs=12345678 https://f.950414.xyz

If s is omitted, a random password is generated and returned in manageUrl.

Private mode (longer random name)

$ curl -Fc='secret' -Fp=1 https://f.950414.xyz

Without a custom name (n), p produces a 24-character random name, making the paste effectively unguessable.

Mark a paste as syntax-highlighted

$ curl -Fc=@main.rs -Flang=rust https://f.950414.xyz

The lang field is sent back as the X-PB-Highlight-Language header on fetching the paste, and is used by the display page (/d/<name>).

Fetching

Fetch raw content

$ curl https://f.950414.xyz/abcd
hello, world

Save the response to a file

$ curl https://f.950414.xyz/~panty.jpg -o panty.jpg
$ curl -OJ https://f.950414.xyz/~panty               # use server-supplied filename

-J honors the Content-Disposition header set from the original filename.

Force download (attachment)

$ curl 'https://f.950414.xyz/abcd?a' -OJ

The ?a query string sets Content-Disposition: attachment.

Override mime type

$ curl 'https://f.950414.xyz/~panty.jpg?mime=image/png' \
    -w '%{content_type}\n' -o /dev/null -sS
image/png

Or via path extension:

$ curl 'https://f.950414.xyz/abcd.json' -i

Pipe to another tool

$ curl https://f.950414.xyz/~panty.jpg | feh -
$ curl https://f.950414.xyz/~config | jq .

Conditional fetch with If-Modified-Since

$ curl -i -H 'If-Modified-Since: Wed, 01 May 2026 00:00:00 GMT' \
    https://f.950414.xyz/~hitagi
HTTP/2 304

Inspecting metadata

$ curl https://f.950414.xyz/m/abcd
{
  "lastModifiedAt": "2026-05-05T10:33:06.114Z",
  "createdAt": "2026-05-01T10:33:06.114Z",
  "expireAt": "2026-05-08T10:33:06.114Z",
  "sizeBytes": 4096,
  "location": "KV",
  "filename": "a.jpg"
}

A HEAD request returns the same headers as GET without the body, useful for quickly checking size and Content-Type:

$ curl -I https://f.950414.xyz/abcd

URL shortener

Upload a short URL, then redirect through /u/<name>:

$ curl -Fc='https://example.com/very/long/path' -Fn=ex https://f.950414.xyz
$ curl -L https://f.950414.xyz/u/~ex

Markdown rendering

Upload a markdown file and render it as HTML via /a/<name>:

$ curl -Fc=@README.md -Fn=readme https://f.950414.xyz
$ firefox https://f.950414.xyz/a/~readme

GitHub-flavored Markdown is supported, along with syntax highlighting and LaTeX math via MathJax.

Updating an existing paste

Use the manageUrl returned at upload time:

$ curl -X PUT -Fc='kawaii~' \
    https://f.950414.xyz/~hitagi:22@-OJWcTOH2jprTJWYadmDv

PUT accepts the same fields as POST (c, e, s). Note that e recalculates the expiration starting from the update time.

Deleting a paste

$ curl -X DELETE https://f.950414.xyz/~hitagi:22@-OJWcTOH2jprTJWYadmDv
the paste will be deleted in seconds

Deletion may take a few seconds to propagate globally.

Tips

Common errors

Status Meaning
400 Malformed request (bad field, illegal name, bad expire).
403 Wrong password when updating or deleting.
404 Paste not found, or already expired.
409 Custom name is already in use.
413 Content exceeds the configured max size.
500 Unexpected server error — please report it.

For the full HTTP API including HEAD, OPTIONS, response headers, and edge cases, see api.md.