piwik/piwik — pull request #221 by crispygoth (2014-02-06 10:45:49+00:00)
Title: Added a setSiteAliasUrls method to the SitesManager API

This method works in a similar way to the addSiteAliasUrls method, but it completely overwrites the URL list rather than merely adding to it.

My use case: my site has an admin system where aliases can be added and removed by the users, and we need to update Piwik's alias list automatically. It's far easier to simply send over an API request containing the full list every time than to use the "add" method. The other option would be to use updateSite, but that means getting all the other data required by updateSite to send back.