Docs
Live demo
POST/api/v2/targets/{id}/service-account/check

Check the service account of a MariaDB target now, without a discovery, and keep the answer as the target's state (access model MD-P1): the account Principal connects with must hold SELECT on mysql.*, CREATE USER, GRANT OPTION, SHOW DATABASES, PROCESS and CONNECTION ADMIN (SUPER before MariaDB 10.5.2) on the whole server. While it lacks any of them, applies, rotations, drift fixes and revocations on the target are refused before they change anything.

Parameters

Path1 required of 1
idstringpathrequired

Target ID (UUID)

Responses

200

The service account as the check found it

TargetServiceAccountResponse · 6 fields
target_idstring · uuidrequired

The target whose service account was checked. "Check again" checks it.

statestringrequired

ready when the account holds every privilege of the contract. Incomplete blocks changes.

readyincomplete
accountstringrequired

The account as MariaDB writes it, for example "principal@%".

missingarray of ServiceAccountPrivilegeResponserequired
3 fields
privilegestringrequired
read_grant_tablescreate_usergrant_optionshow_databasesprocessconnection_admin
labelstringrequired

The privilege as a database administrator names it, for example "GRANT OPTION".

breaksstringrequired

What Principal can't do without the privilege.

recommended_sqlstring

The GRANT statements a database administrator runs to meet the contract. Absent when ready or when the account name can't be written into a command safely.

checked_atstring · date-timerequired

When the check ran.

400

Principal reached the server but could not tell which account it connects with, or the connection broke in a way MariaDB diagnostics name (details.error_code, details.recommended_action)

403

The target rejected the configured credentials, or the caller cannot manage the target

404

The target does not exist or is not a MariaDB target

422

Principal could not reach the target, as a failed connection test. The response does not include driver details. Nothing was kept.

Common errors: 401 409 429 503 504. They mean the same for every operation, see Errors.

↑ ↓ to moveEnter to openEsc to close