Skip to main content

Disable a MySQL user

POST/v2/mysql-users/{mysqlUserId}/actions/disable
API version
v2
Request method
POST
Operation ID
database-disable-mysql-user

Request​

  • mysqlUserIdstringrequired

    ID of the MySQLUser to disable.

Responses​

No response content specified.

Usage examples​

$ curl \
--fail \
--location \
-X POST \
-H "Authorization: Bearer $MITTWALD_API_TOKEN" \
https://api.mittwald.de/v2/mysql-users/string/actions/disable
import { MittwaldAPIV2Client } from "@mittwald/api-client";
import { assertStatus } from "@mittwald/api-client-commons";

const client = MittwaldAPIClient.newWithToken(process.env.MITTWALD_API_TOKEN);
const response = await client.database.disableMysqlUser({
"mysqlUserId": "string"
});

assertStatus(response, 204);

use \Mittwald\ApiClient\Generated\V2\Clients\Database\DisableMysqlUser\DisableMysqlUserRequest;

$client = MittwaldAPIClient::newWithToken(getenv('MITTWALD_API_TOKEN'));

$request = (new DisableMysqlUserRequest(
mysqlUserId: "string"
));
$response = $client->database()->disableMysqlUser($request);

var_dump($response->getBody();

On this page