update for new cocktail api
Merge pull request #200 from silexlabs/cocktail-new-api

update for new cocktail api