Agreed, that's actually what I tried first, but it wasn't working.  I pulled this from here: https://github.com/dimagi/commcare-hq/blob/master/corehq/apps/api/resources/v0_4.py#L28  (used here: https://github.com/dimagi/commcare-hq/blob/master/corehq/apps/api/tests.py#L109)