@mahmoudimus sizeof() is an alias to count. Count may be more readable tho. http://php.net/manual/en/function.sizeof.php

Also, if there are multiple resources that's because their are multiple uri_specs. I just  made the second one the one that overrides (in this case bank_account_verifications) the original uri_spec (verifications) when the object is being created