--- name: shz-al description: Upload, fetch, update, or delete text/binary content via https://pastebin.jiaqicai.com, a curl-friendly pastebin. Use when you need a quick public URL for sharing long output, hosting a small file, shortening a URL, or rendering markdown as HTML. --- # shz.al A pastebin hosted on Cloudflare Workers at `https://pastebin.jiaqicai.com`. Every operation is plain HTTP and works with `curl`. Random paste names appear bare (e.g. `abcd`); custom names are returned with a leading `~` (e.g. `~hitagi`). ## Upload ```shell curl -Fc='hello, world' https://pastebin.jiaqicai.com # text curl -Fc=@file.png https://pastebin.jiaqicai.com # file | curl -Fc=@- https://pastebin.jiaqicai.com # stdin ``` Response: ```json { "url": "https://pastebin.jiaqicai.com/abcd", "manageUrl": "https://pastebin.jiaqicai.com/abcd:", "expireAt": "2026-05-21T10:33:06.114Z" } ``` Persist `manageUrl` if the paste may need to be updated or deleted later — it is the only way to authenticate as the owner. ## Optional upload fields - `-Fn=` — custom name (≥3 chars, returned prefixed with `~`). - `-Fe=` — expiration: integer/float with unit `s`/`m`/`h`/`d` (default seconds). E.g. `-Fe=30m`, `-Fe=14d`. - `-Fs=` — set a specific management password. - `-Flang=` — mark for syntax highlighting on the display page. - `-Fp=1` — private mode: 24-char unguessable random name. ## Fetch ```shell curl https://pastebin.jiaqicai.com/ # raw content curl -OJ https://pastebin.jiaqicai.com/~ # save with server filename curl https://pastebin.jiaqicai.com/m/ # JSON metadata (size, dates, …) curl -I https://pastebin.jiaqicai.com/ # HEAD only ``` Append `?a` for `Content-Disposition: attachment`, `?mime=` to override the response Content-Type, or append `.` to the path to set Content-Type by extension. ## Update / delete ```shell curl -X PUT -Fc='new content' curl -X DELETE ``` `PUT` accepts the same fields as upload; `e` recalculates expiration from now. ## Other URL forms - `/d/` — display code with syntax highlighting. Append `?lang=` to override the highlighting language. - `/a/` — render a markdown paste as HTML (GitHub-flavored Markdown + MathJax). - `/u/` — redirect to the URL stored in the paste (URL shortener). ## Limitations - Default expiration is `1d`, max `7d`. Pastes are deleted on expiry. - Max upload size is `128M`. - A single request body is capped at 100 MB by Cloudflare (you get HTTP `413 Payload Too Large` back, returned by the platform before the worker runs). Files larger than 100 MB therefore cannot be sent via a single `curl -Fc=@…` — use the web UI at `https://pastebin.jiaqicai.com` or the `pb` CLI (see [scripts/](https://github.com/SharzyL/pastebin-worker/tree/goshujin/scripts)), both of which split large files automatically. - Treat the service as ephemeral storage — do not rely on it for archival. ## Full docs - `https://pastebin.jiaqicai.com/doc/curl.md` — comprehensive curl guide. - `https://pastebin.jiaqicai.com/doc/api.md` — HTTP API reference.