Fixing broken Sample API.

Renaming appropriate argument and expanding the API options.