Uploading files now requires authentication. You must generate an API token from your Profile. Include this token in your requests using the Bearer Token method.
Authorization: Bearer YOUR_TOKEN_HERE
When you send us files with POST, we store them and return an url for you in JSON. Note: Guest uploads are currently disabled; you must use an authenticated request.
{
"status": true,
"data": {
"file": {
"url": {
"full": "https://file.fast/BpQ/test",
"short": "https://file.fast/BpQ"
},
"metadata": {
"id": "BpQ",
"name": "test.txt",
"size": {
"bytes": 13,
"readable": "13 B"
}
}
}
}
}
{
"status": false,
"errors": {
"file": ["The file may not be greater than 7 GB."]
}
}
{
"status": false,
"errors": {
"message": "Unauthenticated. Use a valid Bearer token from your profile."
}
}
The file field is required.The file is invalid.The file may not be greater than 7 GB.Max files per hour reached.Max files per day reached.Max bytes per hour reached.Max bytes per day reached.You can send us a GET request to grab info about a file. We respond with a JSON array. Hint: Use the [status] key (true/false) if you want to check if a file exists. Also, if the requested file does not exist, the response will be sent as a 404.
{
"status": true,
"data": {
"file": {
"url": {
"full": "https://file.fast/m40/a",
"short": "https://file.fast/m40"
},
"metadata": {
"id": "m40",
"name": "test.txt",
"size": {
"bytes": "162249833",
"readable": "154.73 MiB"
}
}
}
}
}
{
"status": false,
"errors": {
"file": "The file you are looking for does not exist."
}
}
Get a list of your uploaded files. Results are paginated.
Use the ?page= query parameter to navigate through pages.
{
"status": true,
"data": {
"files": [
{
"url": {
"full": "https://file.fast/BpQ/test",
"short": "https://file.fast/BpQ"
},
"metadata": {
"id": "BpQ",
"name": "test.txt",
"size": {
"bytes": 13,
"readable": "13 B"
}
}
}
],
"pagination": {
"current_page": 1,
"last_page": 1,
"per_page": 20,
"total": 1
}
}
}
Permanently delete a file using its ID (secret).
{
"status": true,
"message": "File deleted successfully."
}
{
"status": false,
"errors": {
"file": "File not found or you do not have permission to delete it."
}
}