Zum Hauptinhalt springen

Update blacklist for a given project ID

PUT/v2/projects/{projectId}/mailsettings/blacklist
API-Version
v2
Request-Methode
PUT
Operation-ID
deprecated-mail-projectsetting-update-blacklist

Request​

  • projectIdstring
    required

    ID of the project you want to update blacklist for

Responses​

Kein Response-Inhalt angegeben.

Nutzungsbeispiele​

$ curl \
--fail \
--location \
-X PUT \
-d '{"blacklist":["string"]}' \
-H "Authorization: Bearer $MITTWALD_API_TOKEN" \
-H 'Content-Type: application/json' \
https://api.mittwald.de/v2/projects/string/mailsettings/blacklist
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.mail.deprecatedMailProjectsettingUpdateBlacklist({
"projectId": "string",
"data": {
"blacklist": [
"string"
]
}
});

assertStatus(response, 200);

use \Mittwald\ApiClient\Generated\V2\Clients\Mail\DeprecatedMailProjectsettingUpdateBlacklist\DeprecatedMailProjectsettingUpdateBlacklistRequest;
use \Mittwald\ApiClient\Generated\V2\Clients\Mail\DeprecatedMailProjectsettingUpdateBlacklist\DeprecatedMailProjectsettingUpdateBlacklistRequestBody;

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

// TODO: Please consult the properties and constructor signature of
// DeprecatedMailProjectsettingUpdateBlacklistRequestBody to learn how to construct a valid instance
$body = new DeprecatedMailProjectsettingUpdateBlacklistRequestBody(/* TODO: ... */);

$request = (new DeprecatedMailProjectsettingUpdateBlacklistRequest(
projectId: "string",
body: $body
));
$response = $client->mail()->deprecatedMailProjectsettingUpdateBlacklist($request);

var_dump($response->getBody();

Auf dieser Seite