Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Examples on curl_examples.sh not working #85

Closed
wants to merge 1 commit into from

Conversation

xanderstevenson
Copy link

Unfortunately, the Chuck Norris API introduced at around 18:24 of the video is no longer online….

https://developer.cisco.com/video/net-prog-basics/01-programming_fundamentals/rest_part_1/curl_examples.sh


…and it’s referenced as well in the GitHub repo here…

https://github.com/CiscoDevNet/netprog_basics/blob/master/programming_fundamentals/rest_part_1/curl_examples.sh

We could replace the Chuck Norris API with something like the Dog API (https://dog.ceo/dog-api/):

curl https://dog.ceo/api/breeds/image/random

{"message":"https:\/\/images.dog.ceo\/breeds\/dane-great\/n02109047_20023.jpg","status":"success"}

curl https://dog.ceo/api/breed/hound/images/random

{"message":"https:\/\/images.dog.ceo\/breeds\/hound-basset\/n02088238_305.jpg","status":"success"}



…in regards to this curl_examples.sh file, the Network Programmability with RESTCONF example cURL on lines 17-21 will not work as written. However, if we change the URL to either of these two, it will work:

sandbox-iosxe-latest-1.cisco.com
sandbox-iosxe-recomm-1.cisco.com

So, the video doesn’t need to be updated, but the curl_examples.sh file does, because at 31:11 Hank urges the users to go back and run these code examples.

    Unfortunately, the Chuck Norris API introduced at around 18:24 of the video is no longer online….

    https://developer.cisco.com/video/net-prog-basics/01-programming_fundamentals/rest_part_1/curl_examples.sh
    

    …and it’s referenced as well in the GitHub repo here…

    https://github.com/CiscoDevNet/netprog_basics/blob/master/programming_fundamentals/rest_part_1/curl_examples.sh

   
   We could replace the Chuck Norris API with something like the Dog API (https://dog.ceo/dog-api/):
   

    curl https://dog.ceo/api/breeds/image/random

    {"message":"https:\/\/images.dog.ceo\/breeds\/dane-great\/n02109047_20023.jpg","status":"success"}

    curl https://dog.ceo/api/breed/hound/images/random

    {"message":"https:\/\/images.dog.ceo\/breeds\/hound-basset\/n02088238_305.jpg","status":"success"}



    …in regards to this curl_examples.sh file, the Network Programmability with RESTCONF example cURL on lines 17-21 will not work as written. However, if we change the URL to either of these two, it will work:

    sandbox-iosxe-latest-1.cisco.com
    sandbox-iosxe-recomm-1.cisco.com

    So, the video doesn’t need to be updated, but the curl_examples.sh file does, because at 31:11 Hank urges the users to go back and run these code examples.
@xanderstevenson
Copy link
Author

Since the README mentions we're using the Recommended code sandbox, we should use this URL:

sandbox-iosxe-recomm-1.cisco.com

@xanderstevenson xanderstevenson closed this by deleting the head repository Sep 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant