add commcare plugin

there's a little bit of unrelated changes mixed in. sorry.