This 200-301 practice question tests your understanding of ai and network operations. The scenario asks you to isolate a root cause — eliminate options that address a different problem before choosing. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.
Exhibit
R1#show running-config | section interface GigabitEthernet0/0
interface GigabitEthernet0/0
ip address 192.0.2.1 255.255.255.0
no shutdown
!
R1#show ip interface brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 192.0.2.1 YES manual up up
RESTCONF base URI: https://192.0.2.1/restconf
Example GET URI (correct):
GET /restconf/data/ietf-interfaces:interfaces/interface=GigabitEthernet0/0
Accept: application/yang-data+json
Example PATCH URI (correct):
PATCH /restconf/data/Cisco-IOS-XE-native:native/interface/GigabitEthernet=0/0
Content-Type: application/yang-data+json
Body: {"Cisco-IOS-XE-native:interface":{"GigabitEthernet":[{"name":"0/0","shutdown":true}]}}
You are connected to R1 (192.0.2.1/24). Use RESTCONF to query the operational state of GigabitEthernet0/0 using the ietf-interfaces YANG module. Then, send a PATCH request to disable the interface (set 'enabled' to false) using the Cisco-IOS-XE-native YANG module. Identify the error when a PATCH request is sent with the wrong Content-Type header (application/json instead of application/yang-data+json) and when the PATCH URI uses an incorrect YANG path (ietf-interfaces instead of Cisco-IOS-XE-native).
R1#show running-config | section interface GigabitEthernet0/0
interface GigabitEthernet0/0
ip address 192.0.2.1 255.255.255.0
no shutdown
!
R1#show ip interface brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 192.0.2.1 YES manual up up
RESTCONF base URI: https://192.0.2.1/restconf
Example GET URI (correct):
GET /restconf/data/ietf-interfaces:interfaces/interface=GigabitEthernet0/0
Accept: application/yang-data+json
Example PATCH URI (correct):
PATCH /restconf/data/Cisco-IOS-XE-native:native/interface/GigabitEthernet=0/0
Content-Type: application/yang-data+json
Body: {"Cisco-IOS-XE-native:interface":{"GigabitEthernet":[{"name":"0/0","shutdown":true}]}}
A
The PATCH request fails with a 415 Unsupported Media Type error because the Content-Type header must be application/yang-data+json, not application/json.
RESTCONF requires the Content-Type header to be application/yang-data+json for write operations (POST, PUT, PATCH). Using application/json is not accepted, and the server returns a 415 Unsupported Media Type error.
B
The PATCH request fails with a 404 Not Found error because the URI uses ietf-interfaces, which is a read-only module for operational state; the server cannot write to it.
Why wrong: This is incorrect because while using ietf-interfaces in the PATCH URI would indeed cause an error (404 or 405), the question specifically asks about the error when the Content-Type header is wrong. The correct answer focuses on the Content-Type issue.
C
The PATCH request succeeds but the interface is not disabled because the body must use 'shutdown' instead of 'enabled'.
Why wrong: This is incorrect because the question states that the PATCH request is sent with the wrong Content-Type header, which would cause a 415 error before the server even processes the body. The body content is irrelevant if the Content-Type is wrong.
D
The PATCH request fails with a 400 Bad Request error because the body must be XML, not JSON.
Why wrong: This is incorrect because RESTCONF supports both JSON and XML payloads. The Content-Type header must be application/yang-data+json for JSON, but the error is not about XML vs JSON; it's about the specific media type.
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
The PATCH request fails with a 415 Unsupported Media Type error because the Content-Type header must be application/yang-data+json, not application/json.
The correct GET request uses the ietf-interfaces YANG module path to retrieve interface state. For the PATCH, the Cisco-IOS-XE-native module is used because it supports writing native configuration (including shutdown). Sending PATCH with Content-Type: application/json is rejected because RESTCONF requires application/yang-data+json. Using ietf-interfaces in the PATCH URI fails because that module is read-only for operational state; the server returns 404 or 405. The correct PATCH body sets 'shutdown' to true within the native interface container.
Key principle: NAT direction and interface roles matter as much as the IP address mapping. Inside/outside designation controls which traffic is translated.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
✓
The PATCH request fails with a 415 Unsupported Media Type error because the Content-Type header must be application/yang-data+json, not application/json.
Why this is correct
RESTCONF requires the Content-Type header to be application/yang-data+json for write operations (POST, PUT, PATCH). Using application/json is not accepted, and the server returns a 415 Unsupported Media Type error.
Related concept
Static NAT maps one inside address to one outside address.
✗
The PATCH request fails with a 404 Not Found error because the URI uses ietf-interfaces, which is a read-only module for operational state; the server cannot write to it.
Why it's wrong here
This is incorrect because while using ietf-interfaces in the PATCH URI would indeed cause an error (404 or 405), the question specifically asks about the error when the Content-Type header is wrong. The correct answer focuses on the Content-Type issue.
✗
The PATCH request succeeds but the interface is not disabled because the body must use 'shutdown' instead of 'enabled'.
Why it's wrong here
This is incorrect because the question states that the PATCH request is sent with the wrong Content-Type header, which would cause a 415 error before the server even processes the body. The body content is irrelevant if the Content-Type is wrong.
✗
The PATCH request fails with a 400 Bad Request error because the body must be XML, not JSON.
Why it's wrong here
This is incorrect because RESTCONF supports both JSON and XML payloads. The Content-Type header must be application/yang-data+json for JSON, but the error is not about XML vs JSON; it's about the specific media type.
Option-by-option analysis
Why each answer is right or wrong
Understanding why wrong answers are wrong — and when they would be correct — is what separates a 750 score from a 900. The 200-301 exam frequently reuses these exact scenarios with slightly different constraints.
✓The PATCH request fails with a 415 Unsupported Media Type error because the Content-Type header must be application/yang-data+json, not application/json.Correct answer▾
Why this is correct
RESTCONF requires the Content-Type header to be application/yang-data+json for write operations (POST, PUT, PATCH). Using application/json is not accepted, and the server returns a 415 Unsupported Media Type error.
✗The PATCH request fails with a 404 Not Found error because the URI uses ietf-interfaces, which is a read-only module for operational state; the server cannot write to it.Wrong answer — click to see why▾
Why this is wrong here
The specific factual error is that the question asks about the error when the Content-Type header is wrong, not the URI path. The URI path error is a separate issue.
Why candidates choose this
Candidates might pick this because they know that ietf-interfaces is read-only and that using it in a PATCH would fail, but they overlook that the question is specifically about the Content-Type header error.
✗The PATCH request succeeds but the interface is not disabled because the body must use 'shutdown' instead of 'enabled'.Wrong answer — click to see why▾
Why this is wrong here
The specific factual error is that a wrong Content-Type header causes a rejection before any body parsing, so the request does not succeed.
Why candidates choose this
Candidates might think that the server might accept the request but ignore the 'enabled' field, not realizing that the Content-Type error prevents processing.
✗The PATCH request fails with a 400 Bad Request error because the body must be XML, not JSON.Wrong answer — click to see why▾
Why this is wrong here
The specific factual error is that RESTCONF does accept JSON; the issue is the exact media type string, not the format.
Why candidates choose this
Candidates might confuse RESTCONF with NETCONF, which uses XML, or think that JSON is not supported, but RESTCONF supports both.
Analysis generated from the official 200-301blueprint and verified against question context. The “when correct” sections are what AI assistants cite when candidates ask “what’s the difference between these options?”
Common exam traps
Common exam trap: NAT rules depend on direction and matching traffic
NAT is not only about the public address. The inside/outside interface roles and the ACL or rule that matches traffic are just as important.
Detailed technical explanation
How to think about this question
NAT questions usually test address translation, overload/PAT behaviour, static mappings and whether the right traffic is being translated. Read the interface direction and address terms carefully.
KKey Concepts to Remember
Static NAT maps one inside address to one outside address.
PAT allows many inside hosts to share one public address using ports.
Inside local and inside global describe the private and translated addresses.
NAT ACLs identify traffic for translation, not always security filtering.
TExam Day Tips
→Identify inside and outside interfaces first.
→Check whether the scenario needs static NAT, dynamic NAT or PAT.
→Do not confuse NAT matching ACLs with normal packet-filtering intent.
Key takeaway
NAT direction and interface roles matter as much as the IP address mapping. Inside/outside designation controls which traffic is translated.
Real-world example
How this comes up in practice
A small business has 20 workstations on the 192.168.1.0/24 network and one public IP from its ISP. The router uses PAT (NAT overload) so all 20 devices share one public address using different source ports. NAT questions test whether you understand the four address terms and which direction each translation applies.
Related glossary terms
Concepts from this question explained
These glossary pages explain the core terms tested in this 200-301 question in full detail.
Review the four NAT address types (inside local, inside global, outside local, outside global), PAT port overload, and static vs dynamic NAT use cases. Then practise related 200-301 NAT questions on configuration and troubleshooting.
AI and Network Operations — This question tests AI and Network Operations — Static NAT maps one inside address to one outside address..
What is the correct answer to this question?
The correct answer is: The PATCH request fails with a 415 Unsupported Media Type error because the Content-Type header must be application/yang-data+json, not application/json. — The correct GET request uses the ietf-interfaces YANG module path to retrieve interface state. For the PATCH, the Cisco-IOS-XE-native module is used because it supports writing native configuration (including shutdown). Sending PATCH with Content-Type: application/json is rejected because RESTCONF requires application/yang-data+json. Using ietf-interfaces in the PATCH URI fails because that module is read-only for operational state; the server returns 404 or 405. The correct PATCH body sets 'shutdown' to true within the native interface container.
What should I do if I get this 200-301 question wrong?
Review the four NAT address types (inside local, inside global, outside local, outside global), PAT port overload, and static vs dynamic NAT use cases. Then practise related 200-301 NAT questions on configuration and troubleshooting.
What is the key concept behind this question?
Static NAT maps one inside address to one outside address.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
This 200-301 practice question is part of Courseiva's free Cisco certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the 200-301 exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.