improve ApiProvder interface
update README to use StatefulApiProvider