Wanderlust-response

Can anyone help with the Wanderlust project in the Introduction to Javascript course?
Wanderlust

I have got to step 13 and have created developer accounts in foursquare and APIXU. When I look at the response in the javascript console and copy and paste the URL into a new browser window I get the message

{“meta”:{“code”:400,“errorType”:“invalid_auth”,“errorDetail”:“Missing access credentials. See https://developer.foursquare.com/docs/api/configuration/authentication for details.”,“requestId”:“5c721b024c1f67634bed46ba”},“response”:{}}

rather than all the code necessary for me to view the object. It is obviously something to do with my foursquare registration but I can’t figure out what. I have the client ID and secret provided.

When I registered it asked for an App URL-perhaps this is wrong. I have tried using

https://www.codecademy.com/courses/introduction-to-javascript/projects/wanderlust
for the app url and also
https://api.foursquare.com/v2/venues/explore
on both occasions the response was the same.

Can anyone advise me?
Thanks

I have now figured this out!
In the javascript console I was copying and pasting the first URL which didnt work however the second url below did! Not sure why as in the video walkthrough he copied the first url!

Response {type: “cors”, url: “https://api.foursquare.com/v2/venues/explore?near=…C03M5OFNTNEMR2ARFCX4YQOUYG3CDZ12WDVXMU&v=20180224”, redirected: false, status: 200, ok: true, …}
main.js:24 Fetch finished loading: GET "https://api.foursquare.com/v2/venues/explore?near=columbus&limit=10&client_id=QW53F2FKVAB5HKQ1YXLYAJA1SFD44IK1MPJQEOG0SJS2G3BG&client_secret=N3Q3BIWDYRC03M5OFNTNEMR2ARFCX4YQOUYG3CDZ12WDVXMU&v=20180224".

7 Likes

Thanks for sharing this, video is misleading and was trying to figure out this for while now…

Thaks it worked for me aswel!!

Thank you very much, i was trying to figure this out for a long time. that video is very mis-leading

I’m on a mac. I’ve been using Safari. I got the same error. I tried on chrome. It worked on chrome.

I tried building the render weather HTML string from scratch. I couldn’t get the date.dt value (which was “1589560637”) to render as a date with const date1 = new Date(date.dt), as the hint suggested. It kept giving me Monday Jan 19 1970. Anybody know why? I gave up and used const date1 = new Date(); to get the current timestamp instead - which is also what the helper function written by codecademy does. How would I construct a Date object from the returned json object’s .dt property?

can someone send the video please? I don’t seem to have the option to look at the video for some reason?

2 Likes

Here you go buddy,

3 Likes

Is the video misleading or good to learn from? In the project it doesn’t give me an option to see the video tutorial

I wouldn’t lean on it too hard — there are definitely some API changes that happened on OpenWeather’s end, and the steps in the project (currently) have changed from when they were recorded in the video. I followed the current steps and had the video open in a separate tab to make sure I wasn’t making any stupid syntax mistakes.

Also something that might impact the project: I got an email after confirming my account with OpenWeather: it sent along my API key, and a note that within a couple hours it would “be activated and ready to use” — I imagine this will lead to some frustrating hangups on Step 37, which prompts you to search for weather and venue results (my weather results didn’t come through, and after double-checking the code, I realized I was still within the “couple hours” mentioned in the email. :man_shrugging:

1 Like

I too am a bit hung up on moving from Step 13.

However, I’m stuck in the Chrome Developer Tool Console and unable to figure out how to copy the full url of the Response as needed in Step 14. All my google queries on how to accomplish this task aren’t bringing me answers.

I can hover over to a grey bar near the URL but also I can’t figure out how copy the full URL from the hovering bar.

Thanks to all on this thread, especially @simeon94 for sharing the now, apparently non-existent tutorial video.

Cheers

I am having the exact same issue.

I solved this by having the console be its own popout window! hit the three little dots top right next to the x. when your console is bigger you can copy the whole url.

Thank you so much for the feedback. I never did resolve the issue, but I just went back and opened the console to experiment and you’re right.

It is funny, early on in the problem solving I moved the console dock to the bottom of my screen from the right-hand side. If only I had done the same as you expanding…

Good luck with the rest of the project. I recall the rest of the project steps up to the Challenge Questions were well explained.

Upon completion I was too tired for the Challenge questions, so someday when I’m more confident in my skills and wiser I will attempt them.

1 Like

I really hope that they could update this and make in javascript only. I have been making API calls and rendering in React already and it was way simpler than this example.