Add API + tests for Swarm

`getsize` imported but unused