The following SOAP methods are provided specifically for interaction with blacklists.
addToBlacklist
Add blacklist entry
bool addToBlacklist( int mandator_id, string entry, string comment = '' )
Details
Parameters
- int mandator_id: ID of the client in which the blacklist entry is to be made. For global users, the global blacklist is addressed with the ID 0, for client users, the blacklist that is assigned to the client.
Please note that global users who have switched to a client via the system interface are considered client users from that point on and ignore the parameter mandator_id until the global user has switched back to the "Global Overview" via the system interface. - string entry: E-mail address (e.g. mustermann@example.com) or e-mail domain (e.g. @example.com) to be added to the blacklist
- string comment: Optional comment
Return value
- bool: true in case of a successful entry, false if the entry already exists
Required rights
Edit Blacklist
Use
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:blac="https://scnem.com/soap.php/soap/blacklist">
<soapenv:Header/>
<soapenv:Body>
<blac:addToBlacklist>
<mandator_id>MANDTOR_ID</mandator_id>
<entry>BLACKLIST_ENTRY</entry>
<comment>BLACKLIST_ENTRY_COMMENT</comment>
</blac:addToBlacklist>
</soapenv:Body>
</soapenv:Envelope>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="https://scnem.com/soap.php/soap/blacklist">
<SOAP-ENV:Body>
<ns1:addToBlacklistResponse>
<addToBlacklistResult>true</addToBlacklistResult>
</ns1:addToBlacklistResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>