updated samples to use v1.2 api