How can I send a message from a ui_button inside an HTML template?

the data-action key contain special character, i.e. - you need to put qoute char (') to make it work. It will be

<md-button class="button save" ng-click="send({topic:'clicked', payload:'button was clicked', 'data-action':'save'})">SAVE</md-button>