Skip to content
View as Markdown

POST Save AI Settings​

POST
/ai/settings

Save AI writing settings. The API key is encrypted before storage. If you send a masked key value starting with ****, the existing stored key is preserved. Sending an empty api_key clears the saved key.

Authorizations​

ApplicationPasswords

WordPress Application Passwords — use Basic auth with your WordPress username and an application password in the format: username:application_password

Type
API Key (header: Authorization)

Request Body​

application/json
JSON
{
"settings": {
"is_enabled": "string",
"provider": "string",
"model": "string",
"api_key": "string",
"custom_prompt": "string"
}
}

Responses​

AI settings saved successfully.

application/json
JSON
{
"message": "string"
}

Playground​

Authorization
Body

Samples​

Powered by VitePress OpenAPI