Updated success/failure callbacks to come from config option.
Updated usage patterns for library.