main d2d1951

Retrieve a random term from any termbase

Returns a random term from any termbase. You can define min length, max length and whether symbols are allowed

Request

Method: POST
Route: api/entry/random
Example: api/entry/random
Input Value
database teleterm
allow_symbols false
max_len_term_en 10
max_len_term_gr 10
Request Headers
host: localhost:8000
accept: application/json
user-agent: Symfony
content-type: application/json
accept-charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
content-length: 87
accept-language: en-us,en;q=0.5

Response

200 JSON
Response Headers
date: Wed, 09 Sep 2026 08:48:02 GMT
content-type: application/json
cache-control: no-cache, private
{
    "data": [
        {
            "RECNUM": 51878,
            "TERMEN": "signal",
            "TERMGR": "σήμα",
            "MOTOVOC": "R  12",
            "CODE": null,
            "STAGE": "3",
            "ABBRGR": null,
            "STERMGR": "Ελληνική Μετάφραση της TBR 2",
            "SECTION": null,
            "NOTEGR": null,
            "ABBREN": null,
            "STERMEN": "TBR 2 - Attachment requirements for TE - X.25 Interface",
            "TERMFR": null,
            "ABBRFR": null,
            "TERMGE": null,
            "ABBRGE": null,
            "NOUN": "c",
            "NOTEEN": null,
            "GRAECOEN": null,
            "GRAECOFR": null,
            "GRAECOGE": null,
            "SOURCES": "S20, L17, R12",
            "MARKING": 0,
            "MOTOVOC2": "R  12",
            "DATEOFRECORD": null,
            "N-LECTICITY_EN": null,
            "N-LECTICITY_GR": null,
            "N-LECTICITY_FR": null,
            "SOURCE_UNIFORM": "R  12",
            "LINK": null
        }
    ],
    "system": {
        "messages": [],
        "status": 200,
        "status_text": "OK",
        "errors": [],
        "error_code": 0
    },
    "metadata": {
        "termmaster_games": 2242,
        "database": "teleterm",
        "uid": 100051878,
        "request": {
            "database": "teleterm",
            "allow_symbols": false,
            "max_len_term_gr": 10,
            "max_len_term_en": 10
        },
        "count": 1
    }
}

Time: 237.08

select * from `TELETERM_TELETERM` where TERMEN REGEXP '^[A-Za-z ]+$' AND length(TERMEN) <= 10 AND length(TERMGR) <= 10 order by RAND() limit 1

Time: 0.74

select * from `GAME_STATISTICS` where `GAME_STATISTICS`.`id` = ? limit 1
Bindings
0: 1

Time: 1.99

update `GAME_STATISTICS` set `value` = `value` + 1 where `id` = ?
Bindings
0: 1

Request

Method: POST
Route: api/entry/random
Example: api/entry/random
Input Value
database teleterm
allow_symbols false
max_len_term_en 10
max_len_term_gr 10
Request Headers
host: localhost:8000
accept: application/json
user-agent: Symfony
content-type: application/json
accept-charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
content-length: 87
accept-language: en-us,en;q=0.5