walking through API code