Checking for endpoint parameter before initialising Cube