The following example shows a <edit-config> request and response to create a basic VPRN service with a SAP; the system creates the service/interface, but fails to create the SAP because the specified port encapsulation is invalid.
<?xml version="1.0" encoding="UTF-8"?>
<rpc message-id="101"
xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<edit-config>
<target>
<running/>
</target>
<config>
<configure>
<service>
<vprn operation="create">
<interface>
<ip-int-name>"test"</ip-int-name>
<sap>
<sap-id>"2/1/1"</sap-id>
</sap>
</interface>
<service-id>201</service-id>
<customer>1</customer>
</vprn>
</service>
</configure>
</config>
</edit-config>
</rpc>
]]>]]>
The following example shows the reply.
<?xml version="1.0" encoding="UTF-8"?>
<rpc-reply message-id="101" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<rpc-error>
<error-type>application</error-type>
<error-tag>operation-failed</error-tag>
<error-severity>error</error-severity>
<error-info>
<err-element>edit-config</err-element>
</error-info>
<error-message>
command failed -
'configure service vprn "201" customer 1 interface "test" sap "2/1/1"'
MINOR: CLI SAP-id has an invalid port number or encapsulation value.
</error-message>
</rpc-error>
</rpc-reply>
]]>]]>