Fix definitions layer missing "referenced"

The definitions layer is different than other layers in that it contains a "referenced" field. The api didn't handle that correctly.