allow resource to be specified as well