Updated 'README.md' example to the new API