Sending a request to https://www.wikidata.org/entity/Q42/ redirects to https://www.wikidata.org/wiki/Special:EntityData/Q42/ , which issues a Bad Request error:
$ curl https://www.wikidata.org/wiki/Special:EntityData/Q42/ -v * Hostname was NOT found in DNS cache * Trying 91.198.174.192... * Connected to www.wikidata.org (91.198.174.192) port 443 (#0) * successfully set certificate verify locations: * CAfile: none CApath: /etc/ssl/certs * SSLv3, TLS handshake, Client hello (1): * SSLv3, TLS handshake, Server hello (2): * SSLv3, TLS handshake, CERT (11): * SSLv3, TLS handshake, Server key exchange (12): * SSLv3, TLS handshake, Server finished (14): * SSLv3, TLS handshake, Client key exchange (16): * SSLv3, TLS change cipher, Client hello (1): * SSLv3, TLS handshake, Finished (20): * SSLv3, TLS change cipher, Client hello (1): * SSLv3, TLS handshake, Finished (20): * SSL connection using TLSv1.2 / ECDHE-RSA-AES128-GCM-SHA256 * Server certificate: * subject: C=US; ST=California; L=San Francisco; O=Wikimedia Foundation, Inc.; CN=*.wikidata.org * start date: 2014-11-21 18:26:02 GMT * expire date: 2015-11-22 18:26:02 GMT * subjectAltName: www.wikidata.org matched * issuer: C=BE; O=GlobalSign nv-sa; CN=GlobalSign Organization Validation CA - SHA256 - G2 * SSL certificate verify ok. > GET /wiki/Special:EntityData/Q42/ HTTP/1.1 > User-Agent: curl/7.38.0 > Host: www.wikidata.org > Accept: */* > < HTTP/1.1 400 Bad Request * Server nginx/1.1.19 is not blacklisted < Server: nginx/1.1.19 < Date: Sun, 18 Jan 2015 15:32:52 GMT < Content-Type: text/html; charset=utf-8 < Transfer-Encoding: chunked < Connection: keep-alive < X-Powered-By: HHVM/3.3.1 < X-Content-Type-Options: nosniff < Vary: Accept-Encoding < X-Varnish: 2237996273, 3783703291, 3806584600 < Via: 1.1 varnish, 1.1 varnish, 1.1 varnish < Age: 0 < X-Cache: cp1053 miss (0), amssq41 miss (0), amssq54 frontend miss (0) < Cache-Control: private, s-maxage=0, max-age=0, must-revalidate < X-Analytics: https=1 < <!DOCTYPE html> <html><head><title>Bad Request</title></head> <body><h1>Bad Request</h1><p>Invalid ID: Q42/.</p></body></html> * Connection #0 to host www.wikidata.org left intact
I think it should serve the resource or redirect to https://www.wikidata.org/wiki/Special:EntityData/Q42 instead