Merging upstream changes

The public API changed so we'll need to update the methods in BFAPIClient, but it should be very straightforward.