[Contents] [Prev] [Next] [Index] [Report an Error]

Exchanging <hello> Tag Elements

The NETCONF server and client application each begin by emitting a <hello> tag element to specify which operations, or capabilities, they support from among those defined in the NETCONF specification. The <hello> tag element encloses the <capabilities> tag element and the <session-id> tag element, which specifies the process ID (PID) of the NETCONF server for the session. Within the <capabilities> tag element, a <capability> tag element specifies each supported function.

The client application must emit the <hello> tag element before any other tag element during the NETCONF session, and must not emit it more than once.

Each capability defined in the NETCONF specification is represented in a tag element by a uniform resource name (URN). Capabilities defined by individual vendors are represented by uniform resource identifiers (URIs), which can be URNs or URLs. The NETCONF API for SRC emits the following<hello> tag element (each<capability> tag element appears on three lines for legibility only):


<hello>
    <capabilities>
        <capability>urn:ietf:params:xml:ns:netconf:base:1.0</capability>
        <capability>
            urn:ietf:params:xml:ns:netconf:capability:candidate:1.0
        </capability>
        <capability>
            urn:ietf:params:xml:ns:netconf:capability:url:1.0?protocol=http,ftp,file
        </capability>
        <capability>http://xml.juniper.net/netconf/junos/1.0</capability>
        <capability>http://xml.juniper.net/netconf/junos/sdx/1.0</capability>
    </capabilities>
    <session-id>3911</session-id>
</hello>
]]>]]>

(For information about the ]]>]]> character sequence, see Generating Well-Formed XML Documents.)

The URIs in the <hello> tag element indicate the following supported capabilities:

To comply with the NETCONF specification, the client application also emits a <hello> tag element to define the capabilities it supports. It does not include the <session-id> tag element:


<hello>
    <capabilities>
        <capability>first-capability</capability>
        <!- - tag elements for additional capabilities - ->
    </capabilities>
</hello>
]]>]]>

[Contents] [Prev] [Next] [Index] [Report an Error]