From 967b3adc76b14f62b6b144c81fffff305b1081dc Mon Sep 17 00:00:00 2001 From: Greg Skinner Date: Wed, 12 Apr 2023 21:28:26 -0700 Subject: [PATCH 1/4] Update api_requests_example.py update username and password to reflect current config --- .../python_part_3/api_requests_example.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/programming_fundamentals/python_part_3/api_requests_example.py b/programming_fundamentals/python_part_3/api_requests_example.py index 5cc91db..acbd431 100644 --- a/programming_fundamentals/python_part_3/api_requests_example.py +++ b/programming_fundamentals/python_part_3/api_requests_example.py @@ -16,9 +16,9 @@ import requests from pprint import pprint router = {"ip": "ios-xe-mgmt.cisco.com", - "port": "9443", + "port": "443", "user": "developer", - "pass": "C1sco12345"} + "pass": "lastorangerestoreball8876"} headers = {"Accept": "application/yang-data+json"} From 1ac5695cc5baa3e1ffd23dc257a15d693607fd3c Mon Sep 17 00:00:00 2001 From: Greg Skinner Date: Thu, 13 Apr 2023 00:03:58 -0700 Subject: [PATCH 2/4] Update api_requests_example.py disable SSL warnings --- .../python_part_3/api_requests_example.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/programming_fundamentals/python_part_3/api_requests_example.py b/programming_fundamentals/python_part_3/api_requests_example.py index acbd431..c1085ee 100644 --- a/programming_fundamentals/python_part_3/api_requests_example.py +++ b/programming_fundamentals/python_part_3/api_requests_example.py @@ -15,6 +15,11 @@ import requests from pprint import pprint +import urllib3 + +# Disable SSL Warnings +urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) + router = {"ip": "ios-xe-mgmt.cisco.com", "port": "443", "user": "developer", From 3de75a0916e995b426ba93dee66ba64ea02de181 Mon Sep 17 00:00:00 2001 From: Greg Skinner Date: Sat, 15 Apr 2023 22:02:04 -0700 Subject: [PATCH 3/4] Update README.md update https port --- programming_fundamentals/rest_part_1/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/programming_fundamentals/rest_part_1/README.md b/programming_fundamentals/rest_part_1/README.md index 0e9aef6..a5b808a 100644 --- a/programming_fundamentals/rest_part_1/README.md +++ b/programming_fundamentals/rest_part_1/README.md @@ -24,10 +24,10 @@ This lesson leverages the [IOS XE on CSR Recommended Code Always On](https://dev ***Note: In the video, a different DevNet Sandbox is used*** -When running the `curl` for the RESTCONF example, leverage `https://ios-xe-mgmt.cisco.com:9443` as the URL instead of `https://10.10.20.21`. +When running the `curl` for the RESTCONF example, leverage `https://ios-xe-mgmt.cisco.com:443` as the URL instead of `https://10.10.20.21`. ## Download Slides You can download the slides for this lesson [here](https://developer.cisco.com/fileMedia/download/c5942bff-3499-3e11-829a-fa90ebeb5fd1). -> *Suggestion: Right click, "Open in new tab"* \ No newline at end of file +> *Suggestion: Right click, "Open in new tab"* From 0f23d4758ce387c4d43ee0108109198ced8c43f6 Mon Sep 17 00:00:00 2001 From: Greg Skinner Date: Sat, 15 Apr 2023 22:10:33 -0700 Subject: [PATCH 4/4] Update curl_examples.sh update password and https port --- programming_fundamentals/rest_part_1/curl_examples.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/programming_fundamentals/rest_part_1/curl_examples.sh b/programming_fundamentals/rest_part_1/curl_examples.sh index c5558bd..19fce31 100644 --- a/programming_fundamentals/rest_part_1/curl_examples.sh +++ b/programming_fundamentals/rest_part_1/curl_examples.sh @@ -16,6 +16,6 @@ curl https://api.icndb.com/jokes/random?limitTo=nerdy # Example 3: Network Programmability with RESTCONF curl -vk \ - -u developer:C1sco12345 \ + -u developer:lastorangerestoreball8876 \ -H 'accept: application/yang-data+json' \ - https://ios-xe-mgmt.cisco.com:9443/restconf/data/ietf-interfaces:interfaces/interface=GigabitEthernet2 + https://ios-xe-mgmt.cisco.com:443/restconf/data/ietf-interfaces:interfaces/interface=GigabitEthernet2