I am trying to grab some data from Delicious, using URL class,
URL url = URL(u);
url.openStream();
open stream fails with 401,
url i am using is,
String(“https://” + creds + “@api.del.icio.us/v1/posts/recent”);
creds is a base64 encoded string e.g. user:pass encoded, i also tried non encoded form that fails also, can someone tell me what i am missing?
UPDATE:
As pointed out below, the URL class does have some mechanism for handling user authentication. However, the OP is correct that the del.icio.us service returns a 401 using code as shown above (verified with my own account, and I am providing the correct credentials .. sending them in the url unencoded).
Modifying the code slightly, however, works just fine by specifying the Authorization header manually: