Secrets
Read a secret by reference (server variable, Vault, AWS, Azure) with one function, so that scripts keep no password. Typical uses: pass a password to a connection, change the secret store without changing scripts.
secret set <name> <value>
Description
Keep a secret (sys): create it, or change its value. The value is encrypted; the configurations give its name. Returns 1
Keep a secret (sys): create it, or change its value. The value is encrypted; the configurations give its name. Returns 1
Parameters
name: The name: 1 to 100 letters, digits, _, . or - - String - required
value: The secret itself (password, token, key...) - String - required
name: The name: 1 to 100 letters, digits, _, . or - - String - required
value: The secret itself (password, token, key...) - String - required
admin
secret set "smtp_billing" "Sm7p-Billing-2026"
mentdb
1
secret set <name> <value> <json_params>
Description
Keep a secret with options: groups (the groups whose members may use it besides sys; kept when left out), description
Keep a secret with options: groups (the groups whose members may use it besides sys; kept when left out), description
Parameters
name: The name - String - required
value: The secret itself - String - required
json_params: The options as a JSON object - String - required
name: The name - String - required
value: The secret itself - String - required
json_params: The options as a JSON object - String - required
admin
secret set "erp_api" "k-77Hq3Zp" "{\"groups\": [\"api-mql\"], \"description\": \"ERP REST key\"}"
mentdb
1
Used in use cases (2 recipes)
Security engineer › Sign a PDF and check it: not modified is not the same as trusted
Security engineer › Decide what to do with a received invoice mail: SPF, DKIM and DMARC
Security engineer › Sign a PDF and check it: not modified is not the same as trusted
Security engineer › Decide what to do with a received invoice mail: SPF, DKIM and DMARC
Often used with
file delete · file exist · file mkdir · mail dkim_sign · mail dkim_verify · mail dmarc_evaluate · mail spf_check · pdf close
file delete · file exist · file mkdir · mail dkim_sign · mail dkim_verify · mail dmarc_evaluate · mail spf_check · pdf close
secret list
Description
The secrets a user may use: rows {name, value (sys only), groups, description, updated, by}
The secrets a user may use: rows {name, value (sys only), groups, description, updated, by}
admin
secret list
mentdb
[{"name": "aws_doc_key", "value": "AKIAIOSFODNN7EXAMPLE", "groups": [], "description": "", "updated": "2026-11-19 13:11:45", "by": "mentdb"}, {"name": "aws_doc_secret", "value": "wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY", "groups": [], "description": "", "updated": "2026-11-19 13:11:45", "by": "mentdb"}, {"name": "cosmos_doc_key", "value": "dsZQi3KtZmCv1ljt3VNWNm7sQUF1y5rJfC6kv5JiwvW0EndXdDku/dkKBp8/ufDToSxLzR4y+O/0H/t4bQtVNw==", "groups": [], "description": "", "updated": "2026-11-19 13:11:45", "by": "mentdb"}, {"name": "dkim_doc_key", "value": "nWGxne/9WmC6hEr0kuwsxERJxWl7MmkZcDusAxyuf2A=", "groups": [], "description": "", "updated": "2026-11-19 13:11:45", "by": "mentdb"}, {"name": "erp_api", "value": "k-77Hq3Zp", "groups": ["api-mql"], "description": "ERP REST key", "updated": "2026-11-19 13:11:57", "by": "mentdb"}, {"name": "glsa_xxxx", "value": "glsa_xxxx-value-0123456789", "groups": [], "description": "", "updated": "2026-11-19 13:11:45", "by": "mentdb"}, {"name": "smtp_billing", "value": "Sm7p-Billing-2026", "groups": [], "description": "", "updated": "2026-11-19 13:11:57", "by": "mentdb"}, {"name": "telegram_bot_token", "value": "telegram_bot_token-value-0123456789", "groups": [], "description": "", "updated": "2026-11-19 13:11:45", "by": "mentdb"}]
secret exists <name>
Description
1 when the secret exists and the user may use it, 0 otherwise
1 when the secret exists and the user may use it, 0 otherwise
Parameters
name: The name - String - required
name: The name - String - required
admin
secret exists "smtp_billing"
mentdb
1
an unknown one
admin
secret exists "nothing_here"
mentdb
0
secret delete <name>
Description
Delete a secret (sys): 1, or 0 when it does not exist. The connections that name it fail until it is created again
Delete a secret (sys): 1, or 0 when it does not exist. The connections that name it fail until it is created again
Parameters
name: The name - String - required
name: The name - String - required
admin
secret delete "erp_api"
mentdb
1
secret get <config> <ref>
Description
Read a secret by its reference. The configuration holds one JSON object per provider used: vault, aws, aws_param, azure (each one is the configuration of the family: see the pages Vault, AWS Secrets, Azure Key Vault). A mentdb: reference needs no configuration ("{}")
Read a secret by its reference. The configuration holds one JSON object per provider used: vault, aws, aws_param, azure (each one is the configuration of the family: see the pages Vault, AWS Secrets, Azure Key Vault). A mentdb: reference needs no configuration ("{}")
Parameters
config: The provider configurations as JSON: {"vault": {...}, "aws": {...}, "aws_param": {...}, "azure": {...}}, only those that are used. Every secret field of a configuration (password, token, api_key, secret_key, client_secret...) gives the NAME of a secret kept with secret set, never the secret itself: a value that is not the name of a secret the user may use is refused, without being shown. A secret is usable by sys and by the members of the groups given to secret set. - String - required
ref: The reference: mentdb:name, vault:app/db#password, aws:prod/db#password, aws_param:/prod/app/db_password, azure:db-password[/version][#field] - String - required
config: The provider configurations as JSON: {"vault": {...}, "aws": {...}, "aws_param": {...}, "azure": {...}}, only those that are used. Every secret field of a configuration (password, token, api_key, secret_key, client_secret...) gives the NAME of a secret kept with secret set, never the secret itself: a value that is not the name of a secret the user may use is refused, without being shown. A secret is usable by sys and by the members of the groups given to secret set. - String - required
ref: The reference: mentdb:name, vault:app/db#password, aws:prod/db#password, aws_param:/prod/app/db_password, azure:db-password[/version][#field] - String - required
admin
secret get "{\"vault\": {\"url\": \"http://127.0.0.1:8200\", \"token\": \"vault_token\"}, \"aws\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"aws_param\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"azure\": {\"vault_url\": \"https://myvault.vault.azure.net\", \"tenant_id\": \"contoso.onmicrosoft.com\", \"client_id\": \"6f1c2a9e-0d1b-4c55-9a51-3e2b7c0f8d11\", \"client_secret\": \"azure_client_secret\"}}" "vault:billing/db#password"
mentdb
B1ll-pass
a whole Vault secret (JSON object) (fixed result: real test servers, see the pages Vault, AWS Secrets and Azure Key Vault)
admin
secret get "{\"vault\": {\"url\": \"http://127.0.0.1:8200\", \"token\": \"vault_token\"}, \"aws\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"aws_param\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"azure\": {\"vault_url\": \"https://myvault.vault.azure.net\", \"tenant_id\": \"contoso.onmicrosoft.com\", \"client_id\": \"6f1c2a9e-0d1b-4c55-9a51-3e2b7c0f8d11\", \"client_secret\": \"azure_client_secret\"}}" "vault:billing/db"
mentdb
{"password": "B1ll-pass", "user": "billing"}
a field of an AWS Secrets Manager secret (fixed result: real test servers, see the pages Vault, AWS Secrets and Azure Key Vault)
admin
secret get "{\"vault\": {\"url\": \"http://127.0.0.1:8200\", \"token\": \"vault_token\"}, \"aws\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"aws_param\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"azure\": {\"vault_url\": \"https://myvault.vault.azure.net\", \"tenant_id\": \"contoso.onmicrosoft.com\", \"client_id\": \"6f1c2a9e-0d1b-4c55-9a51-3e2b7c0f8d11\", \"client_secret\": \"azure_client_secret\"}}" "aws:billing/db#password"
mentdb
B1ll-pass
an SSM parameter (SecureString decrypted) (fixed result: real test servers, see the pages Vault, AWS Secrets and Azure Key Vault)
admin
secret get "{\"vault\": {\"url\": \"http://127.0.0.1:8200\", \"token\": \"vault_token\"}, \"aws\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"aws_param\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"azure\": {\"vault_url\": \"https://myvault.vault.azure.net\", \"tenant_id\": \"contoso.onmicrosoft.com\", \"client_id\": \"6f1c2a9e-0d1b-4c55-9a51-3e2b7c0f8d11\", \"client_secret\": \"azure_client_secret\"}}" "aws_param:/billing/db_password"
mentdb
B1ll-pass
an Azure Key Vault secret (fixed result: real test servers, see the pages Vault, AWS Secrets and Azure Key Vault)
admin
secret get "{\"vault\": {\"url\": \"http://127.0.0.1:8200\", \"token\": \"vault_token\"}, \"aws\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"aws_param\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"azure\": {\"vault_url\": \"https://myvault.vault.azure.net\", \"tenant_id\": \"contoso.onmicrosoft.com\", \"client_id\": \"6f1c2a9e-0d1b-4c55-9a51-3e2b7c0f8d11\", \"client_secret\": \"azure_client_secret\"}}" "azure:billing-smtp"
mentdb
smtp-B1ll
a missing field is an error (fixed result: real test servers, see the pages Vault, AWS Secrets and Azure Key Vault)
admin
secret get "{\"vault\": {\"url\": \"http://127.0.0.1:8200\", \"token\": \"vault_token\"}, \"aws\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"aws_param\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"azure\": {\"vault_url\": \"https://myvault.vault.azure.net\", \"tenant_id\": \"contoso.onmicrosoft.com\", \"client_id\": \"6f1c2a9e-0d1b-4c55-9a51-3e2b7c0f8d11\", \"client_secret\": \"azure_client_secret\"}}" "vault:billing/db#token"
mentdb
ERROR: Sorry, an error appears (the secret 'vault:billing/db#token' has no field 'token').
a secret of MentDB, for sys
admin
secret get "{}" "mentdb:smtp_billing"
mentdb
Sm7p-Billing-2026
secret get <config> <ref> <json_params>
Description
Read a secret with options: ttl_ms (0: no cache; up to 86400000) keeps the value in the memory of the server, to avoid one call per execution of a frequent script
Read a secret with options: ttl_ms (0: no cache; up to 86400000) keeps the value in the memory of the server, to avoid one call per execution of a frequent script
Parameters
config: The provider configurations as JSON - String - required
ref: The reference - String - required
json_params: The options as a JSON object - String - required
config: The provider configurations as JSON - String - required
ref: The reference - String - required
json_params: The options as a JSON object - String - required
admin
secret get "{\"vault\": {\"url\": \"http://127.0.0.1:8200\", \"token\": \"vault_token\"}, \"aws\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"aws_param\": {\"access_key\": \"aws_access_key_id\", \"secret_key\": \"aws_secret_access_key\", \"region\": \"eu-west-3\"}, \"azure\": {\"vault_url\": \"https://myvault.vault.azure.net\", \"tenant_id\": \"contoso.onmicrosoft.com\", \"client_id\": \"6f1c2a9e-0d1b-4c55-9a51-3e2b7c0f8d11\", \"client_secret\": \"azure_client_secret\"}}" "vault:billing/db#password" "{\"ttl_ms\": 300000}"
mentdb
B1ll-pass
secret cache_clear
Description
Empty the cache of secret get (after a rotation). Returns the number of values removed
Empty the cache of secret get (after a rotation). Returns the number of values removed
admin
secret cache_clear
mentdb
1
