def _get_ptr_details(self, device, device_type):
        context = self.api.identity
        region = self.api.region_name
        if device_type.lower().startswith("load"):
            ep = pyrax._get_service_endpoint(context, "load_balancer", region)
            svc = "loadbalancers"
            svc_name = "cloudLoadBalancers"
        else:
            ep = pyrax._get_service_endpoint(context, "compute", region)
            svc = "servers"
            svc_name = "cloudServersOpenStack"
        href = "%s/%s/%s" % (ep, svc, utils.get_id(device))
        return (href, svc_name)
Test that we check the X-Requested-With header.
dataset/ETHPy150Open rackspace/pyrax/pyrax/clouddns.py/CloudDNSManager._get_ptr_details--crossover with--dataset/ETHPy150Open GoogleCloudPlatform/appengine-mapreduce/python/test/mapreduce/handlers_test.py/CleanUpJobTest.testCSRF