This API allows users to upload files from Google Drive to external services using a provided API key.
GET /upload?api=YOUR_API_KEY&drive_id=GOOGLE_DRIVE_FILE_ID
Make a GET request to the endpoint with the required parameters:
GET /upload?api=your_api_key&drive_id=your_drive_file_id
On successful upload or if the file already exists:
{
"status": "success",
"fileStatus": "NewAdd",
"name": "file_name.ext",
"key": "deaddrive_file_uid",
"driveId": "google_drive_file_id",
"size": 12345678,
"download": "/file/unique_file_uid",
"watch": "/embed/unique_file_uid"
}
Note: If the file already exists, "fileStatus": "AlreadyExist" will be returned and existing links will be used.
{
"status": "error",
"message": "Error message describing the issue"
}
api parameter is missing.drive_id parameter is missing.GET /upload?api=abc123&drive_id=1A2B3C4D5E6F7G8H9I0J
{
"status": "success",
"fileStatus": "NewAdd",
"name": "example.mp4",
"key": "xyz789",
"driveId": "1A2B3C4D5E6F7G8H9I0J",
"size": 104857600,
"download": "/file/xyz789",
"watch": "/embed/xyz789"
}
{
"status": "success",
"fileStatus": "AlreadyExist",
"name": "example.mp4",
"key": "xyz789",
"driveId": "1A2B3C4D5E6F7G8H9I0J",
"size": 104857600,
"download": "/file/xyz789",
"watch": "/embed/xyz789"
}
{
"status": "error",
"message": "Not a valid Google Drive ID"
}