Labels Ports
Returns an array of port labels.
List of Port Labels Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
GET /api/v1/labels/ports HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": [
{
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
]
}Creates a port label from the data that's been supplied
Port Label Create Config
Protocol.
udpPort
1Labels for port
["test"]Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
POST /api/v1/labels/ports HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 45
{
"protocol": "udp",
"port": 1,
"labels": [
"test"
]
}{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Update a Port Label given the provided object. This does not do a diff. You must send the complete object.
Port Label Create Config
Protocol.
udpPort
1Labels for port
["test"]Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
PUT /api/v1/labels/ports HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 45
{
"protocol": "udp",
"port": 1,
"labels": [
"test"
]
}{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Returns an array of protocols.
List of Port Labels Protocols Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
GET /api/v1/labels/ports/protocols HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": [
{
"name": "tcp"
}
]
}Fetches all labels by a specific protocol for all Ports.
The protocol of the Port labels to be returned.
Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
GET /api/v1/labels/ports/all/{protocol} HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Fetches a all Port labels for the port supplied in the path.
The Port number of the Port labels to be returned.
Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
GET /api/v1/labels/ports/{port} HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Fetches a specific port label from the protocol and port supplied in the path.
The port of the port label to be returned.
The protocol of the port label to be returned.
Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
GET /api/v1/labels/{port}/{protocol} HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Delete Port Label
The port of the port label to be deleted.
The protocol of the port label to be deleted.
An empty array
No content
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
DELETE /api/v1/labels/{port}/{protocol} HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
No content
Expose (un-hide) a hidden system port label.
The port of the port label to be exposed. Labels in this protocol will now appear for this Port in the UI.
The protocol of the port label to be shown.
Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
PUT /api/v1/labels/ports/{port}/{protocol}/show HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Hide system port label.
The port of the port label to be hidden.
The protocol of the port label to be hidden.
Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
PUT /api/v1/labels/ports/{port}/{protocol}/hide HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Reset system port label to default state.
The port of the port label to be reset.
The protocol of the port label to be reset.
Port Label Requested
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
PUT /api/v1/labels/ports/{port}/{protocol}/reset HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"meta": {
"code": 200,
"count": 1
},
"data": {
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
}Bulk upload port labels. New labels will be created, and existing labels will be replaced. Limited to 10,000 labels per request.
Port Label Create Config
Protocol.
udpPort
1Labels for port
["test"]Result of Port Labels bulk upload
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
PUT /api/v1/labels/ports/bulk HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 47
[
{
"protocol": "udp",
"port": 1,
"labels": [
"test"
]
}
]{
"meta": {
"code": 200,
"count": 1
},
"data": [
{
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
]
}Bulk delete port labels from the data that's been supplied
Delete Port Labels via port or protocol or both. One of port or protocol is required. Both may be provided as well.
Port. Optional if protocol is provided.
1Protocol. Optional is port is provided.
udpResult of Port Labels bulk upload
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
DELETE /api/v1/labels/ports/bulk HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 29
[
{
"port": 1,
"protocol": "udp"
}
]{
"meta": {
"code": 200,
"count": 1
},
"data": [
{
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
]
}Upload Port labels via a CSV file. New labels will be created, and existing labels will be replaced. Limited to 10,000 labels per request.
The CSV must be a text file and should NOT have any headers. Multiple labels can be assigned per protocol by having additional columns.
Example CSV:
Port1, Protocol1, Label1
Port1, Protocol2, Label1, Label2
Port2, Protocol1, Label3
Port2, Protocol4, Label4, Label5, Label6
The CSV file to upload
Result of Port Labels bulk upload
Bad Request. Typically due to a malformatted JSON body, or parameter values are not validating.
Access token is missing or invalid
Access is forbidden
Unknown Error Occurred
PUT /api/v1/labels/ports/upload HTTP/1.1
Host: api.netography.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: multipart/form-data
Accept: */*
Content-Length: 15
{
"file": "text"
}{
"meta": {
"code": 200,
"count": 1
},
"data": [
{
"protocol": "udp",
"port": 1,
"default": true,
"hasdefault": true,
"hide": false,
"labels": [
"test"
]
}
]
}Last updated