refactor requesting and writing to store; wip