Create Packet Capture Session

Create Packet Capture Session

Create an new packet capture session on given node with specified options

Request
URI
POST
https://nsxmanager.your.domain/api/v1/pktcap/session
COPY
Request Body
PacketCaptureRequest of type(s) application/json
Required
{
    "node": "string",
    "cappoint": "string",
    "capduration": 0,
    "capamount": 0,
    "capsource": "string",
    "filtertype": "string",
    "direction": "string",
    "capfilesize": 0,
    "options": {
        "values": [
            {
                "name": "string",
                "value": "string"
            }
        ]
    },
    "streamport": 0,
    "caprate": 0,
    "capvalue": "string",
    "streamaddress": "string",
    "capmode": "string"
}
string
node
Optional

Define the transport node to capture data.

string
cappoint
Required

Define the point to capture data.

Possible values are : VNIC, VMKNIC, VMNIC, VDRPORT, DVFILTER, LOGICALPORT,
integer As int32 As int32
capduration
Optional

Define the packet capture duration time. After the capture duration time, the capture process will stop working.

integer As int32 As int32
capamount
Optional

Define the packet capture amount size.

string
capsource
Required

This type is used to differenite the incoming request from CLI/UI.

Possible values are : CLI, UI,
string
filtertype
Optional

Define the capture filter type. Support PRE/POST mode.

Possible values are : PRE, POST,
string
direction
Optional

Define the capture direction. Support three types INPUT/OUTPUT/DUAL.

Possible values are : INPUT, OUTPUT, DUAL,
integer As int32 As int32
capfilesize
Optional

Define the packet capture file size limit.

options
Optional

options

integer As int32 As int32
streamport
Optional

Set the stream port to receive the capture packet.

integer As int32 As int32
caprate
Optional

Define the rate of packet capture process.

string
capvalue
Optional

Define the capture value of given capture point.

string
streamaddress
Optional

Set the stream address to receive the capture packet.

string
capmode
Optional

Define the capture streaming mode. The STREAM mode will send the data to given stream address and port. And the STANDALONE mode will save the capture file in local folder.

Possible values are : STANDALONE, STREAM,
Authentication
This operation uses the following authentication methods.
Responses
200

OK

Returns PacketCaptureSession of type(s) application/json
{
    "sessionid": "string",
    "filelocation": "string",
    "filesize": 0,
    "sessionname": "string",
    "errormsg": "string",
    "endtime": 0,
    "request": {
        "node": "string",
        "cappoint": "string",
        "capduration": 0,
        "capamount": 0,
        "capsource": "string",
        "filtertype": "string",
        "direction": "string",
        "capfilesize": 0,
        "options": {
            "values": [
                {
                    "name": "string",
                    "value": "string"
                }
            ]
        },
        "streamport": 0,
        "caprate": 0,
        "capvalue": "string",
        "streamaddress": "string",
        "capmode": "string"
    },
    "starttime": 0,
    "sessionstatus": "string"
}
string
sessionid
Required

Packet capture session id

string
filelocation
Optional

Packet capture file location

integer As int32 As int32
filesize
Optional

Packet capture file Size in bytes

string
sessionname
Optional

Packet capture session name

string
errormsg
Optional

Error messasge in capture

integer As int64 As int64
endtime
Optional

Timestamp when session was stopped in epoch millisecond

request
Required

request

integer As int64 As int64
starttime
Optional

Timestamp when session was created in epoch millisecond

string
sessionstatus
Required

Packet capture session status

Possible values are : CREATED, STARTED, STOPPED, FINISHED, ERROR,

400
Returns BadRequest of type(s) application/json
{
    "details": "string",
    "related_errors": [
        "ApiError Object"
    ],
    "module_name": "string",
    "error_message": "string",
    "error_code": 0
}
object
error_data
Optional

Additional data about the error

string
details
Optional

Further details about the error

array of ApiError
related_errors
Optional

Other errors related to this error

string
module_name
Optional

The module name where the error occurred

string
error_message
Optional

A description of the error

integer As int64 As int64
error_code
Optional

A numeric error code


403
Returns Forbidden of type(s) application/json
{
    "details": "string",
    "related_errors": [
        "ApiError Object"
    ],
    "module_name": "string",
    "error_message": "string",
    "error_code": 0
}
object
error_data
Optional

Additional data about the error

string
details
Optional

Further details about the error

array of ApiError
related_errors
Optional

Other errors related to this error

string
module_name
Optional

The module name where the error occurred

string
error_message
Optional

A description of the error

integer As int64 As int64
error_code
Optional

A numeric error code


404
Returns NotFound of type(s) application/json
{
    "details": "string",
    "related_errors": [
        "ApiError Object"
    ],
    "module_name": "string",
    "error_message": "string",
    "error_code": 0
}
object
error_data
Optional

Additional data about the error

string
details
Optional

Further details about the error

array of ApiError
related_errors
Optional

Other errors related to this error

string
module_name
Optional

The module name where the error occurred

string
error_message
Optional

A description of the error

integer As int64 As int64
error_code
Optional

A numeric error code


412
Returns PreconditionFailed of type(s) application/json
{
    "details": "string",
    "related_errors": [
        "ApiError Object"
    ],
    "module_name": "string",
    "error_message": "string",
    "error_code": 0
}
object
error_data
Optional

Additional data about the error

string
details
Optional

Further details about the error

array of ApiError
related_errors
Optional

Other errors related to this error

string
module_name
Optional

The module name where the error occurred

string
error_message
Optional

A description of the error

integer As int64 As int64
error_code
Optional

A numeric error code


500
Returns InternalServerError of type(s) application/json
{
    "details": "string",
    "related_errors": [
        "ApiError Object"
    ],
    "module_name": "string",
    "error_message": "string",
    "error_code": 0
}
object
error_data
Optional

Additional data about the error

string
details
Optional

Further details about the error

array of ApiError
related_errors
Optional

Other errors related to this error

string
module_name
Optional

The module name where the error occurred

string
error_message
Optional

A description of the error

integer As int64 As int64
error_code
Optional

A numeric error code


503
Returns ServiceUnavailable of type(s) application/json
{
    "details": "string",
    "related_errors": [
        "ApiError Object"
    ],
    "module_name": "string",
    "error_message": "string",
    "error_code": 0
}
object
error_data
Optional

Additional data about the error

string
details
Optional

Further details about the error

array of ApiError
related_errors
Optional

Other errors related to this error

string
module_name
Optional

The module name where the error occurred

string
error_message
Optional

A description of the error

integer As int64 As int64
error_code
Optional

A numeric error code