Modifier une IP dédiée
Put /settings/ips/{id}
Paramètres dans l'URL :
| Nom | Description | Type | Obligatoire |
|---|---|---|---|
| id | Id de l'IP | String | Oui |
Paramètres :
| Nom | Description | Type | Obligatoire |
|---|---|---|---|
| type |
Type d'envoi pour l'IP
0 : transactionnel ; 1 : bulk |
Int | Oui |
Réponse :
| Nom | Description | Type |
|---|---|---|
| status | success / failure | String |
Langage de programmation :
Exemple de requête :
{
"type": 0
}
Exemple de réponse :
{
"status": "success"
}
Exemple de code :
curl -X PUT -d '{"type":"0"}' -H "Content-Type: application/json" -H "X-Tipimail-ApiUser:YOUR_SMTP_USERNAME" -H "X-Tipimail-ApiKey:YOUR_SMTP_KEY" https://api.tipimail.com/v1/settings/ips/558a732d576736081fc23f6f
require 'vendor/autoload.php';
$tipimail = new Tipimail\Tipimail('YOUR_SMTP_USERNAME', 'YOUR_API_KEY');
try {
$result = $tipimail->getSettingsService()->getDedicatedIpsService()->updateToBulk('646r54g6r4gr6g46g46546d4');
var_dump($result);
$result = $tipimail->getSettingsService()->getDedicatedIpsService()->updateToTransactional('646r54g6r4gr6g46g46546d4');
var_dump($result);
}
catch(Tipimail\Exceptions\TipimailException $e) {
echo 'Exception received :', $e->getMessage(), "\n";
}