Storage
Overview
The Storage API on VoIPBin is designed to help users manage their stored files and monitor their storage usage. This feature allows users to efficiently oversee their data within their allocated storage quota.
The API provides endpoints for various file operations, such as uploading, retrieving, and deleting files, as well as monitoring overall storage usage. These functionalities enable users to manage their data effectively.
File Management
The Files API enables comprehensive file management on the platform. It includes the following features:
Retrieve All Files: Fetch a list of all files stored by the authenticated user. This helps users view and organize their stored files efficiently.
Upload a File: Allows users to upload new files to the platform. This endpoint is essential for adding new data to the storage.
Retrieve a Single File: Get detailed information about a specific file using its unique identifier. This is useful for accessing file metadata and content, including the download URL.
Download a File: Download a file using the download URL.
Delete a File: Enables users to delete a specific file from the storage by its unique identifier. This helps manage storage space by removing unnecessary files.
Storage Account Management
The Storage Account API provides insights into the user’s storage usage. Users can retrieve current storage usage details, including:
Total amount of stored file size.
Count of stored files.
Storage quota.
Quota
Each user has a storage quota, currently set at 10GB, to ensure fair usage and efficient resource allocation. The Storage API helps users keep track of their stored files and make informed decisions about their storage needs.
By utilizing the Storage API, users can seamlessly manage their data and ensure optimal use of their allocated storage space.
Account
Account
{
"id": "<string>",
"customer_id": "<string>",
"total_file_count": <number>,
"total_file_size": <number>,
"tm_create": "<string>",
"tm_update": "<string>",
"tm_delete": "<string>"
}
id: Account’s ID.
customer_id: Customer’s ID.
total_file_count: Total file count.
total_file_size: Total file size(Byte).
example
{
"id": "1f8ccab9-1b64-11ef-8530-42010a7e5015",
"customer_id": "5e4a0680-804e-11ec-8477-2fea5968d85b",
"total_file_count": 2,
"total_file_size": 221762,
"tm_create": "2024-05-26 13:30:31.176034",
"tm_update": "2024-05-27 07:55:17.016150",
"tm_delete": "9999-01-01 00:00:00.000000"
}
File
File
{
"id": "<string>",
"customer_id": "<string>",
"owner_id": "<string>",
"reference_type": "<string>",
"reference_id": "<string>",
"name": "<string>",
"detail": "<string>",
"filename": "<string>",
"filesize": <number>,
"uri_download": "<string>",
"tm_download_expire": "<string>",
"tm_create": "2024-05-27 07:55:16.515315",
"tm_update": "9999-01-01 00:00:00.000000",
"tm_delete": "9999-01-01 00:00:00.000000"
}
id: File’s ID.
customer_id: Customer’s ID.
owner_id: Owner(Agent)’s ID. If the owner does not exist, this will be empty.
reference_type: Reference type.
reference_id: Reference ID.
name: File’s name.
detail: File’s detail.
filename: File’s filename.
filesize: File’s size(Byte).
uri_download: File’s download URI.
tm_download_expire: File’s download expiration time.
example
{
"id": "0c0c305c-7a55-4395-85a8-ae4860f01393",
"customer_id": "5e4a0680-804e-11ec-8477-2fea5968d85b",
"owner_id": "62005165-7592-4ff7-9076-55bf491023f2",
"reference_type": "",
"reference_id": "00000000-0000-0000-0000-000000000000",
"name": "",
"detail": "",
"filename": "Screenshot from 2024-05-26 21-58-51.png",
"filesize": 110881,
"uri_download": "https://example.com/storage_url",
"tm_download_expire": "2034-05-25 07:55:16.115684",
"tm_create": "2024-05-27 07:55:16.515315",
"tm_update": "9999-01-01 00:00:00.000000",
"tm_delete": "9999-01-01 00:00:00.000000"
}
Reference Type
Reference Type |
Description |
---|---|
none |
Has no reference information. |
recording |
Recording type |