Skip to content
Start here

PCAPs

List packet capture requests
client.MagicTransit.PCAPs.List(ctx, query) (*SinglePage[PCAPListResponse], error)
GET/accounts/{account_id}/pcaps
Get PCAP request
client.MagicTransit.PCAPs.Get(ctx, pcapID, query) (*PCAPGetResponse, error)
GET/accounts/{account_id}/pcaps/{pcap_id}
Create PCAP request
client.MagicTransit.PCAPs.New(ctx, params) (*PCAPNewResponse, error)
POST/accounts/{account_id}/pcaps
Stop full PCAP
client.MagicTransit.PCAPs.Stop(ctx, pcapID, body) error
PUT/accounts/{account_id}/pcaps/{pcap_id}/stop
ModelsExpand Collapse
type PCAP struct{…}
ID stringoptional

The ID for the packet capture.

maxLength32
minLength32
FilterV1 PCAPFilteroptional

The packet capture filter. When this field is empty, all packets are captured.

OffsetTime Timeoptional

The RFC 3339 offset timestamp from which to query backwards for packets. Must be within the last 24h. When this field is empty, defaults to time of request.

formatdate-time
Status PCAPStatusoptional

The status of the packet capture request.

One of the following:
const PCAPStatusUnknown PCAPStatus = "unknown"
const PCAPStatusSuccess PCAPStatus = "success"
const PCAPStatusPending PCAPStatus = "pending"
const PCAPStatusRunning PCAPStatus = "running"
const PCAPStatusConversionPending PCAPStatus = "conversion_pending"
const PCAPStatusConversionRunning PCAPStatus = "conversion_running"
const PCAPStatusComplete PCAPStatus = "complete"
const PCAPStatusFailed PCAPStatus = "failed"
Submitted stringoptional

The RFC 3339 timestamp when the packet capture was created.

System PCAPSystemoptional

The system used to collect packet captures.

TimeLimit float64optional

The packet capture duration in seconds.

maximum300
minimum1
Type PCAPTypeoptional

The type of packet capture. Simple captures sampled packets, and full captures entire payloads and non-sampled packets.

One of the following:
const PCAPTypeSimple PCAPType = "simple"
const PCAPTypeFull PCAPType = "full"
type PCAPFilter struct{…}

The packet capture filter. When this field is empty, all packets are captured.

DestinationAddress stringoptional

The destination IP address of the packet.

DestinationPort float64optional

The destination port of the packet.

Protocol float64optional

The protocol number of the packet.

SourceAddress stringoptional

The source IP address of the packet.

SourcePort float64optional

The source port of the packet.

PCAPsOwnership

List PCAPs Bucket Ownership
client.MagicTransit.PCAPs.Ownership.Get(ctx, query) (*SinglePage[Ownership], error)
GET/accounts/{account_id}/pcaps/ownership
Add buckets for full packet captures
client.MagicTransit.PCAPs.Ownership.New(ctx, params) (*Ownership, error)
POST/accounts/{account_id}/pcaps/ownership
Delete buckets for full packet captures
client.MagicTransit.PCAPs.Ownership.Delete(ctx, ownershipID, body) error
DELETE/accounts/{account_id}/pcaps/ownership/{ownership_id}
Validate buckets for full packet captures
client.MagicTransit.PCAPs.Ownership.Validate(ctx, params) (*Ownership, error)
POST/accounts/{account_id}/pcaps/ownership/validate
ModelsExpand Collapse
type Ownership struct{…}
ID string

The bucket ID associated with the packet captures API.

maxLength32
minLength32
DestinationConf string

The full URI for the bucket. This field only applies to full packet captures.

Filename string

The ownership challenge filename stored in the bucket.

Status OwnershipStatus

The status of the ownership challenge. Can be pending, success or failed.

One of the following:
const OwnershipStatusPending OwnershipStatus = "pending"
const OwnershipStatusSuccess OwnershipStatus = "success"
const OwnershipStatusFailed OwnershipStatus = "failed"
Submitted string

The RFC 3339 timestamp when the bucket was added to packet captures API.

Validated stringoptional

The RFC 3339 timestamp when the bucket was validated.

PCAPsDownload

Download Simple PCAP
client.MagicTransit.PCAPs.Download.Get(ctx, pcapID, query) (*Response, error)
GET/accounts/{account_id}/pcaps/{pcap_id}/download