1.3.2.1 POST and DELETE Operations

For POST and DELETE operations, the following pattern is to be used to execute the operation asynchronously:

  1. The client initiates a POST or DELETE operation.

  2. The Network Controller returns HTTP code 202 (Accepted) with a Location header, an Azure-AsyncOperation header, and, optionally, a Retry-After header. The time interval in the Retry-After header can only be specified in seconds, with a minimum of 15 seconds and a maximum of 15 minutes.

  3. The client waits for the Retry-After interval, if it was specified, or the default of 60 seconds if it wasn't, as specified in section 2.2.1.3.7.

  4. Client invokes the Uniform Resource Identifier (URI) specified in the Location header using the GET verb.

  5. If the operation is not complete, the Network Controller returns 202 (Accepted) again, optionally with a Retry-After header.

  6. If the operation is complete, the Network Controller returns the exact same response that would have been returned had the operation been executed synchronously.

  7. As per the protocol for Asynchronous Operations described in section 1.3.2, a consumer can query the status of an asynchronous operation by initiating GET requests on the HTTP resource as specified in the Location header or Azure-AsyncOperation header. The Location header returned by the Network Controller is of the following form, where operationId is the value of the x-ms-request-id header returned by the resource provider.

     https://<url>/networking/v1/operationResults/{operationId}