CRUD Operations

The Representational State Transfer Configuration Protocol (RESTCONF) API supports the GET, POST, PATCH, and DELETE HTTP methods.

Table 1. RESTCONF API CRUD Methods
MethodDescriptionUsage
GETSent by the client to retrieve data and metadata for a resource. If the GET method succeeds, response message body will have the JSON result.
POSTSent by the client to create a data resource or invoke an operation resource.If the POST method succeeds, a "201 Created" status-line is returned and there is no response message body. If the data resource already exists, then the POST request must fail and "409 Conflict" status-line is returned.
PATCHCan be used by the client to create or update a target resource. Merges the contents of the message body with the target resource.If the PATCH request succeeds, a "200 OK" status-line is returned if there is a message body, and "204 No Content" is returned if no message body is sent.
DELETEUsed by the client to delete the target resource.If the DELETE request succeeds, a "204 No Content" status-line is returned.