Share what you're thinking.
Paste code, prose, or snippets. Beautifully styled, readable, and instant.
Copied!
Library of Pastes
Explore recently shared snippets. Stored in SQLite backend database.
Developer API Documentation
Integrate FoxBin.dev directly into your CLI scripts, terminal tools, or IDE extensions using our REST API.
POST
/api/pastes
Create a new snippet. Supports title, contents, language syntax settings, custom aliases, visibility limits, and auto-expiry.
Request Payload (JSON)
{
"id": "fb_unique_random_id",
"title": "My Python Web Scraper",
"content": "import urllib.request...",
"language": "python",
"visibility": "public",
"expiration": "1d",
"alias": "web-scraper",
"code": "FB-1234",
"createdAt": 1718963282000
}
Example Response (201 Created)
{
"success": true,
"id": "fb_unique_random_id"
}
GET
/api/pastes/{id_or_alias_or_code}
Retrieve a paste by its UUID, custom alphanumeric alias, or short numeric retrieval code.
Example Response (200 OK)
{
"id": "fb_unique_random_id",
"alias": "web-scraper",
"code": "FB-1234",
"title": "My Python Web Scraper",
"content": "import urllib.request...",
"language": "python",
"visibility": "public",
"expiration": "1d",
"createdAt": 1718963282000
}
PUT
/api/pastes/{id}
Update the text contents of an existing paste. Requires the creator authorization (Frontend verifies local ownership mapping).
Request Payload (JSON)
{
"content": "updated code script...",
"createdAt": 1718964500000
}
DELETE
/api/pastes/{id}
Deletes a snippet from the database (restricted to admin authorizations or creator context).