Add API + tests for Swarm

Specially here, in which the abundance is actually important for swarm (I think)