Online Text Database

An API to easily store and update your text data, supporting GET and POST methods

Loading...

What is a text database?

The online text database (TextDB.online) is a free text data storage and sharing service platform. Users can store, update, and delete text data through a simple API interface. Stored text data can be downloaded and retrieved at any time.

Send data in application/x-www-form-urlencoded format to api.textdb.online/update to perform create, update, and delete operations on text data. GET and POST method requests are supported.

For detailed request information, please refer to the following API documentation.

API Documentation

API URL https://api.textdb.online/update/
Request Method GET / POST
Data Encoding application/x-www-form-urlencoded
Request Parameters key: Text identifier, length 6-60 characters, only supports the following characters: 0-9a-zA-Z-_
value: Text data, any text under 200,000 characters, if the value is empty, it indicates a record deletion.
Since there is no password authentication protection, it is recommended to use a randomly generated key of 20 characters or more to reduce the probability of collision and minimize business risk.
Request Example 【Create/Update】https://api.textdb.online/update/?key=123456&value=hello-world
【Delete】https://api.textdb.online/update/?key=123456&value=
【Read】 https://textdb.online/123456
If using the GET method to update data, please perform URLEncode encoding first. It is recommended to use the POST method request.
Response Parameters status: Request processing result, 1 for success, 0 for failure.
data.key: Custom text identifier.
data.url: The URL of the text record, through which the text data can be read.
req_id: API Request ID.
Response Example
{
    "status": 1,
    "data": {
        "key": "123456",
        "url": "https://textdb.online/123456"
    },
    "req_id": "131690600e2b79b47108"
}
Request Limit There is no limit to the number of reads, but the total number of create, update, and delete operations per IP per day is limited to 500.
Precautions 1. Text records will be automatically deleted after 1 year of no update operations. It is recommended to proactively delete them after use.
2. Text data does not have password protection for access. It is recommended to set a key length of at least 20 characters or add a unique prefix to avoid business risks caused by key collisions.
3. Data creation or update is slow, please avoid frequent operations.
4. It is strictly forbidden to store illegal data or use the platform for illegal purposes!

If the text record does not exist, it will be automatically created; if the record already exists, it will be updated.

After creation or update, the text record can be read through https://textdb.online/[key name], cross-origin requests are supported by default, and the content-type is text/plain.

When reading a text record, if the record exists, a 200 or 30x status code will be returned; if the record does not exist, a 404 status code and a 404 HTML page will be returned. You can determine the status of the text data by the response status code or content format.

TextDB.online service is built on the Cloudflare network, so there may be caching. When creating, updating, and deleting text data, the cache is automatically refreshed, which may be time-consuming. Please try to reduce the frequency of creation and updates, focusing mainly on reading.