NAV
Shell HTTP JavaScript Ruby Python PHP Java Go

Patrowl Dashboard API

What is Patrowl? 🦉

Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

Patrowl is an Offensive Security as a Service solution which allows you to improve your Exposure Management (EM), to secure your External Exposure aka External Security Posture.

Patrowl provides an API to retrieve and manage data from the PatrowlDashboard platform with HTTP requests. This documentation lists all these APIs.

What can I do with this API? 🤖

Everything you're used to dealing with on PatrowlDashboard can be done via API, for example:

Base URL:

Email: Support

Authentication

How to get your API Token? 🔑

Your API access token is accessible on Patrowl Dashboard in your account settings:

The token can be renewed or deleted from this same page.

How to use your API Token? 🙇

Your API access token has to be sent in every requests, in the Authorization header of the request:

Authorization: Token <your-API-token>

alerts

alerts_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/alerts/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/alerts/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/alerts/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/alerts/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/alerts/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/alerts/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/alerts/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/alerts/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/alerts/

API endpoint that allows Control to be viewed or edited.

Parameters

Name In Type Required Description
ack query boolean false Ack
created_at query string(date-time) false none
id query integer false none
level query number false Level
limit query integer false Number of results to return per page.
not_ack query boolean false Not ack
org_id query number false Organization
page query integer false A page number within the paginated result set.
search query string false Search in title and message.
sorted_by query array[string] false Ordering
title query string false none
type query number false Type
updated_at query string(date-time) false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -level
sorted_by -title
sorted_by -type
sorted_by -updated_at
sorted_by created_at
sorted_by level
sorted_by title
sorted_by type
sorted_by updated_at

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "type": "Control",
      "level": "Information",
      "message": "string",
      "ack": "string",
      "control": 0,
      "assets": [
        {
          "id": 0,
          "value": "string"
        }
      ],
      "vulnerabilities": [
        {
          "id": 0,
          "asset": 0,
          "asset_value": "string",
          "title": "string",
          "severity": 0
        }
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedFeedList

alerts_ack

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/alerts/{id}/ack", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/alerts/{id}/ack

Ack Feed

:return 404 - Alert doesn't exist

:return 200 - Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
404 Not Found none BasicResponseWithMessage

alerts_ack_all

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/alerts/ack \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/alerts/ack HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/alerts/ack',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/alerts/ack',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/alerts/ack', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/alerts/ack', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/alerts/ack");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/alerts/ack", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/alerts/ack

Ack all alerts.

:return 200: Success

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage

asm

asm_cert_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/cert/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/cert/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/cert/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/cert/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/cert/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/cert/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/cert/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/cert/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/cert/

Parameters

Name In Type Required Description
asset query integer false Asset
created_at query string(date-time) false none
host query string false none
id query integer false none
is_expired query boolean false none
is_mismatched query boolean false none
is_selfsigned query boolean false none
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.
port query integer false none
search query string false Search
serial_number query string false none
sorted_by query array[string] false Ordering
updated_at query string(date-time) false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -host
sorted_by -id
sorted_by -port
sorted_by -serial_number
sorted_by -updated_at
sorted_by created_at
sorted_by host
sorted_by id
sorted_by port
sorted_by serial_number
sorted_by updated_at

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "port": -2147483648,
      "host_id": 0,
      "host": "string",
      "serial_number": "string",
      "data_text": "string",
      "data_pem": "string",
      "data_parsed": null,
      "is_expired": true,
      "is_mismatched": true,
      "is_selfsigned": true,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedCertificateList

asm_cert_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/cert/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/cert/{id}/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "port": -2147483648,
  "host_id": 0,
  "host": "string",
  "serial_number": "string",
  "data_text": "string",
  "data_pem": "string",
  "data_parsed": null,
  "is_expired": true,
  "is_mismatched": true,
  "is_selfsigned": true,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Certificate

asm_domain_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/domain/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/domain/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/domain/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/domain/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/domain/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/domain/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/domain/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/domain/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/domain/

API endpoint that allows Domains to be viewed or edited.

Parameters

Name In Type Required Description
asset query integer false none
id query integer false none
limit query integer false Number of results to return per page.
name query string false none
name__icontains query string false none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -id
sorted_by -name
sorted_by -updated_at
sorted_by created_at
sorted_by id
sorted_by name
sorted_by updated_at

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "name": "string",
      "asset": 0,
      "parent_domain": {
        "id": 0,
        "asset_id": 0,
        "name": "string"
      },
      "subdomains": [
        {
          "id": 0,
          "asset_id": 0,
          "name": "string"
        }
      ],
      "whois": {
        "id": 0,
        "text": "string",
        "registrar": "string",
        "registrar_id": "string",
        "registrar_url": "string",
        "registrar_status": null,
        "registrant_name": "string",
        "registrant_country": "string",
        "registrant_state_province": "string",
        "name_servers": null,
        "created_at": "2019-08-24T14:15:22Z",
        "updated_at": "2019-08-24T14:15:22Z",
        "expiration_date": null
      },
      "is_registered": true,
      "dnsrecords": [
        null
      ],
      "ip_addresses": [
        {
          "id": 0,
          "address": "string",
          "asset_id": 0,
          "ports": "string"
        }
      ],
      "popularity_ranks": [
        null
      ],
      "categories": [
        null
      ],
      "search_engines_results": [
        null
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedDomainList

asm_domain_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/domain/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/domain/{id}/

API endpoint that allows Domains to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "asset": 0,
  "parent_domain": {
    "id": 0,
    "asset_id": 0,
    "name": "string"
  },
  "subdomains": [
    {
      "id": 0,
      "asset_id": 0,
      "name": "string"
    }
  ],
  "whois": {
    "id": 0,
    "text": "string",
    "registrar": "string",
    "registrar_id": "string",
    "registrar_url": "string",
    "registrar_status": null,
    "registrant_name": "string",
    "registrant_country": "string",
    "registrant_state_province": "string",
    "name_servers": null,
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z",
    "expiration_date": null
  },
  "is_registered": true,
  "dnsrecords": [
    null
  ],
  "ip_addresses": [
    {
      "id": 0,
      "address": "string",
      "asset_id": 0,
      "ports": "string"
    }
  ],
  "popularity_ranks": [
    null
  ],
  "categories": [
    null
  ],
  "search_engines_results": [
    null
  ],
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Domain

asm_ip_address_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/ip-address/

Parameters

Name In Type Required Description
address query string false none
address__icontains query string false none
asset query integer false none
id query integer false none
limit query integer false Number of results to return per page.
liveness query string false * unknown - Unknown
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering
type query string false * ipv4 - ipv4

Detailed descriptions

liveness: * unknown - Unknown * up - Up * down - Down

sorted_by: Ordering

type: * ipv4 - ipv4 * ipv6 - ipv6

Enumerated Values

Parameter Value
liveness down
liveness unknown
liveness up
sorted_by -address
sorted_by -created_at
sorted_by -id
sorted_by -type
sorted_by -updated_at
sorted_by address
sorted_by created_at
sorted_by id
sorted_by type
sorted_by updated_at
type ipv4
type ipv6

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "asset": 0,
      "address": "string",
      "type": "ipv4",
      "liveness": "unknown",
      "in_blacklist": true,
      "general_infos": {
        "id": 0,
        "asn_cidr": "string",
        "asn_number": "string",
        "asn_registry": "string",
        "asn_description": "string",
        "asn_country_code": "string"
      },
      "domains": "string",
      "blacklists": [
        null
      ],
      "ports": [
        {
          "id": 0,
          "number": -2147483648,
          "protocol": "tcp",
          "is_ssl": true,
          "service_name": "string",
          "state": "open",
          "banners": [
            {
              "id": 0,
              "host": "string",
              "port": 0,
              "text": "string"
            }
          ]
        }
      ],
      "search_engines_results": [
        null
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedIPAddressList

asm_ip_address_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/ip-address/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/ip-address/{id}/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "asset": 0,
  "address": "string",
  "type": "ipv4",
  "liveness": "unknown",
  "in_blacklist": true,
  "general_infos": {
    "id": 0,
    "asn_cidr": "string",
    "asn_number": "string",
    "asn_registry": "string",
    "asn_description": "string",
    "asn_country_code": "string"
  },
  "domains": "string",
  "blacklists": [
    null
  ],
  "ports": [
    {
      "id": 0,
      "number": -2147483648,
      "protocol": "tcp",
      "is_ssl": true,
      "service_name": "string",
      "state": "open",
      "banners": [
        {
          "id": 0,
          "host": "string",
          "port": 0,
          "text": "string"
        }
      ]
    }
  ],
  "search_engines_results": [
    null
  ],
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none IPAddress

asm_port_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/port/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/port/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/port/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/port/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/port/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/port/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/port/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/port/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/port/

Parameters

Name In Type Required Description
created_at query string(date-time) false none
id query integer false none
ip_address query integer false none
is_ssl query boolean false none
limit query integer false Number of results to return per page.
number query integer false none
page query integer false A page number within the paginated result set.
protocol query string false * tcp - TCP
search query string false none
service_name query string false none
sorted_by query array[string] false Ordering
state query string false * open - Open
updated_at query string(date-time) false none
web_server query number false Web server

Detailed descriptions

protocol: * tcp - TCP * udp - UDP

sorted_by: Ordering

state: * open - Open * filtered - Filtered * closed - Closed * unknown - Unknown

Enumerated Values

Parameter Value
protocol tcp
protocol udp
sorted_by -created_at
sorted_by -id
sorted_by -number
sorted_by -protocol
sorted_by -service_name
sorted_by -state
sorted_by -updated_at
sorted_by created_at
sorted_by id
sorted_by number
sorted_by protocol
sorted_by service_name
sorted_by state
sorted_by updated_at
state closed
state filtered
state open
state unknown

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "ip_address": 0,
      "number": -2147483648,
      "protocol": "tcp",
      "is_ssl": true,
      "service_name": "string",
      "state": "open",
      "certificates": [
        {
          "id": 0,
          "port": 0,
          "host": "string",
          "serial_number": "string",
          "data_text": "string"
        }
      ],
      "banners": [
        {
          "id": 0,
          "host": "string",
          "port": 0,
          "text": "string"
        }
      ],
      "webservers": [
        {
          "id": 0,
          "url": "string",
          "server": "string",
          "title": "string"
        }
      ]
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedPortList

asm_port_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/port/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/port/{id}/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "ip_address": 0,
  "number": -2147483648,
  "protocol": "tcp",
  "is_ssl": true,
  "service_name": "string",
  "state": "open",
  "certificates": [
    {
      "id": 0,
      "port": 0,
      "host": "string",
      "serial_number": "string",
      "data_text": "string"
    }
  ],
  "banners": [
    {
      "id": 0,
      "host": "string",
      "port": 0,
      "text": "string"
    }
  ],
  "webservers": [
    {
      "id": 0,
      "url": "string",
      "server": "string",
      "title": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none Port

asm_subdomain_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/subdomain/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/subdomain/

API endpoint that allows Subdomains to be viewed or edited.

Parameters

Name In Type Required Description
asset query integer false none
id query integer false none
limit query integer false Number of results to return per page.
name query string false none
name__icontains query string false none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -id
sorted_by -name
sorted_by -updated_at
sorted_by created_at
sorted_by id
sorted_by name
sorted_by updated_at

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "name": "string",
      "asset": 0,
      "parent_domain": {
        "id": 0,
        "asset_id": 0,
        "name": "string"
      },
      "subdomains": [
        {
          "id": 0,
          "asset_id": 0,
          "name": "string"
        }
      ],
      "whois": {
        "id": 0,
        "text": "string",
        "registrar": "string",
        "registrar_id": "string",
        "registrar_url": "string",
        "registrar_status": null,
        "registrant_name": "string",
        "registrant_country": "string",
        "registrant_state_province": "string",
        "name_servers": null,
        "created_at": "2019-08-24T14:15:22Z",
        "updated_at": "2019-08-24T14:15:22Z",
        "expiration_date": null
      },
      "is_registered": true,
      "dnsrecords": [
        null
      ],
      "ip_addresses": [
        {
          "id": 0,
          "address": "string",
          "asset_id": 0,
          "ports": "string"
        }
      ],
      "popularity_ranks": [
        null
      ],
      "categories": [
        null
      ],
      "search_engines_results": [
        null
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedDomainList

asm_web_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/web/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/web/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/web/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/web/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/web/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/web/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/web/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/web/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/web/

Parameters

Name In Type Required Description
asset query integer false Asset
created_at query string(date-time) false none
host query string false none
id query integer false none
jarm query string false none
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.
search query string false none
server query string false none
sorted_by query array[string] false Ordering
status_code query string false none
title query string false none
updated_at query string(date-time) false none
url query string false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -host
sorted_by -id
sorted_by -server
sorted_by -status_code
sorted_by -title
sorted_by -updated_at
sorted_by -url
sorted_by created_at
sorted_by host
sorted_by id
sorted_by server
sorted_by status_code
sorted_by title
sorted_by updated_at
sorted_by url

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "ports": [
        {
          "id": 0,
          "number": -2147483648,
          "protocol": "tcp",
          "is_ssl": true,
          "service_name": "string",
          "state": "open",
          "banners": [
            {
              "id": 0,
              "host": "string",
              "port": 0,
              "text": "string"
            }
          ]
        }
      ],
      "host": "string",
      "url": "string",
      "server": "string",
      "path": "string",
      "title": "string",
      "asset": 0,
      "response_time": "string",
      "status_code": "string",
      "content_length": "string",
      "content_type": "string",
      "jarm": "string",
      "favicon_hash": "string",
      "technologies": [
        null
      ],
      "ips": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedWebServerList

asm_web_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/asm/web/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/asm/web/{id}/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "ports": [
    {
      "id": 0,
      "number": -2147483648,
      "protocol": "tcp",
      "is_ssl": true,
      "service_name": "string",
      "state": "open",
      "banners": [
        {
          "id": 0,
          "host": "string",
          "port": 0,
          "text": "string"
        }
      ]
    }
  ],
  "host": "string",
  "url": "string",
  "server": "string",
  "path": "string",
  "title": "string",
  "asset": 0,
  "response_time": "string",
  "status_code": "string",
  "content_length": "string",
  "content_type": "string",
  "jarm": "string",
  "favicon_hash": "string",
  "technologies": [
    null
  ],
  "ips": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none WebServer

assets

assets_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
accessible_by_users query array[number] false Multiple values may be separated by commas.
after query string(date-time) false none
asset_owners query string false none
asset_tags query string false none
before query string(date-time) false none
campaign query string false none
cdn_provider query boolean false Behind a CDN provider or not.
cloud_provider query boolean false Behind a Cloud provider or not.
created_by query string false none
criticality query integer false * 1 - Low
cve query integer false none
description__icontains query string false none
group query string false none
group_not query string false none
groups_or query string false none
groups_value query string false none
is_monitored query boolean false none
limit query integer false Number of results to return per page.
liveness query string false none
no_groups query boolean false No Asset Groups
no_tags query boolean false No Tags
not_asset_owner query string false none
org_id query string false none
page query integer false A page number within the paginated result set.
ports_available query boolean false none
saas_provider query boolean false Behind a SAAS provider or not.
score query string false none
search query string false none
sorted_by query array[string] false Ordering
suborg_id query string false none
suborg_not query string false none
tags query integer false none
tags_value query string false none
tags_value_union query string false none
technology query integer false none
type query string false none
value query string false none
value__icontains query string false none
waf_provider query boolean false Behind a WAF provider or not.

Detailed descriptions

criticality: * 1 - Low * 2 - Medium * 3 - High

sorted_by: Ordering

Enumerated Values

Parameter Value
criticality 1
criticality 2
criticality 3
sorted_by -activevulns
sorted_by -asset_owners
sorted_by -asset_tags
sorted_by -created_at
sorted_by -criticality
sorted_by -description
sorted_by -groups
sorted_by -id
sorted_by -is_monitored
sorted_by -ports
sorted_by -score
sorted_by -type
sorted_by -value
sorted_by activevulns
sorted_by asset_owners
sorted_by asset_tags
sorted_by created_at
sorted_by criticality
sorted_by description
sorted_by groups
sorted_by id
sorted_by is_monitored
sorted_by ports
sorted_by score
sorted_by type
sorted_by value

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "value": "string",
      "criticality": 1,
      "type": "ip",
      "description": "string",
      "exposure": "unknown",
      "is_active": true,
      "score": -2147483648,
      "is_monitored": true,
      "created_by": "string",
      "activevulns": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "asset_tags": "string",
      "organization": 0,
      "last_checked_at": "string",
      "score_level": "string",
      "asset_owners": "string",
      "liveness": "unknown"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedAssetInListList

assets_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "organization": 0,
  "value": "string",
  "description": "string",
  "criticality": 1,
  "is_monitored": true,
  "exposure": "unknown"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/

Create a new Asset :param Criticality: 1 - Low / 2 - Medium / 3 - High

:return 400: You need to specify an org_id

:return 400: Invalid asset value

:return 400: Invalid data

:return 403: User doesn't have access to this organization

:return 404: Organization doesn't exist

:return 201: Success

Body parameter

{
  "organization": 0,
  "value": "string",
  "description": "string",
  "criticality": 1,
  "is_monitored": true,
  "exposure": "unknown"
}
organization: 0
value: string
description: string
criticality: 1
is_monitored: true
exposure: unknown

Parameters

Name In Type Required Description
body body create_asset true none

Example responses

201 Response

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Responses

Status Meaning Description Schema
201 Created none Asset
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_bulk_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "assets_id": [
    null
  ],
  "criticality": 1,
  "is_monitored": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/assets/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/assets/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/assets/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/assets/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/assets/

Update several assets

:param Criticality: 1 - Low / 2 - Medium / 3 - High

:return 400: assets_id is required

:return 400: assets_id must be a list of integers

:return 400: No assets with this or these IDs

:return 400: Invalid data

:return 200: Success

Body parameter

{
  "assets_id": [
    null
  ],
  "criticality": 1,
  "is_monitored": true
}
assets_id:
  - null
criticality: 1
is_monitored: true

Parameters

Name In Type Required Description
body body Patchedserializer_assets_bulk_partial_update false none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage

assets_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/{id}/

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Responses

Status Meaning Description Schema
200 OK none Asset

assets_create_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/{id}/

API endpoint that allows Assets to be viewed or edited.

Body parameter

{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}
value: string
criticality: 1
type: ip
description: string
exposure: unknown
is_monitored: true
tags:
  - 0
owners:
  - 0
organization: 0
suborganizations:
  - 0

Parameters

Name In Type Required Description
id path integer true none
body body Asset true none

Example responses

200 Response

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Responses

Status Meaning Description Schema
200 OK none Asset

assets_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/assets/{id}/

Update one specific asset

:param Criticality: 1 - Low / 2 - Medium / 3 - High

:return 404: Asset doesn't exist

:return 400: Invalid data

:return 200: Success

Body parameter

{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}
value: string
criticality: 1
type: ip
description: string
exposure: unknown
is_monitored: true
tags:
  - 0
owners:
  - 0
organization: 0
suborganizations:
  - 0

Parameters

Name In Type Required Description
id path integer true none
body body PatchedAsset false none

Example responses

200 Response

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Responses

Status Meaning Description Schema
200 OK none Asset
400 Bad Request none Inline
404 Not Found none Inline

Response Schema

Status Code 400

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_delete

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/{id}/

Delete Asset with this id

:return 404: Asset not found

:return 204: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

204 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
204 No Content none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_add_owners

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "users_id": [
    null
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/{id}/owners

API endpoint that allows Assets to be viewed or edited.

Body parameter

{
  "users_id": [
    null
  ]
}
users_id:
  - null

Parameters

Name In Type Required Description
id path integer true none
body body add_owners true none

Example responses

200 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
200 OK none Success
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_remove_owners

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/{id}/owners

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
200 OK none Success
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_refresh_score

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/refresh", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/{id}/refresh

Refresh an asset score.

:return: 404: Asset not found

:return: 400: Error

:return: 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
200 OK none Success
400 Bad Request none BasicResponse
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

asset_remove_tags

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/{id}/tags

Remove tags from an assets

:return: 404: Asset doesn't exist

:return: 204: Success :return: 204: Partial

Body parameter

{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}
value: string
criticality: 1
type: ip
description: string
exposure: unknown
is_monitored: true
tags:
  - 0
owners:
  - 0
organization: 0
suborganizations:
  - 0

Parameters

Name In Type Required Description
id path integer true none
body body Asset true none

Example responses

204 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
204 No Content none BasicResponse
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_remove_tag

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/{pk_tag}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/{id}/tags/{pk_tag}/

Remove an AssetTag from an asset.

:return: 404: Asset or Asset Tag doesn't exist

:return: 204: Success

Parameters

Name In Type Required Description
id path integer true none
pk_tag path integer true none

Example responses

204 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
204 No Content none BasicResponse
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_add_tag

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string",
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/{id}/tags/add", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/{id}/tags/add

Add an Asset Tag to an asset.

:return: 404: Not found

:return: 400: Bad tag value

:return: 400: Bad tag organization value

:return: 403: Access denied

:return: 201: Success

Body parameter

{
  "value": "string",
  "organization": 0
}
value: string
organization: 0

Parameters

Name In Type Required Description
id path integer true none
body body AssetTag true none

Example responses

201 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
201 Created none Success
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_by_control_impacted

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-impacted", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/by-control-impacted

Get impacted asset for a control.

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_by_control_warning

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/by-control-warning", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/by-control-warning

Get warning asset for a control.

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_by_type

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/by-types \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/by-types HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/by-types',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/by-types',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/by-types', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/by-types', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/by-types");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/by-types", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/by-types

Get type for all assets.

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_by_criticality

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/criticalities", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/criticalities

Get criticality for all assets.

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_bulk_delete

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/delete \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/delete HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/delete',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/delete',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/delete', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/delete', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/delete");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/delete", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/delete

Delete Several Assets from list

:param assets_id: List with all the IDs to delete

:return 400: assets_id field is required

:return 400: assets_id must be a list of integers

:return 400: No assets with this or these IDs

:return 204: Success

Example responses

204 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
204 No Content none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage

assets_export_csv

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/export/csv

Export assets as CSV.

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline
400 Bad Request none BasicResponse
403 Forbidden none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_export_csv_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/export/csv

Export assets as CSV.

Body parameter

{
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_monitored": true,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "organization": 0,
  "suborganizations": [
    0
  ]
}
value: string
criticality: 1
type: ip
description: string
exposure: unknown
is_monitored: true
tags:
  - 0
owners:
  - 0
organization: 0
suborganizations:
  - 0

Parameters

Name In Type Required Description
body body Asset true none

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline
400 Bad Request none BasicResponse
403 Forbidden none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_export_json_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/export/json \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/export/json HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/export/json',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/export/json',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/export/json', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/export/json', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/export/json");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/export/json", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/export/json

API endpoint that allows Assets to be viewed or edited.

Example responses

200 Response

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Responses

Status Meaning Description Schema
200 OK none Asset

assets_group_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/group/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/group/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/group/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/group/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/group/

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
accessible_by_users query array[number] false Multiple values may be separated by commas.
asset_group_owners query string false none
asset_group_tags query string false none
criticality query integer false * 1 - Low
description__icontains query string false none
exclude_asset query string false none
is_dynamic query boolean false none
limit query integer false Number of results to return per page.
not_asset_group_owner query string false none
org_id query string false none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering
suborg_id query string false none
suborg_not query string false none
tags query integer false none
tags_value query string false none
tags_value_union query string false none
title query string false none
title__icontains query string false none

Detailed descriptions

criticality: * 1 - Low * 2 - Medium * 3 - High

sorted_by: Ordering

Enumerated Values

Parameter Value
criticality 1
criticality 2
criticality 3
sorted_by -asset_group_owners
sorted_by -asset_group_tags
sorted_by -assets
sorted_by -created_at
sorted_by -criticality
sorted_by -description
sorted_by -id
sorted_by -is_dynamic
sorted_by -title
sorted_by -updated_at
sorted_by asset_group_owners
sorted_by asset_group_tags
sorted_by assets
sorted_by created_at
sorted_by criticality
sorted_by description
sorted_by id
sorted_by is_dynamic
sorted_by title
sorted_by updated_at

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "assets": [
        null
      ],
      "organization": 0,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "asset_group_tags": "string",
      "is_dynamic": true,
      "criticality": 1
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedAssetGroupLiteList

assets_group_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/group/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/group/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/group/

API endpoint that allows Assets to be viewed or edited.

Body parameter

{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}
title: string
description: string
organization: 0
tags:
  - 0
owners:
  - 0
suborganizations:
  - 0
is_dynamic: true
criticality: 1

Parameters

Name In Type Required Description
body body AssetGroup true none

Example responses

201 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "assets": "string",
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

Responses

Status Meaning Description Schema
201 Created none AssetGroup

assets_group_bulk_delete

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/group/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/group/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/group/

API endpoint that allows Assets to be viewed or edited.

Example responses

204 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
204 No Content none BasicResponse
404 Not Found none BasicResponseWithMessage

assets_group_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/group/{id}/

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "assets": "string",
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

Responses

Status Meaning Description Schema
200 OK none AssetGroup

assets_group_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/assets/group/{id}/

API endpoint that allows Assets to be viewed or edited.

Body parameter

{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}
title: string
description: string
organization: 0
tags:
  - 0
owners:
  - 0
suborganizations:
  - 0
is_dynamic: true
criticality: 1

Parameters

Name In Type Required Description
id path integer true none
body body PatchedAssetGroup false none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "assets": "string",
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

Responses

Status Meaning Description Schema
200 OK none AssetGroup

assets_group_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/group/{id}/

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

assets_group_add_assets

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "assets_id": [
    null
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/group/{id}/assets

Add several assets to an asset group

:return: 404: Asset Group not found

:return: 400 Invalid data

Body parameter

{
  "assets_id": [
    null
  ]
}
assets_id:
  - null

Parameters

Name In Type Required Description
id path integer true none
body body assets_group_add_assets true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_group_remove_assets

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/assets", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/group/{id}/assets

Remove several assets from an AssetGroup

:param assets_id: List with all the IDs to remove

:return 404: AssetGroup Not found

:return 400: Invalid data

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_group_filters_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/group/{id}/filters

Add filters to a dynamic asset group

Body parameter

{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}
title: string
description: string
organization: 0
tags:
  - 0
owners:
  - 0
suborganizations:
  - 0
is_dynamic: true
criticality: 1

Parameters

Name In Type Required Description
id path integer true none
body body AssetGroup true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "assets": "string",
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

Responses

Status Meaning Description Schema
200 OK none AssetGroup

assets_group_filters_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/filters", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/group/{id}/filters

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

assets_group_owners_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/group/{id}/owners

API endpoint that allows Assets to be viewed or edited.

Body parameter

{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}
title: string
description: string
organization: 0
tags:
  - 0
owners:
  - 0
suborganizations:
  - 0
is_dynamic: true
criticality: 1

Parameters

Name In Type Required Description
id path integer true none
body body AssetGroup true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "assets": "string",
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

Responses

Status Meaning Description Schema
200 OK none AssetGroup

assets_group_owners_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/group/{id}/owners

API endpoint that allows Assets to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

assets_group_add_assets_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/group/{id}/tag

Add an AssetTag to an AssetGroup.

:return 404: AssetGroup Not found

:return 400: Invalid Data

:return 201: Success

Body parameter

{
  "value": "string"
}
value: string

Parameters

Name In Type Required Description
id path integer true none
body body assets_group_add_tag true none

Example responses

200 Response

{
  "status": "string",
  "data": {
    "id": 0,
    "value": "string",
    "organization": 0
  }
}

Responses

Status Meaning Description Schema
200 OK none response_assets_group_add_tag
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_group_remove_tag

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag} \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag} HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/{id}/tag/{pk_tag}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/group/{id}/tag/{pk_tag}

Remove an AssetTag from an asset.

:return 404: AssetGroup Not Found / Asset Not Found

:return 400: Tag not in AssetGroup

:return 204: Success

Parameters

Name In Type Required Description
id path integer true none
pk_tag path integer true none

Example responses

204 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
204 No Content none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_group_export_csv_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/group/export/csv

Export asset groups as CSV.

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "assets": "string",
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

Responses

Status Meaning Description Schema
200 OK none AssetGroup

assets_group_export_csv_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/group/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/group/export/csv

Export asset groups as CSV.

Body parameter

{
  "title": "string",
  "description": "string",
  "organization": 0,
  "tags": [
    0
  ],
  "owners": [
    0
  ],
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "criticality": 1
}
title: string
description: string
organization: 0
tags:
  - 0
owners:
  - 0
suborganizations:
  - 0
is_dynamic: true
criticality: 1

Parameters

Name In Type Required Description
body body AssetGroup true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "assets": "string",
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

Responses

Status Meaning Description Schema
200 OK none AssetGroup

assets_import_assets_from_csv

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/import \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/import HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "organization": 0,
  "suborganization": "string",
  "file": "http://example.com"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/import',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/import',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/import', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/import', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/import");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/import", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/import

API endpoint that allows Assets to be viewed or edited.

Body parameter

{
  "organization": 0,
  "suborganization": "string",
  "file": "http://example.com"
}
organization: 0
suborganization: string
file: http://example.com

Parameters

Name In Type Required Description
body body ImportCSVAsset true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse

assets_last_discovered

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/last-discovered", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/last-discovered

Get assets last discovered (for KPI).

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage

assets_get_metrics

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/metrics \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/metrics HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/metrics',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/metrics',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/metrics', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/metrics', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/metrics");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/metrics", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/metrics

Get assets monitored/unmonitored (for KPI).

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage

get_port_informations

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/ports \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/ports HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "ids": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/ports',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/ports',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/ports', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/ports', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/ports");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/ports", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/ports

API endpoint that allows Assets to be viewed or edited.

Body parameter

{
  "ids": [
    0
  ]
}
ids:
  - 0

Parameters

Name In Type Required Description
body body IDsList true none

Example responses

200 Response

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Responses

Status Meaning Description Schema
200 OK none Asset

assets_tags_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/tags/

API endpoint that allows AssetTags to be viewed or edited.

Parameters

Name In Type Required Description
exclude_tag_asset query string false none
exclude_tag_asset_group query string false none
id query integer false none
is_asset_group_tag query boolean false none
is_asset_tag query boolean false none
limit query integer false Number of results to return per page.
org_id query string false none
organization query integer false none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering
value query string false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -id
sorted_by -organization
sorted_by -updated_at
sorted_by -value
sorted_by created_at
sorted_by id
sorted_by organization
sorted_by updated_at
sorted_by value

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "value": "string",
      "organization": 0
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedAssetTagList

assets_tags_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string",
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/tags/

API endpoint that allows AssetTags to be viewed or edited.

Body parameter

{
  "value": "string",
  "organization": 0
}
value: string
organization: 0

Parameters

Name In Type Required Description
body body AssetTag true none

Example responses

201 Response

{
  "id": 0,
  "value": "string",
  "organization": 0
}

Responses

Status Meaning Description Schema
201 Created none AssetTag

assets_tags_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/tags/{id}/

API endpoint that allows AssetTags to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "value": "string",
  "organization": 0
}

Responses

Status Meaning Description Schema
200 OK none AssetTag

add_tag_to_assets

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "organization": 0,
  "value": "string",
  "description": "string",
  "criticality": 1,
  "is_monitored": true,
  "exposure": "unknown"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/tags/{id}/

Add an Asset Tag to assets.

:return: 404: Not found

:return: 400: Bad assets_id value

:return: 400: Bad tag organization value

:return: 201: Success

Body parameter

{
  "organization": 0,
  "value": "string",
  "description": "string",
  "criticality": 1,
  "is_monitored": true,
  "exposure": "unknown"
}
organization: 0
value: string
description: string
criticality: 1
is_monitored: true
exposure: unknown

Parameters

Name In Type Required Description
id path integer true none
body body create_asset true none

Example responses

201 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
201 Created none Success
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

assets_tags_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "value": "string",
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/assets/tags/{id}/

API endpoint that allows AssetTags to be viewed or edited.

Body parameter

{
  "value": "string",
  "organization": 0
}
value: string
organization: 0

Parameters

Name In Type Required Description
id path integer true none
body body PatchedAssetTag false none

Example responses

200 Response

{
  "id": 0,
  "value": "string",
  "organization": 0
}

Responses

Status Meaning Description Schema
200 OK none AssetTag

assets_tags_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/tags/{id}/

API endpoint that allows AssetTags to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

assets_tags_policies_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/tags/policies/

API endpoint that allows AutoTag Policy to be viewed or edited.

Parameters

Name In Type Required Description
after query string(date-time) false none
before query string(date-time) false none
is_enabled query boolean false none
limit query integer false Number of results to return per page.
org_id query string false none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering
tag_value query string false none
title query string false none
title__icontains query string false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -id
sorted_by -is_enabled
sorted_by -tag_value
sorted_by -title
sorted_by -updated_at
sorted_by created_at
sorted_by id
sorted_by is_enabled
sorted_by tag_value
sorted_by title
sorted_by updated_at

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "is_enabled": true,
      "tag_id": 0,
      "tag_value": "string",
      "filters": "string",
      "organization": 0,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedAutoTagPolicyList

assets_tags_policies_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "is_enabled": true,
  "tag": "string",
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/tags/policies/

API endpoint that allows AutoTag Policy to be viewed or edited.

Body parameter

{
  "title": "string",
  "is_enabled": true,
  "tag": "string",
  "organization": 0
}
title: string
is_enabled: true
tag: string
organization: 0

Parameters

Name In Type Required Description
body body AutoTagPolicy true none

Example responses

201 Response

{
  "id": 0,
  "title": "string",
  "is_enabled": true,
  "tag_id": 0,
  "tag_value": "string",
  "filters": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
201 Created none AutoTagPolicy

assets_tags_policies_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/assets/tags/policies/{id}/

API endpoint that allows AutoTag Policy to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "is_enabled": true,
  "tag_id": 0,
  "tag_value": "string",
  "filters": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none AutoTagPolicy

assets_tags_policies_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "is_enabled": true,
  "tag": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/assets/tags/policies/{id}/

API endpoint that allows AutoTag Policy to be viewed or edited.

Body parameter

{
  "title": "string",
  "is_enabled": true,
  "tag": "string"
}
title: string
is_enabled: true
tag: string

Parameters

Name In Type Required Description
id path integer true none
body body PatchedUpdateAutoTagPolicy false none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "is_enabled": true,
  "tag_id": 0,
  "tag_value": "string",
  "filters": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none UpdateAutoTagPolicy

assets_tags_policies_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/assets/tags/policies/{id}/

API endpoint that allows AutoTag Policy to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

add_filters

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "is_enabled": true,
  "tag": "string",
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/tags/policies/{id}/filters/

API endpoint that allows AutoTag Policy to be viewed or edited.

Body parameter

{
  "title": "string",
  "is_enabled": true,
  "tag": "string",
  "organization": 0
}
title: string
is_enabled: true
tag: string
organization: 0

Parameters

Name In Type Required Description
id path integer true none
body body AutoTagPolicy true none

Example responses

201 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
201 Created none Success
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

remove_filters

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "ids": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/{id}/filters/remove/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/tags/policies/{id}/filters/remove/

API endpoint that allows AutoTag Policy to be viewed or edited.

Body parameter

{
  "ids": [
    0
  ]
}
ids:
  - 0

Parameters

Name In Type Required Description
id path integer true none
body body IDsList true none

Example responses

201 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
201 Created none Success
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

bulk_delete

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "ids": [
    "string"
  ],
  "remove_tag": false,
  "remove_tag_all": false
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/assets/tags/policies/delete/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/assets/tags/policies/delete/

API endpoint that allows AutoTag Policy to be viewed or edited.

Body parameter

{
  "ids": [
    "string"
  ],
  "remove_tag": false,
  "remove_tag_all": false
}
ids:
  - string
remove_tag: false
remove_tag_all: false

Parameters

Name In Type Required Description
body body AutoTagPolicyBulkDelete true none

Example responses

201 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
201 Created none Success
400 Bad Request none BasicResponseWithMessage

controls

controls_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/controls/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/controls/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/controls/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/controls/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/controls/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/controls/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/controls/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/controls/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/controls/

API endpoint that allows Control to be viewed or edited.

Parameters

Name In Type Required Description
cve_identifiers query string false none
cvss_vector query string false none
description query string false none
finished_at query string(date-time) false none
finished_at__gte query string(date-time) false none
finished_at__lte query string(date-time) false none
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.
products query string false none
result query integer false Result
search query string false Search in title, description, status and CVE identifiers.
severity query string false none
sorted_by query array[string] false Ordering
started_at query string(date-time) false none
started_at__gte query string(date-time) false none
started_at__lte query string(date-time) false none
status query integer false * 0 - In progress
title query string false none
vendor query string false none

Detailed descriptions

result: Result

sorted_by: Ordering

status: * 0 - In progress * 1 - Finished

Enumerated Values

Parameter Value
result 0
result 1
result 2
result 3
sorted_by -created_at
sorted_by -cve_identifiers
sorted_by -cvss_vector
sorted_by -finished_at
sorted_by -id
sorted_by -products
sorted_by -severity
sorted_by -started_at
sorted_by -status
sorted_by -title
sorted_by -updated_at
sorted_by -vendor
sorted_by created_at
sorted_by cve_identifiers
sorted_by cvss_vector
sorted_by finished_at
sorted_by id
sorted_by products
sorted_by severity
sorted_by started_at
sorted_by status
sorted_by title
sorted_by updated_at
sorted_by vendor
status 0
status 1

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "status": "string",
      "result": "string",
      "cve_identifiers": [
        "string"
      ],
      "cvss_vector": "string",
      "cvss_score": "string",
      "severity": 0,
      "description": "string",
      "references": [
        "http://example.com"
      ],
      "vendor": "string",
      "products": [
        "string"
      ],
      "started_at": "2019-08-24T14:15:22Z",
      "finished_at": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedControlLiteList

controls_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/controls/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/controls/{id}/

API endpoint that allows Control to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "status": "string",
  "result": "string",
  "cve_identifiers": [
    "string"
  ],
  "cvss_vector": "string",
  "cvss_score": "string",
  "severity": 0,
  "description": "string",
  "references": [
    "http://example.com"
  ],
  "vendor": "string",
  "products": [
    "string"
  ],
  "assets_impacted": "string",
  "assets_warning": "string",
  "vulnerabilities": "string",
  "started_at": "2019-08-24T14:15:22Z",
  "finished_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Control

cybelangel

cybelangel_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/cybelangel/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/cybelangel/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/cybelangel/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/cybelangel/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/cybelangel/

Parameters

Name In Type Required Description
org_id query integer false Filter by organization id
page query integer false A page number within the paginated result set.

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "org_id": 0,
      "name": "string",
      "client_id": "string",
      "periodic_import_enabled": false,
      "is_token_expired": true
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedCybelangelList

cybelangel_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/cybelangel/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/cybelangel/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "client_secret": "string",
  "periodic_import_enabled": false
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/cybelangel/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/cybelangel/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/cybelangel/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/cybelangel/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/cybelangel/

Body parameter

{
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "client_secret": "string",
  "periodic_import_enabled": false
}
org_id: 0
name: string
client_id: string
client_secret: string
periodic_import_enabled: false

Parameters

Name In Type Required Description
body body Cybelangel true none

Example responses

201 Response

{
  "id": 0,
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "periodic_import_enabled": false,
  "is_token_expired": true
}

Responses

Status Meaning Description Schema
201 Created none Cybelangel

cybelangel_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/cybelangel/{id}/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "periodic_import_enabled": false,
  "is_token_expired": true
}

Responses

Status Meaning Description Schema
200 OK none Cybelangel

cybelangel_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "client_secret": "string",
  "periodic_import_enabled": false
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/cybelangel/{id}/

Body parameter

{
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "client_secret": "string",
  "periodic_import_enabled": false
}
org_id: 0
name: string
client_id: string
client_secret: string
periodic_import_enabled: false

Parameters

Name In Type Required Description
id path integer true none
body body PatchedCybelangel false none

Example responses

200 Response

{
  "id": 0,
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "periodic_import_enabled": false,
  "is_token_expired": true
}

Responses

Status Meaning Description Schema
200 OK none Cybelangel

cybelangel_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/cybelangel/{id}/

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

cybelangel_check_connection

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/connection", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/cybelangel/{id}/connection

Check connection by retrieving a new access token for Cybelangel with Cybelangel API credentials client_id and client_secret.

:return 404: The Cybelangel configuration does not exist

:return 200: Success

:return 400: Invalid Credentials

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

cybelangel_import_reports

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/cybelangel/{id}/import", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/cybelangel/{id}/import

Import all Cybelangel reports on Patrowl Dashboard

:return 401: An error occurred while retrieving the access token for CybelAngel API. Please try again later

:return 400: An error occurred while retrieving reports from CybelAngel. Please try again later

:return 400: An import from CybelAngel is already in progress

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
400 Bad Request none Inline
401 Unauthorized none Inline
404 Not Found none Inline

Response Schema

Status Code 400

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 401

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

greyboxes

greyboxes_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/greyboxes/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/greyboxes/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/greyboxes/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/greyboxes/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/greyboxes/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/greyboxes/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/greyboxes/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/greyboxes/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/greyboxes/

API endpoint that allows Greybox Requests to be viewed or edited.

Parameters

Name In Type Required Description
comments query string false none
comments__icontains query string false none
contact_info query string false none
contact_info__icontains query string false none
in_scope query string false none
in_scope__icontains query string false none
limit query integer false Number of results to return per page.
org_id query integer false none
page query integer false A page number within the paginated result set.
requested_by query string false none
search query string false none
sorted_by query array[string] false Ordering
user_friendly_id query string false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -complexity
sorted_by -created_at
sorted_by -finished_at
sorted_by -id
sorted_by -organization_name
sorted_by -requested_by
sorted_by -started_at
sorted_by -user_friendly_id
sorted_by complexity
sorted_by created_at
sorted_by finished_at
sorted_by id
sorted_by organization_name
sorted_by requested_by
sorted_by started_at
sorted_by user_friendly_id

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "user_friendly_id": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "started_at": "2019-08-24T14:15:22Z",
      "finished_at": "2019-08-24T14:15:22Z",
      "complexity": 1,
      "in_scope": "string",
      "contact_info": "string",
      "complexity_text": "string",
      "requested_by": "user@example.com",
      "comments": "string",
      "organization": 0,
      "organization_name": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedReadGreyboxRequestList

create_greybox_request

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/greyboxes/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/greyboxes/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "requested_by": 0,
  "started_at": "2019-08-24T14:15:22Z",
  "finished_at": "2019-08-24T14:15:22Z",
  "in_scope": "string",
  "comments": "string",
  "contact_info": "string",
  "complexity": 1,
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/greyboxes/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/greyboxes/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/greyboxes/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/greyboxes/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/greyboxes/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/greyboxes/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/greyboxes/

API endpoint that allows Greybox Requests to be viewed or edited.

Body parameter

{
  "requested_by": 0,
  "started_at": "2019-08-24T14:15:22Z",
  "finished_at": "2019-08-24T14:15:22Z",
  "in_scope": "string",
  "comments": "string",
  "contact_info": "string",
  "complexity": 1,
  "organization": 0
}
requested_by: 0
started_at: 2019-08-24T14:15:22Z
finished_at: 2019-08-24T14:15:22Z
in_scope: string
comments: string
contact_info: string
complexity: 1
organization: 0

Parameters

Name In Type Required Description
body body WriteGreyboxRequest true none

Example responses

201 Response

{
  "score": "string"
}

Responses

Status Meaning Description Schema
201 Created none Success
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage

itsm

itsm_config_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/config/

Retrieve the ITSM configuration(s) from DB. If config_id is set, retrieve
only the configuration of this config. Otherwise, retrieve the first one.

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
        * options (dict) -- list of ITSM configs as dictionnaries, with an additionnal key ìd` the "ITSM config id in Patrowl DB"
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_config_del_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/config/del/

Delete an ITSM configuration from DB.

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * body (dict) -- The ITSM submitted configuration stored in a dictionnary (see function description above)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_config_del_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/del/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/itsm/{config_id}/config/del/

Delete an ITSM configuration from DB.

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * body (dict) -- The ITSM submitted configuration stored in a dictionnary (see function description above)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

itsm_config_set_create_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/itsm/{config_id}/config/set/

Set an ITSM configuration in DB from a json dictionary of options.
If config_id is not set, creates a new entry.
If config_id exists in db, update the entry.

ITSM config details :
{
    'name': [str, 'Configuration name'],
    'vendor': [str, 'ITSM Vendor name'],
    'auth_mode': [str, 'ITSM Authentication mode'],
    'is_saas': [bool, 'SaaS or On-Premise'],
    'instance': [str, 'URL or instance name'],
    'ssltls_disable': [bool, 'Disabling SSL/TLS'],
    'is_default': [bool, 'Set this config as default'],

    # Specific for glpi:basic_auth
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],

    # Specific for glpi:user_token
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'user_token': [str, 'User Token'],  # from GLPI > Home > My Settings > Remote access keys : API token (user_token)

    # Specific for jira:basic_auth
    'login': [str, 'Username or Email for Jira SaaS'],
    'password': [str, 'Password', ''],
    'jira_project': [str, 'Project Key or ID'],
    'jira_issuetype': [str, 'Type of issue'],  # type of the ticket like ``Task``, ``Bug``, ``Issue``...

    # Specific for snow:basic_auth
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],
    'snow_tablename': [str, 'ServiceNow ticket table name'],
},
Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * body (dict) -- The ITSM submitted configuration stored in a dictionnary (see function description above)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
        * config_id (str) -- id of the new or updated config in db
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_config_set_update_2

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/config/set/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/itsm/{config_id}/config/set/

Set an ITSM configuration in DB from a json dictionary of options.
If config_id is not set, creates a new entry.
If config_id exists in db, update the entry.

ITSM config details :
{
    'name': [str, 'Configuration name'],
    'vendor': [str, 'ITSM Vendor name'],
    'auth_mode': [str, 'ITSM Authentication mode'],
    'is_saas': [bool, 'SaaS or On-Premise'],
    'instance': [str, 'URL or instance name'],
    'ssltls_disable': [bool, 'Disabling SSL/TLS'],
    'is_default': [bool, 'Set this config as default'],

    # Specific for glpi:basic_auth
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],

    # Specific for glpi:user_token
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'user_token': [str, 'User Token'],  # from GLPI > Home > My Settings > Remote access keys : API token (user_token)

    # Specific for jira:basic_auth
    'login': [str, 'Username or Email for Jira SaaS'],
    'password': [str, 'Password', ''],
    'jira_project': [str, 'Project Key or ID'],
    'jira_issuetype': [str, 'Type of issue'],  # type of the ticket like ``Task``, ``Bug``, ``Issue``...

    # Specific for snow:basic_auth
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],
    'snow_tablename': [str, 'ServiceNow ticket table name'],
},
Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * body (dict) -- The ITSM submitted configuration stored in a dictionnary (see function description above)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
        * config_id (str) -- id of the new or updated config in db
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_groups_retrieve_3

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/groups/

List groups by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists... i hope so ;)
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * groups (List[Dict]) -- normalized list of groups with their properties:
            * id (str) -- the id of the group in the remote ITSM
            * name (str) -- name of the group
            * description (str) -- ⚠ Only on Snow, description of the group
            * link (str) -- link to the group's information in the remote ITSM
            * groups (List[Dict]) -- ⚠ Only on Jira, list of dict of name and link
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_groups_retrieve_4

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/groups/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/groups/{ids}

List groups by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists... i hope so ;)
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * groups (List[Dict]) -- normalized list of groups with their properties:
            * id (str) -- the id of the group in the remote ITSM
            * name (str) -- name of the group
            * description (str) -- ⚠ Only on Snow, description of the group
            * link (str) -- link to the group's information in the remote ITSM
            * groups (List[Dict]) -- ⚠ Only on Jira, list of dict of name and link
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_issuetypes_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/issuetypes/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/issuetypes/

List Jira issue types (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

⚠ Undocumented feature in Jira.
The name of the issue type is both in `name` and `untranslatedName`, the last one (untranslatedName) was introduced in June 2020 and should be used instead of `name`.
https://community.developer.atlassian.com/t/untranslatedname-property-returned-within-the-issue-types-api-response/46934

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `untranslatedName`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * issuetypes (List[Dict]) -- list of issue types infos :
            * untranslatedName(str): the untranslated name, in english, that must be used as a `key` when creating/getting a ticket
            * name(str): translated name of the issue type, just for cosmetic (`Bogue` for bug but in french...)
            * iconUrl(str): url to the icon for the issue type
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_jira_issuetypes_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-issuetypes/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/jira-issuetypes/

List Jira issue types (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

⚠ Undocumented feature in Jira.
The name of the issue type is both in `name` and `untranslatedName`, the last one (untranslatedName) was introduced in June 2020 and should be used instead of `name`.
https://community.developer.atlassian.com/t/untranslatedname-property-returned-within-the-issue-types-api-response/46934

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `untranslatedName`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * issuetypes (List[Dict]) -- list of issue types infos :
            * untranslatedName(str): the untranslated name, in english, that must be used as a `key` when creating/getting a ticket
            * name(str): translated name of the issue type, just for cosmetic (`Bogue` for bug but in french...)
            * iconUrl(str): url to the icon for the issue type
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_jira_projects_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/jira-projects/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/jira-projects/

List Jira projects (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `name`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * projects (List[Dict]) -- list of projects, for details, please see classMiniJira:get_projects():
            * name(str): name of the project
            * key(str): short name of the project, that must be used as a key when creating/getting a ticket
            * id(str): id of the project
            * projectTypeKey (str): TEMPORARILY DISABLED
            * avatarUrls(Dict[str]): TEMPORARILY DISABLED dictionnary of icons' url, dict keys are the resolution (16x16, 48x48...)
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_projects_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/projects/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/projects/

List Jira projects (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `name`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * projects (List[Dict]) -- list of projects, for details, please see classMiniJira:get_projects():
            * name(str): name of the project
            * key(str): short name of the project, that must be used as a key when creating/getting a ticket
            * id(str): id of the project
            * projectTypeKey (str): TEMPORARILY DISABLED
            * avatarUrls(Dict[str]): TEMPORARILY DISABLED dictionnary of icons' url, dict keys are the resolution (16x16, 48x48...)
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_snow_tablenames_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/snow-tablenames/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/snow-tablenames/

List Service Now / SNOW table names (if ITSM is SNOW ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in  `desc` aka `label` in snow world
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * table names (List[Dict]) -- list of table informations, including names :
            * key (str) -- key of the table, it's snow's `tablename` wich is used for tickets get/set
            * id (str) -- system real id of a table, it's snow's `sys_id` used for specific requests like web link
            * name (str) -- short name of a table, it's a technical name
            * desc (str) -- long name of a table, kind of description
            * link (str) -- link to the table information
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_retrieve_3

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/tickets/

List tickets by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets (List[Dict]) -- List of ticket infos as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * title (str) -- title of the ticket
            * content (str) -- content of the ticket
            * link (str) -- link to the ticket on the ITSM
            * created_at (int) -- date of creation
            * priority (int) -- priority of the ticket
            * status (int) -- status of the ticket
            * status_name (str) -- ⚠ Only for Jira, status of the ticket as a string if status=0, if not Jira, is empty str
            * assigned_to_users (list) -- list of users' id assigned to the ticket
            * assigned_to_groups (list) -- list of groups' id assigned to the ticket
            * jira_issuetype (str) -- ⚠ Only for Jira, Type of Jira issue (bug, issue...)

Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_retrieve_4

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/tickets/{ids}

List tickets by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets (List[Dict]) -- List of ticket infos as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * title (str) -- title of the ticket
            * content (str) -- content of the ticket
            * link (str) -- link to the ticket on the ITSM
            * created_at (int) -- date of creation
            * priority (int) -- priority of the ticket
            * status (int) -- status of the ticket
            * status_name (str) -- ⚠ Only for Jira, status of the ticket as a string if status=0, if not Jira, is empty str
            * assigned_to_users (list) -- list of users' id assigned to the ticket
            * assigned_to_groups (list) -- list of groups' id assigned to the ticket
            * jira_issuetype (str) -- ⚠ Only for Jira, Type of Jira issue (bug, issue...)

Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_set_create_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/set/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/itsm/{config_id}/tickets/set/

Create a ticket in the remote ITSM

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * post_data (dict): A dictionnary of the ticket content and normalized informations:
            * title (str) -- Common to all ITSM, title of the ticket
            * content (str) -- Common to all ITSM, content of the ticket
            * assigned_to_users (List[int], optional) -- Common to all ITSM, list of users id as integer (0, 1 or more)
                GLPI support multiple users
                JIRA support only one user
            * assigned_to_groups (List[int], optional) -- Common to all ITSM, list of groups id as integer (0, 1 or more)
                GLPI support multiple groups
                JIRA does not support groups
            * priority (int) -- Common to all ITSM, priority of the ticket :
                1: very low / lowest
                2: low
                3: medium
                4: high
                5: very high
                6: major / highest
            * vuln_ids (List[int]) -- Common to all ITSM, list of ids of the vulnerabilities (id coming from patrowl's DB)
            * custom_remed_ids (List[int]) -- Common to all ITSM, list of ids of the custom remediation (id coming from patrowl's DB)
            * status (int, optional) -- ⚠ Only for GLPI ⚠ the status of the ticket to open a ticket can have a different status than new:
                0: Unknown
                1: New
                2: In Progress
                3: On Hold
                4: Resolved
                5: Closed
                6: Canceled
            * jira_project (str) -- ⚠ Only for Jira ⚠ the Jira Project name, it's `key` retrieved by API:itsm/jira-projects/
            * jira_issuetype (str) -- ⚠ Only for Jira ⚠ the Jira issue type, it's `untranslatedName` retrieved by API:itsm/jira-issuetypes/
            * snow_tablename (str) -- ⚠ Only for Snow ⚠ the Service Now table name, represented by the `key` retrieved by classMiniSnow.get_tables()

    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * ticket (dict) -- dictionnary of created ticket info:
            * itsm_ticket_id (str) -- id of the ticket, from remote ITSM
            * link (str) -- link to the ITSM ticket
            * status (int) -- the status of the ticket, force to 1=New
            * status_name (str) -- empty, not used in GLPI
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_status_retrieve_3

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/tickets/status/

List tickets status from ids by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
   ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets_status (List[Dict]) -- List of ticket infos, mainly status, as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * status (int) -- status of the ticket
                0: Unknown
                1: New
                2: In Progress
                3: On Hold
                4: Resolved
                5: Closed
                6: Canceled
            * status_name (str) -- ⚠ Only for Jira ⚠, status of the ticket as a string if status=0, if not Jira, is empty str
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_status_retrieve_4

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/tickets/status/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/tickets/status/{ids}

List tickets status from ids by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
   ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets_status (List[Dict]) -- List of ticket infos, mainly status, as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * status (int) -- status of the ticket
                0: Unknown
                1: New
                2: In Progress
                3: On Hold
                4: Resolved
                5: Closed
                6: Canceled
            * status_name (str) -- ⚠ Only for Jira ⚠, status of the ticket as a string if status=0, if not Jira, is empty str
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_users_retrieve_3

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/users/

List users by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * users (List[Dict]) -- normalized list of users with their properties:
            * id (str) -- the id of the user in the remote ITSM
            * name (str) -- name of the user
            * link (str) -- link to the user's profil in the remote ITSM
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_users_retrieve_4

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/{config_id}/users/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/{config_id}/users/{ids}

List users by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * users (List[Dict]) -- normalized list of users with their properties:
            * id (str) -- the id of the user in the remote ITSM
            * name (str) -- name of the user
            * link (str) -- link to the user's profil in the remote ITSM
Raises:
    No raise

Parameters

Name In Type Required Description
config_id path integer true none
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_config_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/config/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/config/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/config/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/config/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/config/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/config/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/config/

Retrieve the ITSM configuration(s) from DB. If config_id is set, retrieve
only the configuration of this config. Otherwise, retrieve the first one.

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
        * options (dict) -- list of ITSM configs as dictionnaries, with an additionnal key ìd` the "ITSM config id in Patrowl DB"
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_config_reset_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/config/reset/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/config/reset/

Delete all ITSM configuration from DB, related to the user's organization.

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * body (dict) -- The ITSM submitted configuration stored in a dictionnary (see function description above)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_config_set_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/itsm/config/set/

Set an ITSM configuration in DB from a json dictionary of options.
If config_id is not set, creates a new entry.
If config_id exists in db, update the entry.

ITSM config details :
{
    'name': [str, 'Configuration name'],
    'vendor': [str, 'ITSM Vendor name'],
    'auth_mode': [str, 'ITSM Authentication mode'],
    'is_saas': [bool, 'SaaS or On-Premise'],
    'instance': [str, 'URL or instance name'],
    'ssltls_disable': [bool, 'Disabling SSL/TLS'],
    'is_default': [bool, 'Set this config as default'],

    # Specific for glpi:basic_auth
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],

    # Specific for glpi:user_token
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'user_token': [str, 'User Token'],  # from GLPI > Home > My Settings > Remote access keys : API token (user_token)

    # Specific for jira:basic_auth
    'login': [str, 'Username or Email for Jira SaaS'],
    'password': [str, 'Password', ''],
    'jira_project': [str, 'Project Key or ID'],
    'jira_issuetype': [str, 'Type of issue'],  # type of the ticket like ``Task``, ``Bug``, ``Issue``...

    # Specific for snow:basic_auth
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],
    'snow_tablename': [str, 'ServiceNow ticket table name'],
},
Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * body (dict) -- The ITSM submitted configuration stored in a dictionnary (see function description above)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
        * config_id (str) -- id of the new or updated config in db
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_config_set_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/itsm/config/set/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/itsm/config/set/

Set an ITSM configuration in DB from a json dictionary of options.
If config_id is not set, creates a new entry.
If config_id exists in db, update the entry.

ITSM config details :
{
    'name': [str, 'Configuration name'],
    'vendor': [str, 'ITSM Vendor name'],
    'auth_mode': [str, 'ITSM Authentication mode'],
    'is_saas': [bool, 'SaaS or On-Premise'],
    'instance': [str, 'URL or instance name'],
    'ssltls_disable': [bool, 'Disabling SSL/TLS'],
    'is_default': [bool, 'Set this config as default'],

    # Specific for glpi:basic_auth
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],

    # Specific for glpi:user_token
    'app_token': [str, 'Application Token'],  # from GLPI > Setup > General > Api > API Client > Filter Access : Application Token (app_token)
    'user_token': [str, 'User Token'],  # from GLPI > Home > My Settings > Remote access keys : API token (user_token)

    # Specific for jira:basic_auth
    'login': [str, 'Username or Email for Jira SaaS'],
    'password': [str, 'Password', ''],
    'jira_project': [str, 'Project Key or ID'],
    'jira_issuetype': [str, 'Type of issue'],  # type of the ticket like ``Task``, ``Bug``, ``Issue``...

    # Specific for snow:basic_auth
    'login': [str, 'Username or Login'],
    'password': [str, 'Password'],
    'snow_tablename': [str, 'ServiceNow ticket table name'],
},
Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * body (dict) -- The ITSM submitted configuration stored in a dictionnary (see function description above)
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * reason (str) -- the reason of the status
        * config_id (str) -- id of the new or updated config in db
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_groups_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/groups/

List groups by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists... i hope so ;)
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * groups (List[Dict]) -- normalized list of groups with their properties:
            * id (str) -- the id of the group in the remote ITSM
            * name (str) -- name of the group
            * description (str) -- ⚠ Only on Snow, description of the group
            * link (str) -- link to the group's information in the remote ITSM
            * groups (List[Dict]) -- ⚠ Only on Jira, list of dict of name and link
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_groups_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/groups/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/groups/{ids}

List groups by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists... i hope so ;)
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * groups (List[Dict]) -- normalized list of groups with their properties:
            * id (str) -- the id of the group in the remote ITSM
            * name (str) -- name of the group
            * description (str) -- ⚠ Only on Snow, description of the group
            * link (str) -- link to the group's information in the remote ITSM
            * groups (List[Dict]) -- ⚠ Only on Jira, list of dict of name and link
Raises:
    No raise

Parameters

Name In Type Required Description
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_issuetypes_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/issuetypes/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/issuetypes/

List Jira issue types (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

⚠ Undocumented feature in Jira.
The name of the issue type is both in `name` and `untranslatedName`, the last one (untranslatedName) was introduced in June 2020 and should be used instead of `name`.
https://community.developer.atlassian.com/t/untranslatedname-property-returned-within-the-issue-types-api-response/46934

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `untranslatedName`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * issuetypes (List[Dict]) -- list of issue types infos :
            * untranslatedName(str): the untranslated name, in english, that must be used as a `key` when creating/getting a ticket
            * name(str): translated name of the issue type, just for cosmetic (`Bogue` for bug but in french...)
            * iconUrl(str): url to the icon for the issue type
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_jira_issuetypes_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-issuetypes/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/jira-issuetypes/

List Jira issue types (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

⚠ Undocumented feature in Jira.
The name of the issue type is both in `name` and `untranslatedName`, the last one (untranslatedName) was introduced in June 2020 and should be used instead of `name`.
https://community.developer.atlassian.com/t/untranslatedname-property-returned-within-the-issue-types-api-response/46934

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `untranslatedName`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * issuetypes (List[Dict]) -- list of issue types infos :
            * untranslatedName(str): the untranslated name, in english, that must be used as a `key` when creating/getting a ticket
            * name(str): translated name of the issue type, just for cosmetic (`Bogue` for bug but in french...)
            * iconUrl(str): url to the icon for the issue type
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_jira_projects_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/jira-projects/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/jira-projects/

List Jira projects (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `name`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * projects (List[Dict]) -- list of projects, for details, please see classMiniJira:get_projects():
            * name(str): name of the project
            * key(str): short name of the project, that must be used as a key when creating/getting a ticket
            * id(str): id of the project
            * projectTypeKey (str): TEMPORARILY DISABLED
            * avatarUrls(Dict[str]): TEMPORARILY DISABLED dictionnary of icons' url, dict keys are the resolution (16x16, 48x48...)
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_projects_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/projects/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/projects/

List Jira projects (if ITSM is Jira ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in `name`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is 10
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * projects (List[Dict]) -- list of projects, for details, please see classMiniJira:get_projects():
            * name(str): name of the project
            * key(str): short name of the project, that must be used as a key when creating/getting a ticket
            * id(str): id of the project
            * projectTypeKey (str): TEMPORARILY DISABLED
            * avatarUrls(Dict[str]): TEMPORARILY DISABLED dictionnary of icons' url, dict keys are the resolution (16x16, 48x48...)
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_snow_tablenames_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/snow-tablenames/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/snow-tablenames/

List Service Now / SNOW table names (if ITSM is SNOW ;) )
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list. Search in  `desc` aka `label` in snow world
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * table names (List[Dict]) -- list of table informations, including names :
            * key (str) -- key of the table, it's snow's `tablename` wich is used for tickets get/set
            * id (str) -- system real id of a table, it's snow's `sys_id` used for specific requests like web link
            * name (str) -- short name of a table, it's a technical name
            * desc (str) -- long name of a table, kind of description
            * link (str) -- link to the table information
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/tickets/

List tickets by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets (List[Dict]) -- List of ticket infos as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * title (str) -- title of the ticket
            * content (str) -- content of the ticket
            * link (str) -- link to the ticket on the ITSM
            * created_at (int) -- date of creation
            * priority (int) -- priority of the ticket
            * status (int) -- status of the ticket
            * status_name (str) -- ⚠ Only for Jira, status of the ticket as a string if status=0, if not Jira, is empty str
            * assigned_to_users (list) -- list of users' id assigned to the ticket
            * assigned_to_groups (list) -- list of groups' id assigned to the ticket
            * jira_issuetype (str) -- ⚠ Only for Jira, Type of Jira issue (bug, issue...)

Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/tickets/{ids}

List tickets by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets (List[Dict]) -- List of ticket infos as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * title (str) -- title of the ticket
            * content (str) -- content of the ticket
            * link (str) -- link to the ticket on the ITSM
            * created_at (int) -- date of creation
            * priority (int) -- priority of the ticket
            * status (int) -- status of the ticket
            * status_name (str) -- ⚠ Only for Jira, status of the ticket as a string if status=0, if not Jira, is empty str
            * assigned_to_users (list) -- list of users' id assigned to the ticket
            * assigned_to_groups (list) -- list of groups' id assigned to the ticket
            * jira_issuetype (str) -- ⚠ Only for Jira, Type of Jira issue (bug, issue...)

Raises:
    No raise

Parameters

Name In Type Required Description
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_set_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/set/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/itsm/tickets/set/

Create a ticket in the remote ITSM

Args:
    request (rest_framework.request.Request): request metadatas that contains
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * post_data (dict): A dictionnary of the ticket content and normalized informations:
            * title (str) -- Common to all ITSM, title of the ticket
            * content (str) -- Common to all ITSM, content of the ticket
            * assigned_to_users (List[int], optional) -- Common to all ITSM, list of users id as integer (0, 1 or more)
                GLPI support multiple users
                JIRA support only one user
            * assigned_to_groups (List[int], optional) -- Common to all ITSM, list of groups id as integer (0, 1 or more)
                GLPI support multiple groups
                JIRA does not support groups
            * priority (int) -- Common to all ITSM, priority of the ticket :
                1: very low / lowest
                2: low
                3: medium
                4: high
                5: very high
                6: major / highest
            * vuln_ids (List[int]) -- Common to all ITSM, list of ids of the vulnerabilities (id coming from patrowl's DB)
            * custom_remed_ids (List[int]) -- Common to all ITSM, list of ids of the custom remediation (id coming from patrowl's DB)
            * status (int, optional) -- ⚠ Only for GLPI ⚠ the status of the ticket to open a ticket can have a different status than new:
                0: Unknown
                1: New
                2: In Progress
                3: On Hold
                4: Resolved
                5: Closed
                6: Canceled
            * jira_project (str) -- ⚠ Only for Jira ⚠ the Jira Project name, it's `key` retrieved by API:itsm/jira-projects/
            * jira_issuetype (str) -- ⚠ Only for Jira ⚠ the Jira issue type, it's `untranslatedName` retrieved by API:itsm/jira-issuetypes/
            * snow_tablename (str) -- ⚠ Only for Snow ⚠ the Service Now table name, represented by the `key` retrieved by classMiniSnow.get_tables()

    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * ticket (dict) -- dictionnary of created ticket info:
            * itsm_ticket_id (str) -- id of the ticket, from remote ITSM
            * link (str) -- link to the ITSM ticket
            * status (int) -- the status of the ticket, force to 1=New
            * status_name (str) -- empty, not used in GLPI
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_status_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/tickets/status/

List tickets status from ids by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
   ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets_status (List[Dict]) -- List of ticket infos, mainly status, as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * status (int) -- status of the ticket
                0: Unknown
                1: New
                2: In Progress
                3: On Hold
                4: Resolved
                5: Closed
                6: Canceled
            * status_name (str) -- ⚠ Only for Jira ⚠, status of the ticket as a string if status=0, if not Jira, is empty str
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_tickets_status_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/tickets/status/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/tickets/status/{ids}

List tickets status from ids by connecting to the ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * jira_project (str, optional) -- ⚠ Only for Jira, the Jira Project name as a query string/parameter as an integer in a string (?jira_project=TES)
        * snow_tablename (str, optional) -- ⚠ Only for Snow, the Servnice Now table name (?snow_tablename=incident)
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
   ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * tickets_status (List[Dict]) -- List of ticket infos, mainly status, as dict:
            * itsm_ticket_id (str) -- id of the ticket "on the ITSM side"
            * status (int) -- status of the ticket
                0: Unknown
                1: New
                2: In Progress
                3: On Hold
                4: Resolved
                5: Closed
                6: Canceled
            * status_name (str) -- ⚠ Only for Jira ⚠, status of the ticket as a string if status=0, if not Jira, is empty str
Raises:
    No raise

Parameters

Name In Type Required Description
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_users_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/users/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/users/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/users/

List users by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * users (List[Dict]) -- normalized list of users with their properties:
            * id (str) -- the id of the user in the remote ITSM
            * name (str) -- name of the user
            * link (str) -- link to the user's profil in the remote ITSM
Raises:
    No raise

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_users_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/users/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/users/{ids}

List users by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * users (List[Dict]) -- normalized list of users with their properties:
            * id (str) -- the id of the user in the remote ITSM
            * name (str) -- name of the user
            * link (str) -- link to the user's profil in the remote ITSM
Raises:
    No raise

Parameters

Name In Type Required Description
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

itsm_users_search_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/itsm/users/search/{ids}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/itsm/users/search/{ids}

List users by connecting to the remote ITSM.
A local cache keeps users in memory several minutes (5 to 10), to have a quicker answer.
See cache_expiration in real_list_itsm_items()

Args:
    request (rest_framework.request.Request): request metadatas that contains :
        * org_id (str) -- The organization id as a query string/parameter as an integer in a string (?org_id=123)
        * search (str) -- Search, containing this string. If empty, just list
        * start_at (str) -- Listing, starts at `start_at` (list from `start_at` to `start_at` + `limit`), default is `0`
        * limit (str) -- Listing or Search, maximum number of elements to retrieve, default is `10`
    config_id (int, optional): the id in db of the configuration. Defaults to 0 that does not exists
    ids (list, optional): List of IDs in the format of the vendor (0-9 or 0-9a-zA-Z or ...)
Returns:
    JsonResponse: Json dict with the following content:
        * status (str) -- error or success
        * users (List[Dict]) -- normalized list of users with their properties:
            * id (str) -- the id of the user in the remote ITSM
            * name (str) -- name of the user
            * link (str) -- link to the user's profil in the remote ITSM
Raises:
    No raise

Parameters

Name In Type Required Description
ids path string true none

Responses

Status Meaning Description Schema
200 OK No response body None

orgs

orgs_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/

API endpoint that allows Organizations to be viewed or edited.

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
owner query string false none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -name
sorted_by -owner
sorted_by -slug
sorted_by name
sorted_by owner
sorted_by slug

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "name": "string",
      "slug": "string",
      "is_active": true,
      "owner": "string",
      "user_count": 0,
      "is_poc": true,
      "is_sso": true,
      "risk_insights_enabled": true,
      "technologies_enabled": true,
      "brand_image_url": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "pentested_assets": 0,
      "max_pentested_assets_allowed": 0,
      "pentested_slot_available": 0,
      "max_pentested_slot_allowed": 0,
      "end_of_contract": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedOrganizationList

orgs_settings_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{org_id}/settings/

API endpoint that allows OrganizationSettings to be viewed or edited.

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
org_id path integer true none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -comments
sorted_by -key
sorted_by -value
sorted_by comments
sorted_by key
sorted_by value

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "key": "string",
      "value": "string",
      "is_secret": true,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedOrganizationSettingList

orgs_settings_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{org_id}/settings/{id}/

API endpoint that allows OrganizationSettings to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none
org_id path integer true none

Example responses

200 Response

{
  "id": 0,
  "key": "string",
  "value": "string",
  "is_secret": true,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none OrganizationSetting

orgs_settings_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "key": "string",
  "value": "string",
  "is_secret": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/orgs/{org_id}/settings/{id}/

API endpoint that allows OrganizationSettings to be viewed or edited.

Body parameter

{
  "key": "string",
  "value": "string",
  "is_secret": true
}
key: string
value: string
is_secret: true

Parameters

Name In Type Required Description
id path integer true none
org_id path integer true none
body body OrganizationSetting true none

Example responses

200 Response

{
  "id": 0,
  "key": "string",
  "value": "string",
  "is_secret": true,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none OrganizationSetting

orgs_settings_sla_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{org_id}/settings/sla

Get remediation sla settings.

Parameters

Name In Type Required Description
org_id path integer true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_settings_sla_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "slug": "string",
  "is_active": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/settings/sla", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/orgs/{org_id}/settings/sla

Set remediation sla settings.

Body parameter

{
  "name": "string",
  "slug": "string",
  "is_active": true
}
name: string
slug: string
is_active: true

Parameters

Name In Type Required Description
org_id path integer true none
body body Organization true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_users_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{org_id}/users/

API endpoint that allows OrganizationUser to be viewed or edited.

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
org_id path integer true none
page query integer false A page number within the paginated result set.
search query string false none
sorted_by query array[string] false Ordering

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -id
sorted_by -user__email
sorted_by -user__username
sorted_by -username
sorted_by id
sorted_by user__email
sorted_by user__username
sorted_by username

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "organization": 0,
      "user": 0,
      "username": "string",
      "email": "string",
      "is_admin": true,
      "is_active": true,
      "org_name": "string",
      "role": 0
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedOrganizationUserList

orgs_users_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "organization": 0,
  "user": 0,
  "is_admin": true,
  "user_ids": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/orgs/{org_id}/users/

Create One or Several Organization user.

Body parameter

{
  "organization": 0,
  "user": 0,
  "is_admin": true,
  "user_ids": [
    0
  ]
}
organization: 0
user: 0
is_admin: true
user_ids:
  - 0

Parameters

Name In Type Required Description
org_id path integer true none
body body OrganizationUser true none

Example responses

201 Response

{
  "id": 0,
  "organization": 0,
  "user": 0,
  "username": "string",
  "email": "string",
  "is_admin": true,
  "is_active": true,
  "org_name": "string",
  "role": 0
}

Responses

Status Meaning Description Schema
201 Created none OrganizationUser

orgs_users_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{org_id}/users/{id}/

API endpoint that allows OrganizationUser to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none
org_id path integer true none

Example responses

200 Response

{
  "id": 0,
  "organization": 0,
  "user": 0,
  "username": "string",
  "email": "string",
  "is_admin": true,
  "is_active": true,
  "org_name": "string",
  "role": 0
}

Responses

Status Meaning Description Schema
200 OK none OrganizationUser

orgs_users_delete_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{org_id}/users/{id}/delete", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/orgs/{org_id}/users/{id}/delete

Delete an existing Organization user.

Parameters

Name In Type Required Description
id path integer true none
org_id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

orgs_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{id}/

API endpoint that allows Organizations to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "slug": "string",
  "is_active": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/orgs/{id}/

API endpoint that allows Organizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "slug": "string",
  "is_active": true
}
name: string
slug: string
is_active: true

Parameters

Name In Type Required Description
id path integer true none
body body Organization true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "slug": "string",
  "is_active": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/orgs/{id}/

API endpoint that allows Organizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "slug": "string",
  "is_active": true
}
name: string
slug: string
is_active: true

Parameters

Name In Type Required Description
id path integer true none
body body Organization true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_brandimage_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "slug": "string",
  "is_active": true
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/brandimage", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/orgs/{id}/brandimage

Update the brand/organization image for a selected organization.

Body parameter

{
  "name": "string",
  "slug": "string",
  "is_active": true
}
name: string
slug: string
is_active: true

Parameters

Name In Type Required Description
id path integer true none
body body Organization true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_not_users_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/not-users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{id}/not-users/

List the users not in the organization.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_pentested_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/{id}/pentested/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/{id}/pentested/

Get oranigazition monitorings informations

:return 404: Org not found

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_arsenalstatus_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/arsenalstatus", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/arsenalstatus

Retrieve Arsenal operation status.

Example responses

200 Response

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Organization

orgs_export_csv_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/export/csv

API endpoint that allows SubOrganizations to be viewed or edited.

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

orgs_export_csv_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/orgs/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/orgs/export/csv

API endpoint that allows SubOrganizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
body body SubOrganization true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

orgs_suborgs_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/orgs/suborgs

Create a new suborganization

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
body body SubOrganization true none

Example responses

201 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
201 Created none SubOrganization

orgs_suborgs_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/orgs/suborgs

Delete an existing suborganization.

Responses

Status Meaning Description Schema
204 No Content No response body None

orgs_suborgs_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/suborgs/{id}/

Get details of an existing suborganization.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

orgs_suborgs_create_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/orgs/suborgs/{id}/

API endpoint that allows SubOrganizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
id path integer true none
body body SubOrganization true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

orgs_suborgs_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/orgs/suborgs/{id}/

API endpoint that allows SubOrganizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
id path integer true none
body body SubOrganization true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

orgs_suborgs_list_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/suborgs/list

API endpoint that allows SubOrganizations to be viewed or edited.

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.
search query string false none

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "is_default": true,
      "organization": 0,
      "name": "string",
      "slug": "string",
      "user_count": "string",
      "assetgroup_count": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "parent": 0,
      "asset_count": "string",
      "children": "string",
      "parent_name": "string",
      "root_id": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedSubOrganizationsInListList

orgs_suborgs_list_all_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/orgs/suborgs/list_all", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/orgs/suborgs/list_all

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "name": "string",
      "slug": "string",
      "parent_name": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedSubOrganizationsListList

overview

overview_widgets_data_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/data", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/overview/{org_id}/widgets/data

Return periodic stats.

Parameters

Name In Type Required Description
org_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

overview_widgets_feeds_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/feeds", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/overview/{org_id}/widgets/feeds

Return latest feeds.

Parameters

Name In Type Required Description
org_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

overview_widgets_score_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/score", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/overview/{org_id}/widgets/score

Return global patrowl score and graph stats (monthly by default).

Parameters

Name In Type Required Description
org_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

overview_widgets_stats_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/stats", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/overview/{org_id}/widgets/stats

Return global statistics.

Parameters

Name In Type Required Description
org_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

overview_widgets_vulns_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/overview/{org_id}/widgets/vulns", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/overview/{org_id}/widgets/vulns

Return vulnerabilities graph.

Parameters

Name In Type Required Description
org_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

pentests

pentests_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/pentests/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/pentests/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/pentests/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/pentests/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/pentests/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/pentests/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/pentests/

API endpoint that allows Pentests to be viewed or edited.

Parameters

Name In Type Required Description
created_at query string(date-time) false none
id query integer false none
is_greybox query boolean false none
limit query integer false Number of results to return per page.
org query string false none
page query integer false A page number within the paginated result set.
requested_by query string false none
search query string false none
sorted_by query array[string] false Ordering
title query string false none
updated_at query string(date-time) false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -id
sorted_by -nb_assets
sorted_by -nb_vulns
sorted_by -title
sorted_by -updated_at
sorted_by created_at
sorted_by id
sorted_by nb_assets
sorted_by nb_vulns
sorted_by title
sorted_by updated_at

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "requested_by": "string",
      "title": "string",
      "provider": "string",
      "organization": 0,
      "description": "string",
      "comments": "string",
      "date_from": "2019-08-24T14:15:22Z",
      "date_to": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "nb_vulns": 0,
      "attachments": "string",
      "nb_assets": 0,
      "is_greybox": true,
      "pentest_suborganization": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedPentestList

pentests_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/pentests/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/pentests/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/pentests/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/pentests/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/pentests/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/pentests/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/pentests/

API endpoint that allows Pentests to be viewed or edited.

Body parameter

{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}
title: string
provider: string
organization: 0
description: string
comments: string
date_from: 2019-08-24T14:15:22Z
date_to: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
is_greybox: true
suborganization: 0

Parameters

Name In Type Required Description
body body Pentest true none

Example responses

201 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
201 Created none Pentest

pentests_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/pentests/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/pentests/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/pentests/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/pentests/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/pentests/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/pentests/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/pentests/

Delete a pentest.

Responses

Status Meaning Description Schema
204 No Content No response body None

pentests_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/pentests/{id}/

API endpoint that allows Pentests to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

pentests_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/pentests/{id}/

API endpoint that allows Pentests to be viewed or edited.

Body parameter

{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}
title: string
provider: string
organization: 0
description: string
comments: string
date_from: 2019-08-24T14:15:22Z
date_to: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
is_greybox: true
suborganization: 0

Parameters

Name In Type Required Description
id path integer true none
body body PatchedPentest false none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

pentests_destroy_2

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/pentests/{id}/

Delete a pentest.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

pentests_assets_export_csv_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/pentests/{id}/assets/export/csv

Export related assets as CSV.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

pentest_assets_import_assets_from_csv

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv?org_id=0 \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv?org_id=0 HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv?org_id=0',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv',
  params: {
  'org_id' => 'integer'
}, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv', params={
  'org_id': '0'
}, headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv?org_id=0");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/import/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/pentests/{id}/assets/import/csv

Import Assets from CSV

:param file: The csv file

:return: 400: Invalid CSV

:return: 200: Success

Body parameter

{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}
title: string
provider: string
organization: 0
description: string
comments: string
date_from: 2019-08-24T14:15:22Z
date_to: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
is_greybox: true
suborganization: 0

Parameters

Name In Type Required Description
id path integer true none
org_id query integer true Organization
body body Pentest true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage

pentest_remove_assets

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/assets/remove", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/pentests/{id}/assets/remove

API endpoint that allows Pentests to be viewed or edited.

Body parameter

{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}
title: string
provider: string
organization: 0
description: string
comments: string
date_from: 2019-08-24T14:15:22Z
date_to: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
is_greybox: true
suborganization: 0

Parameters

Name In Type Required Description
id path integer true none
body body Pentest true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

pentests_attachements_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/attachements", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/pentests/{id}/attachements

Upload file attachments

:return 404: Pentest not found

:return 400: Invalid file or title

:return 201: Pentest Attachment upload

Body parameter

{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}
title: string
provider: string
organization: 0
description: string
comments: string
date_from: 2019-08-24T14:15:22Z
date_to: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
is_greybox: true
suborganization: 0

Parameters

Name In Type Required Description
id path integer true none
body body Pentest true none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

pentests_vulns_export_csv_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/pentests/{id}/vulns/export/csv

Export related vulns as CSV.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

pentests_vulns_import_csv_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/pentests/{id}/vulns/import/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/pentests/{id}/vulns/import/csv

API endpoint that allows Pentests to be viewed or edited.

Body parameter

{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}
title: string
provider: string
organization: 0
description: string
comments: string
date_from: 2019-08-24T14:15:22Z
date_to: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
is_greybox: true
suborganization: 0

Parameters

Name In Type Required Description
id path integer true none
body body Pentest true none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

pentests_attachements_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/pentests/attachements/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/pentests/attachements/{id}/

Delete file link to a vulnerability

:return 404: File not found

:return 403: Unauthorized to delete file upload by Patrowl

:return 400: Unable to delete this file

:return 204: Success

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

pentests_org_export_csv_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/pentests/org/{org_id}/export/csv

Export pentest data as CSV content.

Parameters

Name In Type Required Description
org_id path integer true none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

pentests_org_export_csv_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/pentests/org/{org_id}/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/pentests/org/{org_id}/export/csv

Export pentest data as CSV content.

Body parameter

{
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_greybox": true,
  "suborganization": 0
}
title: string
provider: string
organization: 0
description: string
comments: string
date_from: 2019-08-24T14:15:22Z
date_to: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
is_greybox: true
suborganization: 0

Parameters

Name In Type Required Description
org_id path integer true none
body body Pentest true none

Example responses

200 Response

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "pentest_suborganization": "string"
}

Responses

Status Meaning Description Schema
200 OK none Pentest

remediations

remediations_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/remediations \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/remediations HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/remediations',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/remediations', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/remediations', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/remediations", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/remediations

API endpoint that allows Remediations to be viewed or edited.

Parameters

Name In Type Required Description
after query string(date-time) false none
before query string(date-time) false none
created_at query string(date-time) false none
created_at__gte query string(date-time) false none
created_at__lte query string(date-time) false none
effort query string false * low - Low
gain query integer false none
gain__gte query integer false none
gain__lte query integer false none
headline query string false none
headline__icontains query string false none
id query integer false none
limit query integer false Number of results to return per page.
org_id query string false none
owners query string false none
page query integer false A page number within the paginated result set.
priority query string false * urgent - Urgent
search query string false none
solution__icontains query string false none
sorted_by query array[string] false Ordering
status query string false * new - New
status__icontains query string false none

Detailed descriptions

effort: * low - Low * medium - Medium * high - High

priority: * urgent - Urgent * moderate - Moderate * hardening - Hardening

sorted_by: Ordering

status: * new - New * ack - Acknowledged * assigned - Assigned * patched - Patched * closed - Closed * closed-benign - Closed (Benign) * closed-fp - Closed (False-Positive) * closed-duplicate - Closed (Duplicate) * closed-workaround - Closed (Workaround) * closed-risk-acceptance - Closed (Risk acceptance)

Enumerated Values

Parameter Value
effort high
effort low
effort medium
priority hardening
priority moderate
priority urgent
sorted_by -count_vulns
sorted_by -effort
sorted_by -headline
sorted_by -priority
sorted_by -status
sorted_by count_vulns
sorted_by effort
sorted_by headline
sorted_by priority
sorted_by status
status ack
status assigned
status closed
status closed-benign
status closed-duplicate
status closed-fp
status closed-risk-acceptance
status closed-workaround
status new
status patched

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "organization": 0,
      "headline": "string",
      "solution": "string",
      "solution_html": "string",
      "priority": "urgent",
      "effort": "low",
      "gain": 0,
      "owners": [
        {
          "id": 0,
          "email": "user@example.com"
        }
      ],
      "due_date": "2019-08-24T14:15:22Z",
      "status": "new",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "suborganization": 0,
      "suborganization_name": "string",
      "count_vulns": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedRemediationList

create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/remediations \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/remediations HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "priority": "urgent",
  "effort": "low",
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/remediations',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/remediations', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/remediations', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/remediations", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/remediations

API endpoint that allows Remediations to be viewed or edited.

Body parameter

{
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "priority": "urgent",
  "effort": "low",
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "suborganization": 0
}
organization: 0
headline: string
solution: string
priority: urgent
effort: low
due_date: 2019-08-24T14:15:22Z
status: new
suborganization: 0

Parameters

Name In Type Required Description
body body Remediation true none

Example responses

201 Response

{
  "id": 0,
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "solution_html": "string",
  "priority": "urgent",
  "effort": "low",
  "gain": 0,
  "owners": [
    {
      "id": 0,
      "email": "user@example.com"
    }
  ],
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "suborganization": 0,
  "suborganization_name": "string",
  "count_vulns": "string"
}

Responses

Status Meaning Description Schema
201 Created none Remediation
404 Not Found none BasicResponseWithMessage

remediation_bulk_delete

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/remediations',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/remediations', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/remediations', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/remediations", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/remediations

API endpoint that allows Remediations to be viewed or edited.

Example responses

204 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
204 No Content none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

remediations_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/remediations/{id}/

API endpoint that allows Remediations to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "solution_html": "string",
  "priority": "urgent",
  "effort": "low",
  "gain": 0,
  "owners": [
    {
      "id": 0,
      "email": "user@example.com"
    }
  ],
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "suborganization": 0,
  "suborganization_name": "string",
  "count_vulns": "string"
}

Responses

Status Meaning Description Schema
200 OK none Remediation

partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "priority": "urgent",
  "effort": "low",
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "suborganization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/remediations/{id}/

API endpoint that allows Remediations to be viewed or edited.

Body parameter

{
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "priority": "urgent",
  "effort": "low",
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "suborganization": 0
}
organization: 0
headline: string
solution: string
priority: urgent
effort: low
due_date: 2019-08-24T14:15:22Z
status: new
suborganization: 0

Parameters

Name In Type Required Description
id path integer true none
body body PatchedRemediation false none

Example responses

200 Response

{
  "id": 0,
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "solution_html": "string",
  "priority": "urgent",
  "effort": "low",
  "gain": 0,
  "owners": [
    {
      "id": 0,
      "email": "user@example.com"
    }
  ],
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "suborganization": 0,
  "suborganization_name": "string",
  "count_vulns": "string"
}

Responses

Status Meaning Description Schema
200 OK none Remediation
400 Bad Request none BasicResponseWithMessage

remediations_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/remediations/{id}/

API endpoint that allows Remediations to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

remediation_list_comments

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/remediations/{id}/comments

List related comments

:return 404: Custom remediation not found

Parameters

Name In Type Required Description
after query string(date-time) false none
before query string(date-time) false none
created_at query string(date-time) false none
created_at__gte query string(date-time) false none
created_at__lte query string(date-time) false none
effort query string false * low - Low
gain query integer false none
gain__gte query integer false none
gain__lte query integer false none
headline query string false none
headline__icontains query string false none
id path integer true none
id query integer false none
limit query integer false Number of results to return per page.
org_id query string false none
owners query string false none
page query integer false A page number within the paginated result set.
priority query string false * urgent - Urgent
search query string false none
solution__icontains query string false none
sorted_by query array[string] false Ordering
status query string false * new - New
status__icontains query string false none

Detailed descriptions

effort: * low - Low * medium - Medium * high - High

priority: * urgent - Urgent * moderate - Moderate * hardening - Hardening

sorted_by: Ordering

status: * new - New * ack - Acknowledged * assigned - Assigned * patched - Patched * closed - Closed * closed-benign - Closed (Benign) * closed-fp - Closed (False-Positive) * closed-duplicate - Closed (Duplicate) * closed-workaround - Closed (Workaround) * closed-risk-acceptance - Closed (Risk acceptance)

Enumerated Values

Parameter Value
effort high
effort low
effort medium
priority hardening
priority moderate
priority urgent
sorted_by -count_vulns
sorted_by -effort
sorted_by -headline
sorted_by -priority
sorted_by -status
sorted_by count_vulns
sorted_by effort
sorted_by headline
sorted_by priority
sorted_by status
status ack
status assigned
status closed
status closed-benign
status closed-duplicate
status closed-fp
status closed-risk-acceptance
status closed-workaround
status new
status patched

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "text": "string",
      "author": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "is_editable": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedCommentList
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

remediation_create_comment

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "text": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/comments", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/remediations/{id}/comments

Add a new comment

:return 404: Custom Remediation not found

:return 201: Create a new comment and add it to custom remediation

Body parameter

{
  "text": "string"
}
text: string

Parameters

Name In Type Required Description
id path integer true none
body body Comment true none

Example responses

201 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
201 Created none BasicResponse
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

custom_remediations_add_owners

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "users_id": [
    null
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/remediations/{id}/owners

Add several owners to a custom remediation

:return: 404: Custom Remediations not found

:return: 400: Invalid data

:return 200: Success

Body parameter

{
  "users_id": [
    null
  ]
}
users_id:
  - null

Parameters

Name In Type Required Description
id path integer true none
body body custom_remediations_add_owners true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

custom_remediations_remove_owners

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/remediations/{id}/owners

Remove several owners from a custom remediation

:param assets_id: List with all the IDs to remove

:return 404: Custom Remediation Not found

:return 400: Invalid data

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

custom_remediations_add_vulnerabilities

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "vulnerabilities_id": [
    null
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/remediations/{id}/vulnerabilities

Add several vulnerabilities to a custom remediation

:return: 404: Custom Remediations not found

:return: 400 Invalid data

Body parameter

{
  "vulnerabilities_id": [
    null
  ]
}
vulnerabilities_id:
  - null

Parameters

Name In Type Required Description
id path integer true none
body body custom_remediations_add_vulnerabilities true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

custom_remediations_remove_vulnerabilities

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/remediations/{id}/vulnerabilities", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/remediations/{id}/vulnerabilities

Remove several vulnerabilities from a custom remediation

:param assets_id: List with all the IDs to remove

:return 404: Custom Remediation Not found

:return 400: Invalid data

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

report

report_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/report/{org_id} \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/report/{org_id} HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/report/{org_id}

Generate a PDF report and receive it by email. Without parameter, it will generate a global report with all vulnerabilities raised by Patrowl. Otherwise, you can specify which data to export.

Parameters

Name In Type Required Description
org_id path string true Your organization ID.

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK Success, the report will be generated and sent to you by e-mail. BasicResponseWithMessage
403 Forbidden Error, either your organization is in PoC (which is not allowed to download a report), or you do not have access to the organization BasicResponseWithMessage
404 Not Found Error, your organization org_id does not exist. BasicResponseWithMessage

report_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/report/{org_id} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/report/{org_id} HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "emails": [
    "user@example.com"
  ],
  "assets": [
    0
  ],
  "vulnerabilities": [
    0
  ],
  "assetgroups": [
    0
  ],
  "assets_from_assetgroups": [
    0
  ],
  "vulnerabilities_from_assetgroups": [
    0
  ],
  "pentests": [
    0
  ],
  "assets_from_pentests": [
    0
  ],
  "vulnerabilities_from_pentests": [
    0
  ],
  "suborganizations": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/report/{org_id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/report/{org_id}

Generate a PDF report and receive it by email. Without parameter, it will generate a global report with all vulnerabilities raised by Patrowl. Otherwise, you can specify which data to export.

Body parameter

{
  "emails": [
    "user@example.com"
  ],
  "assets": [
    0
  ],
  "vulnerabilities": [
    0
  ],
  "assetgroups": [
    0
  ],
  "assets_from_assetgroups": [
    0
  ],
  "vulnerabilities_from_assetgroups": [
    0
  ],
  "pentests": [
    0
  ],
  "assets_from_pentests": [
    0
  ],
  "vulnerabilities_from_pentests": [
    0
  ],
  "suborganizations": [
    0
  ]
}
emails:
  - user@example.com
assets:
  - 0
vulnerabilities:
  - 0
assetgroups:
  - 0
assets_from_assetgroups:
  - 0
vulnerabilities_from_assetgroups:
  - 0
pentests:
  - 0
assets_from_pentests:
  - 0
vulnerabilities_from_pentests:
  - 0
suborganizations:
  - 0

Parameters

Name In Type Required Description
org_id path string true Your organization ID.
body body DownloadReporting false none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK Success, the report will be generated and sent to you by e-mail. BasicResponseWithMessage
403 Forbidden Error, either your organization is in PoC (which is not allowed to download a report), or you do not have access to the organization BasicResponseWithMessage
404 Not Found Error, your organization org_id does not exist. BasicResponseWithMessage

report_fast_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id}',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/report/fast/{org_id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/report/fast/{org_id}

Return periodic stats.

Parameters

Name In Type Required Description
org_id path integer true none

Responses

Status Meaning Description Schema
200 OK No response body None

retests

retests_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/retests/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/retests/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/retests/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/retests/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/retests/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/retests/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/retests/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/retests/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/retests/

API endpoint that allows Retests to be viewed or edited.

Parameters

Name In Type Required Description
created_at query string(date-time) false none
id query integer false none
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.
sorted_by query array[string] false Ordering
status query string false * none - None
updated_at query string(date-time) false none

Detailed descriptions

sorted_by: Ordering

status: * none - None * pending - Pending * in-progress - In Progress * done-fixed - Done (Fixed) * done-not-fixed - Done (Not Fixed) * error - Error * canceled - Canceled

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -id
sorted_by -status
sorted_by -updated_at
sorted_by created_at
sorted_by id
sorted_by status
sorted_by updated_at
status canceled
status done-fixed
status done-not-fixed
status error
status in-progress
status none
status pending

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "patrowl_id": 0,
      "vulnerability": 0,
      "status": "none",
      "comments": "string",
      "requested_by": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "is_auto": true
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedRetestList

retests_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/retests/{id}/

API endpoint that allows Retests to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "patrowl_id": 0,
  "vulnerability": 0,
  "status": "none",
  "comments": "string",
  "requested_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_auto": true
}

Responses

Status Meaning Description Schema
200 OK none Retest

retests_update_comment

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "comment": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/retests/{id}/

Update the comment of one retest

:return: 404: Retest not found

:return: 200: Success

Body parameter

{
  "comment": "string"
}
comment: string

Parameters

Name In Type Required Description
id path integer true none
body body retests_update_comment true none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

retests_cancel

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/cancel", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/retests/{id}/cancel

Cancel one specific retest and sync with PatrowlArsenal.

:return 404: Retest not found

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponse
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

retests_refresh

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/retests/{id}/refresh", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/retests/{id}/refresh

Refresh a retest, sync with PatrowlArsenal.

:return 400: Error during the sync with arsenal

:return 404: Retest not found

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "patrowl_id": 0,
  "vulnerability": 0,
  "status": "none",
  "comments": "string",
  "requested_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_auto": true
}

Responses

Status Meaning Description Schema
200 OK none Retest
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

retests_settings

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/retests/settings \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/retests/settings HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/retests/settings',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/retests/settings',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/retests/settings', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/retests/settings', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/retests/settings");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/retests/settings", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/retests/settings

Sync retests with PatrowlArsenal.

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

risks

risks_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "resourcetype": "string",
      "id": 0,
      "title": "string",
      "light_description": "string",
      "severity": 0,
      "status": 0,
      "subtopic": "string",
      "asset": {
        "id": 0,
        "value": "string",
        "is_monitored": true
      },
      "topic": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "last_seen_at": "2019-08-24T14:15:22Z",
      "serial_number": "string",
      "port": "string",
      "expiration_date": "string",
      "subject": "string",
      "issuer": "string",
      "product": "string",
      "raw_data": "string",
      "provider": "string",
      "protection": true,
      "selector": "string",
      "qualifier": "string",
      "policy": "string",
      "mx_records": "string",
      "protocol": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedInsightPolymorphicList

risks_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/risks/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/risks/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/risks/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/risks/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/risks/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/risks/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/risks/

Body parameter

{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}
resourcetype: string
light_description: string
severity: 0
status: 0
asset:
  value: string
  is_monitored: true

Parameters

Name In Type Required Description
body body InsightPolymorphic false none

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/{id}/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/risks/{id}/

Body parameter

{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}
resourcetype: string
light_description: string
severity: 0
status: 0
asset:
  value: string
  is_monitored: true

Parameters

Name In Type Required Description
id path integer true none
body body PatchedInsightPolymorphic false none

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_pem_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/{id}/pem/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/{id}/pem/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_by_severity_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/by-severity/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/by-severity/

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_count_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/count/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/count/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/count/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/count/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/count/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/count/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/count/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/count/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/count/

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_export_csv_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/export/csv/

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_export_csv_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/risks/export/csv/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/risks/export/csv/

Body parameter

{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}
resourcetype: string
light_description: string
severity: 0
status: 0
asset:
  value: string
  is_monitored: true

Parameters

Name In Type Required Description
body body InsightPolymorphic false none

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_export_json_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/export/json/

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_export_json_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/risks/export/json/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/risks/export/json/

Body parameter

{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}
resourcetype: string
light_description: string
severity: 0
status: 0
asset:
  value: string
  is_monitored: true

Parameters

Name In Type Required Description
body body InsightPolymorphic false none

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_over_time_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/over-time/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/over-time/

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_policies_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/policies/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/policies/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/policies/

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "description": "string",
      "is_enabled": true,
      "severity": 0,
      "created_by": {
        "id": 0,
        "email": "user@example.com"
      },
      "organization": 0,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "active_vulnerabilities": "string",
      "filters": "string",
      "already_applied": true
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedInsightPolicyList

risks_policies_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/risks/policies/

Create a new Insight Policy

Body parameter

{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}
title: string
description: string
is_enabled: true
severity: 0
organization: 0

Parameters

Name In Type Required Description
body body InsightPolicy true none

Example responses

201 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Responses

Status Meaning Description Schema
201 Created none InsightPolicy

risks_policies_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/risks/policies/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/risks/policies/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/risks/policies/

Body parameter

{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}
title: string
description: string
is_enabled: true
severity: 0
organization: 0

Parameters

Name In Type Required Description
body body PatchedInsightPolicy false none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Responses

Status Meaning Description Schema
200 OK none InsightPolicy

risks_policies_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/policies/{id}/

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Responses

Status Meaning Description Schema
200 OK none InsightPolicy

risks_policies_partial_update_2

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/risks/policies/{id}/

Body parameter

{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0
}
title: string
description: string
is_enabled: true
severity: 0

Parameters

Name In Type Required Description
id path integer true none
body body PatchedUpdateInsightPolicy false none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Responses

Status Meaning Description Schema
200 OK none UpdateInsightPolicy

risks_policies_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/risks/policies/{id}/

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

risks_policies_apply_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/apply/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/risks/policies/{id}/apply/

Body parameter

{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}
title: string
description: string
is_enabled: true
severity: 0
organization: 0

Parameters

Name In Type Required Description
id path integer true none
body body InsightPolicy true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Responses

Status Meaning Description Schema
200 OK none InsightPolicy

risks_policies_filters_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/risks/policies/{id}/filters/

Body parameter

{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}
title: string
description: string
is_enabled: true
severity: 0
organization: 0

Parameters

Name In Type Required Description
id path integer true none
body body InsightPolicy true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Responses

Status Meaning Description Schema
200 OK none InsightPolicy

risks_policies_filters_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/{id}/filters/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/risks/policies/{id}/filters/

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

risks_policies_delete_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/risks/policies/delete/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/risks/policies/delete/

Body parameter

{
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "organization": 0
}
title: string
description: string
is_enabled: true
severity: 0
organization: 0

Parameters

Name In Type Required Description
body body InsightPolicy true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Responses

Status Meaning Description Schema
200 OK none InsightPolicy

risks_statistics_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/statistics/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/statistics/

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

risks_subtopics_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/subtopics/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/subtopics/

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "slug": "string",
      "description": "string",
      "is_available": true,
      "default_severity": 0,
      "security_check": 0,
      "remediation": "string",
      "remediation_effort": 0,
      "remediation_priority": 0
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedSubTopicList

risks_topics_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/risks/topics/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/risks/topics/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/topics/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/risks/topics/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/risks/topics/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/risks/topics/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/topics/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/risks/topics/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/risks/topics/

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "slug": "string",
      "is_available": true,
      "subtopics": [
        {
          "id": 0,
          "title": "string",
          "slug": "string",
          "description": "string",
          "is_available": true,
          "default_severity": 0,
          "security_check": 0,
          "remediation": "string",
          "remediation_effort": 0,
          "remediation_priority": 0
        }
      ]
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedTopicList

risks_vulns_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/risks/vulns/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/risks/vulns/

Body parameter

{
  "resourcetype": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "asset": {
    "value": "string",
    "is_monitored": true
  }
}
resourcetype: string
light_description: string
severity: 0
status: 0
asset:
  value: string
  is_monitored: true

Parameters

Name In Type Required Description
body body InsightPolymorphic false none

Example responses

200 Response

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Responses

Status Meaning Description Schema
200 OK none InsightPolymorphic

security-checks

security_checks_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/security-checks/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/security-checks/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/security-checks/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/security-checks/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/security-checks/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/security-checks/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/security-checks/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/security-checks/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/security-checks/

API endpoint that allows SecurityChecks to be viewed or edited.

Example responses

200 Response

[
  {
    "id": 0,
    "title": "string",
    "description": "string",
    "scan_type": "passive",
    "is_available": true,
    "is_auto": true,
    "latest_scans": "string",
    "vulnerabilities": "string",
    "webservers_required": true
  }
]

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [SecurityCheck] false none none
» id integer true read-only none
» title string true none none
» description string¦null false none none
» scan_type ScanTypeEnum false none * passive - Passive
* offensive - Offensive
» is_available boolean false none none
» is_auto boolean false none none
» latest_scans string true read-only none
» vulnerabilities string true read-only none
» webservers_required boolean true read-only none

Enumerated Values

Property Value
scan_type passive
scan_type offensive

get_security_check_specific_asset

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id} \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id} HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/security-checks/asset/{asset_id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/security-checks/asset/{asset_id}

API endpoint that allows SecurityChecks to be viewed or edited.

Parameters

Name In Type Required Description
asset_id path integer true none

Example responses

200 Response

{
  "id": 0,
  "title": "string",
  "description": "string",
  "scan_type": "passive",
  "is_available": true,
  "is_auto": true,
  "latest_scans": "string",
  "vulnerabilities": "string",
  "webservers_required": true
}

Responses

Status Meaning Description Schema
200 OK none SecurityCheck

security_checks_scans_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/security-checks/scans", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/security-checks/scans

API endpoint that allows SecurityChecks to be viewed or edited.

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "finished_at": "2019-08-24T14:15:22Z",
      "security_check": 0,
      "id": 0,
      "assets": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedScanInListList

suborgs

suborgs_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/suborgs/{id}/

Get details of an existing suborganization.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

suborgs_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/suborgs/{id}/

API endpoint that allows SubOrganizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
id path integer true none
body body SubOrganization true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

suborgs_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/suborgs/{id}/

API endpoint that allows SubOrganizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
id path integer true none
body body SubOrganization true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

suborgs_assetgroups_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/suborgs/{suborg_id}/assetgroups

API endpoint that allows SubOrganizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
suborg_id path integer true none
body body SubOrganization true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

suborgs_assetgroups_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assetgroups", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/suborgs/{suborg_id}/assetgroups

API endpoint that allows SubOrganizations to be viewed or edited.

Parameters

Name In Type Required Description
suborg_id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

suborgs_assets_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "name": "string",
  "parent": 0
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/suborgs/{suborg_id}/assets

API endpoint that allows SubOrganizations to be viewed or edited.

Body parameter

{
  "name": "string",
  "parent": 0
}
name: string
parent: 0

Parameters

Name In Type Required Description
suborg_id path integer true none
body body SubOrganization true none

Example responses

200 Response

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Responses

Status Meaning Description Schema
200 OK none SubOrganization

suborgs_assets_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/assets", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/suborgs/{suborg_id}/assets

API endpoint that allows SubOrganizations to be viewed or edited.

Parameters

Name In Type Required Description
suborg_id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

suborgs_users_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/suborgs/{suborg_id}/users/{id}/

Delete an existing SubOrganization user.

Parameters

Name In Type Required Description
id path integer true none
suborg_id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

suborgs_users_list_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/suborgs/{suborg_id}/users/list

API endpoint that allows suborganization users to be viewed or edited.

Parameters

Name In Type Required Description
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.
suborg_id path integer true none

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "organization": 0,
      "user": 0,
      "username": "string",
      "email": "string",
      "is_admin": true,
      "is_active": true,
      "org_name": "string",
      "role": 0
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedSubOrganizationUserList

suborgs_users_list_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "user_ids": [
    0
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/suborgs/{suborg_id}/users/list

Add one or several existing user to suborganization

Body parameter

{
  "user_ids": [
    0
  ]
}
user_ids:
  - 0

Parameters

Name In Type Required Description
suborg_id path integer true none
body body SubOrganizationUser true none

Example responses

201 Response

{
  "id": 0,
  "organization": 0,
  "user": 0,
  "username": "string",
  "email": "string",
  "is_admin": true,
  "is_active": true,
  "org_name": "string",
  "role": 0
}

Responses

Status Meaning Description Schema
201 Created none SubOrganizationUser

suborgs_users_list_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/suborgs/{suborg_id}/users/list", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/suborgs/{suborg_id}/users/list

Remove one or several users from suborganization

Parameters

Name In Type Required Description
suborg_id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

tickets

tickets_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/tickets/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/tickets/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/tickets/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/tickets/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/tickets/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/tickets/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/tickets/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/tickets/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/tickets/

API endpoint that allows Tickets to be viewed or edited.

Parameters

Name In Type Required Description
created_at query string(date-time) false none
id query integer false none
limit query integer false Number of results to return per page.
page query integer false A page number within the paginated result set.
sorted_by query array[string] false Ordering
status query integer false * 0 - Unknown
status_name query string false none
updated_at query string(date-time) false none

Detailed descriptions

sorted_by: Ordering

status: * 0 - Unknown * 1 - New * 2 - In Progress * 3 - On Hold * 4 - Resolved * 5 - Closed * 6 - Canceled

Enumerated Values

Parameter Value
sorted_by -created_at
sorted_by -id
sorted_by -status
sorted_by -updated_at
sorted_by created_at
sorted_by id
sorted_by status
sorted_by updated_at
status 0
status 1
status 2
status 3
status 4
status 5
status 6

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "identifier": "string",
      "status": 0,
      "status_name": "string",
      "link": "string",
      "last_checked_at": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedTicketList

tickets_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/tickets/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/tickets/{id}/

API endpoint that allows Tickets to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "identifier": "string",
  "status": 0,
  "status_name": "string",
  "link": "string",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Ticket

user

user_current_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/user/current \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/user/current HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/current',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/user/current',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/user/current', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/user/current', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/current");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/user/current", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/user/current

Handle the GET method.

Responses

Status Meaning Description Schema
200 OK No response body None

user_current_password_change_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/user/current/password_change", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/user/current/password_change

Update the user's password. Keycloak will send an email to the user

:return 400 - Error during the request to keycloak

:return 200 - Password change

Responses

Status Meaning Description Schema
200 OK No response body None

renew_my_otp

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/user/current/renew_otp", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/user/current/renew_otp

Renew user's password.

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage

toggle_email_type

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/user/current/subscribe-to-email", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/user/current/subscribe-to-email

Change subscription email

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage

user_current_update_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/user/current/update \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/user/current/update HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/current/update',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/user/current/update',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/user/current/update', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/user/current/update', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/current/update");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/user/current/update", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/user/current/update

Update the user's information (LastName / FirstName).

:return: 400 - No data or Invalid Data

:return: 200 - Success

Responses

Status Meaning Description Schema
200 OK No response body None

user_set_org_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/user/set-org \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/user/set-org HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/set-org',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/user/set-org',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/user/set-org', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/user/set-org', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/set-org");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/user/set-org", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/user/set-org

Set organization.

Responses

Status Meaning Description Schema
200 OK No response body None

user_setdefaultorg_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/user/setdefaultorg", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/user/setdefaultorg

Set the default user's organization.

Responses

Status Meaning Description Schema
200 OK No response body None

user_token_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/user/token \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/user/token HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/token',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/user/token',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/user/token', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/user/token', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/token");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/user/token", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/user/token

Responses

Status Meaning Description Schema
200 OK No response body None

user_token_delete_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/user/token/delete \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/user/token/delete HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/token/delete',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/user/token/delete',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/user/token/delete', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/user/token/delete', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/token/delete");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/user/token/delete", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/user/token/delete

Responses

Status Meaning Description Schema
204 No Content No response body None

user_token_generate_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/user/token/generate \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/user/token/generate HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/user/token/generate',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/user/token/generate',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/user/token/generate', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/user/token/generate', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/user/token/generate");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/user/token/generate", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/user/token/generate

Responses

Status Meaning Description Schema
200 OK No response body None

users

users_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/users/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/users/

API endpoint that allows Users to be viewed or edited.

Parameters

Name In Type Required Description
email query string false none
first_name query string false none
id query integer false none
is_active query boolean false none
is_asset_group_owner query boolean false none
is_asset_owner query boolean false none
is_vuln_owner query boolean false none
is_vuln_solution_owner query boolean false none
last_name query string false none
limit query integer false Number of results to return per page.
org_id query string false none
page query integer false A page number within the paginated result set.
role query string false none
search query string false none
sorted_by query array[string] false Ordering
suborg_ids query string false Comma separated list of suborganization IDs
suborg_not query string false none
username query string false none

Detailed descriptions

sorted_by: Ordering

Enumerated Values

Parameter Value
sorted_by -can_be_owner
sorted_by -email
sorted_by -first_name
sorted_by -id
sorted_by -is_active
sorted_by -last_login
sorted_by -last_name
sorted_by -role
sorted_by -suborgs
sorted_by -username
sorted_by can_be_owner
sorted_by email
sorted_by first_name
sorted_by id
sorted_by is_active
sorted_by last_login
sorted_by last_name
sorted_by role
sorted_by suborgs
sorted_by username

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "username": "string",
      "first_name": "string",
      "last_name": "string",
      "email": "user@example.com",
      "last_login": "2019-08-24T14:15:22Z",
      "is_superuser": true,
      "is_staff": true,
      "is_active": true,
      "changed_first_password": true,
      "orgs": {
        "property1": null,
        "property2": null
      },
      "current_org": {
        "property1": null,
        "property2": null
      },
      "is_org_admin": true,
      "role": 2,
      "auth_token": "string",
      "dark_mode": true,
      "suborgs": {
        "property1": null,
        "property2": null
      },
      "asset_assets": "string",
      "assetgroup_assetgroups": "string",
      "vulnerability_vulnerabilities": "string",
      "from_sso": true,
      "emails_subscribed": "string",
      "intercom": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedUserList

users_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/users/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/users/

API endpoint that allows Users to be viewed or edited.

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
body body User true none

Example responses

201 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
201 Created none User

users_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/users/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/users/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/users/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/users/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/users/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/users/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/users/

API endpoint that allows Users to be viewed or edited.

Responses

Status Meaning Description Schema
204 No Content No response body None

users_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/users/{id}/

API endpoint that allows Users to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_create_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/users/{id}/

API endpoint that allows Users to be viewed or edited.

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
id path integer true none
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/users/{id}/

API endpoint that allows Users to be viewed or edited.

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
id path integer true none
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_destroy_2

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/users/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/users/{id}/

API endpoint that allows Users to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

users_create_3

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type} HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/users/{id}/{object_type}

Add ownership on several assets

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
id path integer true none
object_type path string true none
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_destroy_3

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type} \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type} HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/{object_type}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/users/{id}/{object_type}

Add ownership on several assets

Parameters

Name In Type Required Description
id path integer true none
object_type path string true none

Responses

Status Meaning Description Schema
204 No Content No response body None

users_deactivate_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/deactivate", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/users/{id}/deactivate

Blocked a User

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
id path integer true none
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

user_renew_otp

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/new-otp", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/users/{id}/new-otp

Renew user's OTP.

Parameters

Name In Type Required Description
id path integer true none

Example responses

404 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

users_newpwd_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/newpwd", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/users/{id}/newpwd

Renew user's password.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_subscribe_mail_update

Code samples

# You can also use wget
curl -X PUT https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PUT https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.put 'https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.put('https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://dashboard.cloud.patrowl.io/api/auth/users/{id}/subscribe-mail", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /api/auth/users/{id}/subscribe-mail

API endpoint that allows Users to be viewed or edited.

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
id path integer true none
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_darkmode_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/users/darkmode \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/users/darkmode HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/darkmode',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/users/darkmode',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/users/darkmode', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/users/darkmode', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/darkmode");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/users/darkmode", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/users/darkmode

Retrieve user's preference for dark mode.

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_darkmode_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/users/darkmode \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/users/darkmode HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/darkmode',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/users/darkmode',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/users/darkmode', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/users/darkmode', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/darkmode");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/users/darkmode", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/users/darkmode

Toggle user's preference for dark mode.

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_export_csv_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/users/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/users/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/users/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/users/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/users/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/users/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/users/export/csv

API endpoint that allows Users to be viewed or edited.

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_export_csv_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/users/export/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/users/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/export/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/users/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/users/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/users/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/users/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/users/export/csv

API endpoint that allows Users to be viewed or edited.

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

users_import_csv_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/users/import/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/users/import/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/users/import/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/users/import/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/users/import/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/users/import/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/users/import/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/users/import/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/users/import/csv

API endpoint that allows Users to be viewed or edited.

Body parameter

{
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "role": 2
}
username: string
first_name: string
last_name: string
email: user@example.com
role: 2

Parameters

Name In Type Required Description
body body User true none

Example responses

200 Response

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Responses

Status Meaning Description Schema
200 OK none User

vulns

vulns_list

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/

API endpoint that allows Vulnerabilities to be viewed or edited.

Parameters

Name In Type Required Description
accessible_by_users query array[number] false Multiple values may be separated by commas.
after query string(date-time) false none
asset__type query string false * ip - ip
asset__value query string false none
asset_value_icontains query string false none
asset_group_id query number false none
asset_id query number false none
asset_type query string false none
asset_value query string false none
assets_id query string false none
before query string(date-time) false none
campaign query string false none
created_at query string(date-time) false none
created_at__gte query string(date-time) false none
created_at__lte query string(date-time) false none
id query integer false none
insight_policy query string false none
is_auto query boolean false none
is_greybox query boolean false none
limit query integer false Number of results to return per page.
not_remediation_id query string false none
not_vuln_owner query string false none
not_vuln_solution_owner query string false none
org query string false none
page query integer false A page number within the paginated result set.
remediation_id query string false none
reteststatus query array[string] false Multiple values may be separated by commas.
search query string false none
security_check query string false none
severity query integer false * 0 - Info
solution__icontains query string false none
solution_effort query string false * low - Low
solution_gain query integer false none
solution_gain__gte query integer false none
solution_gain__lte query integer false none
solution_headline query string false none
solution_headline__icontains query string false none
solution_priority query string false * urgent - Urgent
sorted_by query array[string] false Ordering
source query string false none
status query string false * new - New
status__icontains query string false none
suborgs query string false none
ticketstatus query integer false none
title query string false none
title__icontains query string false none
user_friendly_id query string false none
user_friendly_id__icontains query string false none
vuln_owners query string false none
vuln_solution_owners query string false none

Detailed descriptions

asset__type: * ip - ip * ip-range - ip-range * ip-subnet - ip-subnet * fqdn - fqdn * domain - domain * keyword - keyword * other - other

severity: * 0 - Info * 1 - Low * 2 - Medium * 3 - High * 4 - Critical

solution_effort: * low - Low * medium - Medium * high - High

solution_priority: * urgent - Urgent * moderate - Moderate * hardening - Hardening

sorted_by: Ordering

status: * new - New * ack - Acknowledged * assigned - Assigned * patched - Patched * closed - Closed * closed-benign - Closed (Benign) * closed-fp - Closed (False-Positive) * closed-duplicate - Closed (Duplicate) * closed-workaround - Closed (Workaround) * closed-risk-acceptance - Closed (Risk acceptance)

Enumerated Values

Parameter Value
asset__type domain
asset__type fqdn
asset__type ip
asset__type ip-range
asset__type ip-subnet
asset__type keyword
asset__type other
severity 0
severity 1
severity 2
severity 3
severity 4
solution_effort high
solution_effort low
solution_effort medium
solution_priority hardening
solution_priority moderate
solution_priority urgent
sorted_by -asset_value
sorted_by -created_at
sorted_by -description
sorted_by -id
sorted_by -last_status_update
sorted_by -remediation_date
sorted_by -severity
sorted_by -solution
sorted_by -solution_duedate
sorted_by -solution_effort
sorted_by -solution_gain
sorted_by -solution_headline
sorted_by -solution_priority
sorted_by -source
sorted_by -status
sorted_by -ticketstatus
sorted_by -title
sorted_by -updated_at
sorted_by -user_friendly_id
sorted_by -vuln_owners
sorted_by -vuln_solution_owners
sorted_by asset_value
sorted_by created_at
sorted_by description
sorted_by id
sorted_by last_status_update
sorted_by remediation_date
sorted_by severity
sorted_by solution
sorted_by solution_duedate
sorted_by solution_effort
sorted_by solution_gain
sorted_by solution_headline
sorted_by solution_priority
sorted_by source
sorted_by status
sorted_by ticketstatus
sorted_by title
sorted_by updated_at
sorted_by user_friendly_id
sorted_by vuln_owners
sorted_by vuln_solution_owners
status ack
status assigned
status closed
status closed-benign
status closed-duplicate
status closed-fp
status closed-risk-acceptance
status closed-workaround
status new
status patched

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "user_friendly_id": "string",
      "description": "string",
      "solution_headline": "string",
      "solution_priority": "urgent",
      "solution_effort": "low",
      "solution_gain": -2147483648,
      "is_quickwin": true,
      "title": "string",
      "source": "string",
      "status": "new",
      "severity": 0,
      "asset_id": "string",
      "asset_value": "string",
      "asset_criticality": "string",
      "vuln_owners": "string",
      "vuln_solution_owners": "string",
      "asset": 0,
      "reteststatus": "string",
      "ticketstatus": -2147483648,
      "is_retestable": true,
      "last_ticket": "string",
      "solution_duedate": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedVulnerabilityLiteList

vulns_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/vulns/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/vulns/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/vulns/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/vulns/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/vulns/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/vulns/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/vulns/

API endpoint that allows Vulnerabilities to be viewed or edited.

Body parameter

{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}
patrowl_id: -2147483648
asset: 0
organization: 0
severity: 0
cvss_vector: string
status: new
title: string
description: string
source: string
external_id: null
category: string
business_impacts:
  - string
has_exploit: true
solution_headline: string
solution: string
solution_priority: urgent
solution_effort: low
solution_gain: -2147483648
owners:
  - 0
solution_duedate: 2019-08-24T14:15:22Z
is_quickwin: true
is_auto: true
is_greybox: true
remediation_date: 2019-08-24T14:15:22Z
last_status_update: 2019-08-24T14:15:22Z
found_at: 2019-08-24T14:15:22Z
last_checked_at: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
ticketstatus: -2147483648
solution_owners:
  - 0
updated_by_user_at: 2019-08-24T14:15:22Z

Parameters

Name In Type Required Description
body body Vulnerability true none

Example responses

201 Response

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
201 Created none Vulnerability

vulnerabilities_bulk_update_vulns_status

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/vulns/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/vulns/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "vulnerabilities_id": [
    null
  ],
  "status": "new"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/vulns/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/vulns/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/vulns/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/vulns/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/vulns/

Update several status

:return 400: Invalid data

:return 200: Success

Body parameter

{
  "vulnerabilities_id": [
    null
  ],
  "status": "new"
}
vulnerabilities_id:
  - null
status: new

Parameters

Name In Type Required Description
body body Patchedbulk_update_vulns_status false none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage

vulns_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/vulns/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/vulns/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/vulns/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/vulns/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/vulns/

Delete Several Vulns from list

:param vulns_id: List with all the IDs to delete

:return 400: vulns_id field is required

:return 400: vulns_id must be a list of integers

:return 400: No vulns with this or these IDs

:return 204: Success

Responses

Status Meaning Description Schema
204 No Content No response body None

vulns_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/{id}/

API endpoint that allows Vulnerabilities to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Vulnerability

vulns_partial_update

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/ \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/vulns/{id}/

API endpoint that allows Vulnerabilities to be viewed or edited.

Body parameter

{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}
patrowl_id: -2147483648
asset: 0
organization: 0
severity: 0
cvss_vector: string
status: new
title: string
description: string
source: string
external_id: null
category: string
business_impacts:
  - string
has_exploit: true
solution_headline: string
solution: string
solution_priority: urgent
solution_effort: low
solution_gain: -2147483648
owners:
  - 0
solution_duedate: 2019-08-24T14:15:22Z
is_quickwin: true
is_auto: true
is_greybox: true
remediation_date: 2019-08-24T14:15:22Z
last_status_update: 2019-08-24T14:15:22Z
found_at: 2019-08-24T14:15:22Z
last_checked_at: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
ticketstatus: -2147483648
solution_owners:
  - 0
updated_by_user_at: 2019-08-24T14:15:22Z

Parameters

Name In Type Required Description
id path integer true none
body body PatchedVulnerability false none

Example responses

200 Response

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Vulnerability

vulns_destroy_2

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/ \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/vulns/{id}/

API endpoint that allows Vulnerabilities to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

vulnerabilities_upload_file_attachments

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "title": "string",
  "file": "http://example.com"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/attachements", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/vulns/{id}/attachements

Upload file attachments

:return 404: Vuln not found

:return 400: Invalid file or title

:return 201: Vulnerabiltiy Attachment upload

Body parameter

{
  "title": "string",
  "file": "http://example.com"
}
title: string
file: http://example.com

Parameters

Name In Type Required Description
id path integer true none
body body upload_file_attachements true none

Example responses

201 Response

{
  "status": "string"
}

Responses

Status Meaning Description Schema
201 Created none BasicResponse
400 Bad Request none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_create_comment

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/vulns/{id}/comments

Add a new comments.

:return 404: Vuln not found

:return 201: Success

Body parameter

{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}
patrowl_id: -2147483648
asset: 0
organization: 0
severity: 0
cvss_vector: string
status: new
title: string
description: string
source: string
external_id: null
category: string
business_impacts:
  - string
has_exploit: true
solution_headline: string
solution: string
solution_priority: urgent
solution_effort: low
solution_gain: -2147483648
owners:
  - 0
solution_duedate: 2019-08-24T14:15:22Z
is_quickwin: true
is_auto: true
is_greybox: true
remediation_date: 2019-08-24T14:15:22Z
last_status_update: 2019-08-24T14:15:22Z
found_at: 2019-08-24T14:15:22Z
last_checked_at: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
ticketstatus: -2147483648
solution_owners:
  - 0
updated_by_user_at: 2019-08-24T14:15:22Z

Parameters

Name In Type Required Description
id path integer true none
body body Vulnerability true none

Example responses

201 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
201 Created none Inline
404 Not Found none Inline

Response Schema

Status Code 201

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_edit_comment

Code samples

# You can also use wget
curl -X PATCH https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

PATCH https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id} HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id}',
{
  method: 'PATCH',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.patch 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.patch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id}', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/comments/{comment_id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /api/auth/vulns/{id}/comments/{comment_id}

Edit an existing comments.

:return 404: Vuln or comment not found

:return 201: Success

Body parameter

{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}
patrowl_id: -2147483648
asset: 0
organization: 0
severity: 0
cvss_vector: string
status: new
title: string
description: string
source: string
external_id: null
category: string
business_impacts:
  - string
has_exploit: true
solution_headline: string
solution: string
solution_priority: urgent
solution_effort: low
solution_gain: -2147483648
owners:
  - 0
solution_duedate: 2019-08-24T14:15:22Z
is_quickwin: true
is_auto: true
is_greybox: true
remediation_date: 2019-08-24T14:15:22Z
last_status_update: 2019-08-24T14:15:22Z
found_at: 2019-08-24T14:15:22Z
last_checked_at: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
ticketstatus: -2147483648
solution_owners:
  - 0
updated_by_user_at: 2019-08-24T14:15:22Z

Parameters

Name In Type Required Description
comment_id path integer true none
id path integer true none
body body PatchedVulnerability false none

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline
404 Not Found none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_list_events

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/events", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/{id}/events

List related events.

:return 404: Vuln not found

:return 200: Success

Parameters

Name In Type Required Description
accessible_by_users query array[number] false Multiple values may be separated by commas.
after query string(date-time) false none
asset__type query string false * ip - ip
asset__value query string false none
asset_value_icontains query string false none
asset_group_id query number false none
asset_id query number false none
asset_type query string false none
asset_value query string false none
assets_id query string false none
before query string(date-time) false none
campaign query string false none
created_at query string(date-time) false none
created_at__gte query string(date-time) false none
created_at__lte query string(date-time) false none
id path integer true none
id query integer false none
insight_policy query string false none
is_auto query boolean false none
is_greybox query boolean false none
limit query integer false Number of results to return per page.
not_remediation_id query string false none
not_vuln_owner query string false none
not_vuln_solution_owner query string false none
org query string false none
page query integer false A page number within the paginated result set.
remediation_id query string false none
reteststatus query array[string] false Multiple values may be separated by commas.
search query string false none
security_check query string false none
severity query integer false * 0 - Info
solution__icontains query string false none
solution_effort query string false * low - Low
solution_gain query integer false none
solution_gain__gte query integer false none
solution_gain__lte query integer false none
solution_headline query string false none
solution_headline__icontains query string false none
solution_priority query string false * urgent - Urgent
sorted_by query array[string] false Ordering
source query string false none
status query string false * new - New
status__icontains query string false none
suborgs query string false none
ticketstatus query integer false none
title query string false none
title__icontains query string false none
user_friendly_id query string false none
user_friendly_id__icontains query string false none
vuln_owners query string false none
vuln_solution_owners query string false none

Detailed descriptions

asset__type: * ip - ip * ip-range - ip-range * ip-subnet - ip-subnet * fqdn - fqdn * domain - domain * keyword - keyword * other - other

severity: * 0 - Info * 1 - Low * 2 - Medium * 3 - High * 4 - Critical

solution_effort: * low - Low * medium - Medium * high - High

solution_priority: * urgent - Urgent * moderate - Moderate * hardening - Hardening

sorted_by: Ordering

status: * new - New * ack - Acknowledged * assigned - Assigned * patched - Patched * closed - Closed * closed-benign - Closed (Benign) * closed-fp - Closed (False-Positive) * closed-duplicate - Closed (Duplicate) * closed-workaround - Closed (Workaround) * closed-risk-acceptance - Closed (Risk acceptance)

Enumerated Values

Parameter Value
asset__type domain
asset__type fqdn
asset__type ip
asset__type ip-range
asset__type ip-subnet
asset__type keyword
asset__type other
severity 0
severity 1
severity 2
severity 3
severity 4
solution_effort high
solution_effort low
solution_effort medium
solution_priority hardening
solution_priority moderate
solution_priority urgent
sorted_by -asset_value
sorted_by -created_at
sorted_by -description
sorted_by -id
sorted_by -last_status_update
sorted_by -remediation_date
sorted_by -severity
sorted_by -solution
sorted_by -solution_duedate
sorted_by -solution_effort
sorted_by -solution_gain
sorted_by -solution_headline
sorted_by -solution_priority
sorted_by -source
sorted_by -status
sorted_by -ticketstatus
sorted_by -title
sorted_by -updated_at
sorted_by -user_friendly_id
sorted_by -vuln_owners
sorted_by -vuln_solution_owners
sorted_by asset_value
sorted_by created_at
sorted_by description
sorted_by id
sorted_by last_status_update
sorted_by remediation_date
sorted_by severity
sorted_by solution
sorted_by solution_duedate
sorted_by solution_effort
sorted_by solution_gain
sorted_by solution_headline
sorted_by solution_priority
sorted_by source
sorted_by status
sorted_by ticketstatus
sorted_by title
sorted_by updated_at
sorted_by user_friendly_id
sorted_by vuln_owners
sorted_by vuln_solution_owners
status ack
status assigned
status closed
status closed-benign
status closed-duplicate
status closed-fp
status closed-risk-acceptance
status closed-workaround
status new
status patched

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "message": "string",
      "author": "user@example.com",
      "text": "string",
      "scope": "string",
      "updated_at": "2019-08-24T14:15:22Z",
      "is_editable": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedEventCommentList
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulns_owners_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/vulns/{id}/owners

API endpoint that allows Vulnerabilities to be viewed or edited.

Body parameter

{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}
patrowl_id: -2147483648
asset: 0
organization: 0
severity: 0
cvss_vector: string
status: new
title: string
description: string
source: string
external_id: null
category: string
business_impacts:
  - string
has_exploit: true
solution_headline: string
solution: string
solution_priority: urgent
solution_effort: low
solution_gain: -2147483648
owners:
  - 0
solution_duedate: 2019-08-24T14:15:22Z
is_quickwin: true
is_auto: true
is_greybox: true
remediation_date: 2019-08-24T14:15:22Z
last_status_update: 2019-08-24T14:15:22Z
found_at: 2019-08-24T14:15:22Z
last_checked_at: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
ticketstatus: -2147483648
solution_owners:
  - 0
updated_by_user_at: 2019-08-24T14:15:22Z

Parameters

Name In Type Required Description
id path integer true none
body body Vulnerability true none

Example responses

200 Response

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Vulnerability

vulns_owners_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/vulns/{id}/owners

API endpoint that allows Vulnerabilities to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

vulnerabilties_get_periodic_retest

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/periodic-retest", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/{id}/periodic-retest

List related retests.

:return 404: Vuln not found

:return 400: Vuln already fix

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline
404 Not Found none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_list_retests

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/{id}/retests

List related retests.

:return 404: Vuln not found

:return 200: Success

Parameters

Name In Type Required Description
accessible_by_users query array[number] false Multiple values may be separated by commas.
after query string(date-time) false none
asset__type query string false * ip - ip
asset__value query string false none
asset_value_icontains query string false none
asset_group_id query number false none
asset_id query number false none
asset_type query string false none
asset_value query string false none
assets_id query string false none
before query string(date-time) false none
campaign query string false none
created_at query string(date-time) false none
created_at__gte query string(date-time) false none
created_at__lte query string(date-time) false none
id path integer true none
id query integer false none
insight_policy query string false none
is_auto query boolean false none
is_greybox query boolean false none
limit query integer false Number of results to return per page.
not_remediation_id query string false none
not_vuln_owner query string false none
not_vuln_solution_owner query string false none
org query string false none
page query integer false A page number within the paginated result set.
remediation_id query string false none
reteststatus query array[string] false Multiple values may be separated by commas.
search query string false none
security_check query string false none
severity query integer false * 0 - Info
solution__icontains query string false none
solution_effort query string false * low - Low
solution_gain query integer false none
solution_gain__gte query integer false none
solution_gain__lte query integer false none
solution_headline query string false none
solution_headline__icontains query string false none
solution_priority query string false * urgent - Urgent
sorted_by query array[string] false Ordering
source query string false none
status query string false * new - New
status__icontains query string false none
suborgs query string false none
ticketstatus query integer false none
title query string false none
title__icontains query string false none
user_friendly_id query string false none
user_friendly_id__icontains query string false none
vuln_owners query string false none
vuln_solution_owners query string false none

Detailed descriptions

asset__type: * ip - ip * ip-range - ip-range * ip-subnet - ip-subnet * fqdn - fqdn * domain - domain * keyword - keyword * other - other

severity: * 0 - Info * 1 - Low * 2 - Medium * 3 - High * 4 - Critical

solution_effort: * low - Low * medium - Medium * high - High

solution_priority: * urgent - Urgent * moderate - Moderate * hardening - Hardening

sorted_by: Ordering

status: * new - New * ack - Acknowledged * assigned - Assigned * patched - Patched * closed - Closed * closed-benign - Closed (Benign) * closed-fp - Closed (False-Positive) * closed-duplicate - Closed (Duplicate) * closed-workaround - Closed (Workaround) * closed-risk-acceptance - Closed (Risk acceptance)

Enumerated Values

Parameter Value
asset__type domain
asset__type fqdn
asset__type ip
asset__type ip-range
asset__type ip-subnet
asset__type keyword
asset__type other
severity 0
severity 1
severity 2
severity 3
severity 4
solution_effort high
solution_effort low
solution_effort medium
solution_priority hardening
solution_priority moderate
solution_priority urgent
sorted_by -asset_value
sorted_by -created_at
sorted_by -description
sorted_by -id
sorted_by -last_status_update
sorted_by -remediation_date
sorted_by -severity
sorted_by -solution
sorted_by -solution_duedate
sorted_by -solution_effort
sorted_by -solution_gain
sorted_by -solution_headline
sorted_by -solution_priority
sorted_by -source
sorted_by -status
sorted_by -ticketstatus
sorted_by -title
sorted_by -updated_at
sorted_by -user_friendly_id
sorted_by -vuln_owners
sorted_by -vuln_solution_owners
sorted_by asset_value
sorted_by created_at
sorted_by description
sorted_by id
sorted_by last_status_update
sorted_by remediation_date
sorted_by severity
sorted_by solution
sorted_by solution_duedate
sorted_by solution_effort
sorted_by solution_gain
sorted_by solution_headline
sorted_by solution_priority
sorted_by source
sorted_by status
sorted_by ticketstatus
sorted_by title
sorted_by updated_at
sorted_by user_friendly_id
sorted_by vuln_owners
sorted_by vuln_solution_owners
status ack
status assigned
status closed
status closed-benign
status closed-duplicate
status closed-fp
status closed-risk-acceptance
status closed-workaround
status new
status patched

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "patrowl_id": 0,
      "vulnerability": 0,
      "status": "none",
      "comments": "string",
      "requested_by": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "is_auto": true
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedRetestList
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_add_retest

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/retests/add", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/{id}/retests/add

Add retest for one vulnerabiltiy

:return 403: Organization is a poc

:return 404: Vuln not foud

:return 429: Too much manual retest / Auto Retest already exist

:return 200: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

400 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage
404 Not Found none Inline
429 Too Many Requests none BasicResponseWithMessage

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulns_solution_owners_create

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/vulns/{id}/solution-owners

API endpoint that allows Vulnerabilities to be viewed or edited.

Body parameter

{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}
patrowl_id: -2147483648
asset: 0
organization: 0
severity: 0
cvss_vector: string
status: new
title: string
description: string
source: string
external_id: null
category: string
business_impacts:
  - string
has_exploit: true
solution_headline: string
solution: string
solution_priority: urgent
solution_effort: low
solution_gain: -2147483648
owners:
  - 0
solution_duedate: 2019-08-24T14:15:22Z
is_quickwin: true
is_auto: true
is_greybox: true
remediation_date: 2019-08-24T14:15:22Z
last_status_update: 2019-08-24T14:15:22Z
found_at: 2019-08-24T14:15:22Z
last_checked_at: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
ticketstatus: -2147483648
solution_owners:
  - 0
updated_by_user_at: 2019-08-24T14:15:22Z

Parameters

Name In Type Required Description
id path integer true none
body body Vulnerability true none

Example responses

200 Response

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Vulnerability

vulns_solution_owners_destroy

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/solution-owners", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/vulns/{id}/solution-owners

API endpoint that allows Vulnerabilities to be viewed or edited.

Parameters

Name In Type Required Description
id path integer true none

Responses

Status Meaning Description Schema
204 No Content No response body None

vulnerabilities_list_tickets

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{id}/tickets", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/{id}/tickets

List related tickets.

:return 404: Vuln not found

:return 200: Success

Parameters

Name In Type Required Description
accessible_by_users query array[number] false Multiple values may be separated by commas.
after query string(date-time) false none
asset__type query string false * ip - ip
asset__value query string false none
asset_value_icontains query string false none
asset_group_id query number false none
asset_id query number false none
asset_type query string false none
asset_value query string false none
assets_id query string false none
before query string(date-time) false none
campaign query string false none
created_at query string(date-time) false none
created_at__gte query string(date-time) false none
created_at__lte query string(date-time) false none
id path integer true none
id query integer false none
insight_policy query string false none
is_auto query boolean false none
is_greybox query boolean false none
limit query integer false Number of results to return per page.
not_remediation_id query string false none
not_vuln_owner query string false none
not_vuln_solution_owner query string false none
org query string false none
page query integer false A page number within the paginated result set.
remediation_id query string false none
reteststatus query array[string] false Multiple values may be separated by commas.
search query string false none
security_check query string false none
severity query integer false * 0 - Info
solution__icontains query string false none
solution_effort query string false * low - Low
solution_gain query integer false none
solution_gain__gte query integer false none
solution_gain__lte query integer false none
solution_headline query string false none
solution_headline__icontains query string false none
solution_priority query string false * urgent - Urgent
sorted_by query array[string] false Ordering
source query string false none
status query string false * new - New
status__icontains query string false none
suborgs query string false none
ticketstatus query integer false none
title query string false none
title__icontains query string false none
user_friendly_id query string false none
user_friendly_id__icontains query string false none
vuln_owners query string false none
vuln_solution_owners query string false none

Detailed descriptions

asset__type: * ip - ip * ip-range - ip-range * ip-subnet - ip-subnet * fqdn - fqdn * domain - domain * keyword - keyword * other - other

severity: * 0 - Info * 1 - Low * 2 - Medium * 3 - High * 4 - Critical

solution_effort: * low - Low * medium - Medium * high - High

solution_priority: * urgent - Urgent * moderate - Moderate * hardening - Hardening

sorted_by: Ordering

status: * new - New * ack - Acknowledged * assigned - Assigned * patched - Patched * closed - Closed * closed-benign - Closed (Benign) * closed-fp - Closed (False-Positive) * closed-duplicate - Closed (Duplicate) * closed-workaround - Closed (Workaround) * closed-risk-acceptance - Closed (Risk acceptance)

Enumerated Values

Parameter Value
asset__type domain
asset__type fqdn
asset__type ip
asset__type ip-range
asset__type ip-subnet
asset__type keyword
asset__type other
severity 0
severity 1
severity 2
severity 3
severity 4
solution_effort high
solution_effort low
solution_effort medium
solution_priority hardening
solution_priority moderate
solution_priority urgent
sorted_by -asset_value
sorted_by -created_at
sorted_by -description
sorted_by -id
sorted_by -last_status_update
sorted_by -remediation_date
sorted_by -severity
sorted_by -solution
sorted_by -solution_duedate
sorted_by -solution_effort
sorted_by -solution_gain
sorted_by -solution_headline
sorted_by -solution_priority
sorted_by -source
sorted_by -status
sorted_by -ticketstatus
sorted_by -title
sorted_by -updated_at
sorted_by -user_friendly_id
sorted_by -vuln_owners
sorted_by -vuln_solution_owners
sorted_by asset_value
sorted_by created_at
sorted_by description
sorted_by id
sorted_by last_status_update
sorted_by remediation_date
sorted_by severity
sorted_by solution
sorted_by solution_duedate
sorted_by solution_effort
sorted_by solution_gain
sorted_by solution_headline
sorted_by solution_priority
sorted_by source
sorted_by status
sorted_by ticketstatus
sorted_by title
sorted_by updated_at
sorted_by user_friendly_id
sorted_by vuln_owners
sorted_by vuln_solution_owners
status ack
status assigned
status closed
status closed-benign
status closed-duplicate
status closed-fp
status closed-risk-acceptance
status closed-workaround
status new
status patched

Example responses

200 Response

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "identifier": "string",
      "status": 0,
      "status_name": "string",
      "link": "string",
      "last_checked_at": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK none PaginatedTicketList
404 Not Found none Inline

Response Schema

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulns_retrieve_2

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/{user_friendly_id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/{user_friendly_id}/

API endpoint that allows Vulnerabilities to be viewed or edited.

Parameters

Name In Type Required Description
user_friendly_id path string true none

Example responses

200 Response

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Responses

Status Meaning Description Schema
200 OK none Vulnerability

vulnerabilities_delete_file_attachments

Code samples

# You can also use wget
curl -X DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/ \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

DELETE https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/ HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.delete 'https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.delete('https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://dashboard.cloud.patrowl.io/api/auth/vulns/attachements/{id}/", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /api/auth/vulns/attachements/{id}/

Delete file link to a vulnerability

:return 404: File not found

:return 403: Unauthorized to delete file upload by Patrowl

:return 400: Unable to delete this file

:return 204: Success

Parameters

Name In Type Required Description
id path integer true none

Example responses

204 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
204 No Content none Inline
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage
404 Not Found none Inline

Response Schema

Status Code 204

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

Status Code 404

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_efforts

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/by-efforts", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/by-efforts

Recommendations by effort Data corresponding to the recommendations total on each effort types

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_priorities

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/by-priorities", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/by-priorities

Recommendations by priority data corresponding to the recommendations total on each priority types

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_severity_and_time

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/by-severity-and-time", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/by-severity-and-time

Overdues recommendations by severity and time data corresponding to the recommendations total on each severity types & time

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_status_vuln

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/by-vulns-status", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/by-vulns-status

Data corresponding to the total recomm on each effort types.

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_export_csv

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/export/csv

Export vulnerabilities as CSV.

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_export_csv_2

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/vulns/export/csv", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/vulns/export/csv

Export vulnerabilities as CSV.

Body parameter

{
  "patrowl_id": -2147483648,
  "asset": 0,
  "organization": 0,
  "severity": 0,
  "cvss_vector": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "ticketstatus": -2147483648,
  "solution_owners": [
    0
  ],
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}
patrowl_id: -2147483648
asset: 0
organization: 0
severity: 0
cvss_vector: string
status: new
title: string
description: string
source: string
external_id: null
category: string
business_impacts:
  - string
has_exploit: true
solution_headline: string
solution: string
solution_priority: urgent
solution_effort: low
solution_gain: -2147483648
owners:
  - 0
solution_duedate: 2019-08-24T14:15:22Z
is_quickwin: true
is_auto: true
is_greybox: true
remediation_date: 2019-08-24T14:15:22Z
last_status_update: 2019-08-24T14:15:22Z
found_at: 2019-08-24T14:15:22Z
last_checked_at: 2019-08-24T14:15:22Z
created_at: 2019-08-24T14:15:22Z
updated_at: 2019-08-24T14:15:22Z
ticketstatus: -2147483648
solution_owners:
  - 0
updated_by_user_at: 2019-08-24T14:15:22Z

Parameters

Name In Type Required Description
body body Vulnerability true none

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_bulk_remove_owners

Code samples

# You can also use wget
curl -X POST https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

POST https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear HTTP/1.1
Host: dashboard.cloud.patrowl.io
Content-Type: application/json
Accept: application/json

const inputBody = '{
  "ids": [
    null
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.post 'https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.post('https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Content-Type' => 'application/json',
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://dashboard.cloud.patrowl.io/api/auth/vulns/owners/clear", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /api/auth/vulns/owners/clear

Update several status

:return 400: Invalid data

:return 200: Success

Body parameter

{
  "ids": [
    null
  ]
}
ids:
  - null

Parameters

Name In Type Required Description
body body bulk_remove_owners true none

Example responses

200 Response

{
  "status": "string",
  "message": "string"
}

Responses

Status Meaning Description Schema
200 OK none BasicResponseWithMessage
400 Bad Request none BasicResponseWithMessage

vulnerabilities_by_severity

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/severities \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/severities HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/severities',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/severities',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/severities', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/severities', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/severities");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/severities", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/severities

Get severities for all vulns.

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_severities_over_time

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/over-time", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/severities/over-time

Get severities over time.

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_statistics

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/severities/statistics", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/severities/statistics

Data corresponding to the number of opened and closed vulns on the last 7 days A key opened and a key closed, and in each key an object with a key total a key increase

:return 200: Success

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

vulnerabilities_times_to_fix

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix \
  -H 'Accept: application/json' \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix HTTP/1.1
Host: dashboard.cloud.patrowl.io
Accept: application/json


const headers = {
  'Accept':'application/json',
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Accept' => 'application/json',
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/auth/vulns/times-to-fix", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/auth/vulns/times-to-fix

API endpoint that allows Vulnerabilities to be viewed or edited.

Example responses

200 Response

{
  "property1": null,
  "property2": null
}

Responses

Status Meaning Description Schema
200 OK none Inline
400 Bad Request none BasicResponseWithMessage
403 Forbidden none BasicResponseWithMessage

Response Schema

Status Code 200

Unspecified response body

Name Type Required Restrictions Description
» additionalProperties any false none none

api

api_metrics_retrieve

Code samples

# You can also use wget
curl -X GET https://dashboard.cloud.patrowl.io/api/metrics \
  -H 'Authorization: Token 1234567890abcefghijklmnopqrstuvwxyz12345'

GET https://dashboard.cloud.patrowl.io/api/metrics HTTP/1.1
Host: dashboard.cloud.patrowl.io


const headers = {
  'Authorization':'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
};

fetch('https://dashboard.cloud.patrowl.io/api/metrics',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

result = RestClient.get 'https://dashboard.cloud.patrowl.io/api/metrics',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Authorization': 'Token 1234567890abcefghijklmnopqrstuvwxyz12345'
}

r = requests.get('https://dashboard.cloud.patrowl.io/api/metrics', headers = headers)

print(r.json())

<?php

require 'vendor/autoload.php';

$headers = array(
    'Authorization' => 'Token 1234567890abcefghijklmnopqrstuvwxyz12345',
);

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','https://dashboard.cloud.patrowl.io/api/metrics', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("https://dashboard.cloud.patrowl.io/api/metrics");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Authorization": []string{"Token 1234567890abcefghijklmnopqrstuvwxyz12345"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://dashboard.cloud.patrowl.io/api/metrics", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /api/metrics

Responses

Status Meaning Description Schema
200 OK No response body None

Schemas

Asset

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "tags": [
    0
  ],
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "owners": [
    0
  ],
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Asset DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer true read-only none
value string true none none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High
type TypeEf5Enum false none * ip - ip
* ip-range - ip-range
* ip-subnet - ip-subnet
* fqdn - fqdn
* domain - domain
* keyword - keyword
* other - other
description string¦null false none none
exposure ExposureEnum false none * unknown - Unknown
* external - External
* internal - Internal
* restricted - Restricted
is_active boolean true read-only none
score integer true read-only none
is_monitored boolean false none none
created_by string true read-only none
created_at string(date-time)¦null true read-only none
updated_at string(date-time)¦null true read-only none
tags [integer] false write-only none
score_level string true read-only none
technologies string true read-only none
asset_owners string true read-only none
owners [integer] false write-only none
groups string true read-only none
organization integer¦null false none none
last_checked_at string true read-only none
pentest_data string true read-only none
asset_tags string true read-only none
waf_provider string true read-only none
cdn_provider string true read-only none
saas_provider string true read-only none
cloud_provider string true read-only none
suborganizations [integer] false none none
monitored_slot_lock_until string(date-time)¦null true read-only none
liveness LivenessEnum true read-only * unknown - Unknown
* up - Up
* down - Down
www_related_domain string true read-only none
has_webservers string true read-only none

AssetGroup

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "tags": [
    0
  ],
  "assets": "string",
  "owners": [
    0
  ],
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

AssetGroup DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string false none none
description string false none none
organization integer true none none
created_at string(date-time)¦null true read-only none
updated_at string(date-time)¦null true read-only none
tags [integer] false write-only none
assets string true read-only none
owners [integer] false write-only none
asset_group_owners string true read-only none
asset_group_tags string true read-only none
suborganizations [integer] false none none
is_dynamic boolean false none none
filters string true read-only none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High

AssetGroupLite

{
  "id": 0,
  "title": "string",
  "assets": [
    null
  ],
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "asset_group_tags": "string",
  "is_dynamic": true,
  "criticality": 1
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string false none none
assets [any] true read-only none
organization integer true none none
created_at string(date-time)¦null true read-only none
updated_at string(date-time)¦null true read-only none
asset_group_tags string true read-only none
is_dynamic boolean false none none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High

AssetInList

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": -2147483648,
  "is_monitored": true,
  "created_by": "string",
  "activevulns": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "asset_tags": "string",
  "organization": 0,
  "last_checked_at": "string",
  "score_level": "string",
  "asset_owners": "string",
  "liveness": "unknown"
}

Asset DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer true read-only none
value string true none none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High
type TypeEf5Enum false none * ip - ip
* ip-range - ip-range
* ip-subnet - ip-subnet
* fqdn - fqdn
* domain - domain
* keyword - keyword
* other - other
description string¦null false none none
exposure ExposureEnum false none * unknown - Unknown
* external - External
* internal - Internal
* restricted - Restricted
is_active boolean false none none
score integer false none none
is_monitored boolean false none none
created_by string false none none
activevulns string true read-only none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none
asset_tags string true read-only none
organization integer¦null false none none
last_checked_at string true read-only none
score_level string true read-only none
asset_owners string true read-only none
liveness LivenessEnum false none * unknown - Unknown
* up - Up
* down - Down

AssetLite

{
  "id": 0,
  "value": "string",
  "is_monitored": true
}

AssetLite DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer true read-only none
value string true none none
is_monitored boolean false none none

AssetTag

{
  "id": 0,
  "value": "string",
  "organization": 0
}

AssetTag DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer true read-only none
value string true none none
organization integer true none none

AutoTagPolicy

{
  "id": 0,
  "title": "string",
  "is_enabled": true,
  "tag": "string",
  "tag_id": 0,
  "tag_value": "string",
  "filters": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true none none
is_enabled boolean true none none
tag string true write-only none
tag_id integer true read-only none
tag_value string true read-only none
filters string true read-only none
organization integer true none none
created_at string(date-time) true read-only none
updated_at string(date-time) true read-only none

AutoTagPolicyBulkDelete

{
  "ids": [
    "string"
  ],
  "remove_tag": false,
  "remove_tag_all": false
}

Properties

Name Type Required Restrictions Description
ids [string] true none none
remove_tag boolean false none none
remove_tag_all boolean false none none

Banner

{
  "id": 0,
  "host": "string",
  "port": 0,
  "text": "string"
}

Serializer for Banner endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
host string false none none
port integer¦null false none none
text string false none none

BasicResponse

{
  "status": "string"
}

Properties

Name Type Required Restrictions Description
status string true none none

BasicResponseWithMessage

{
  "status": "string",
  "message": "string"
}

Properties

Name Type Required Restrictions Description
status string true none none
message string true none none

Certificate

{
  "id": 0,
  "port": -2147483648,
  "host_id": 0,
  "host": "string",
  "serial_number": "string",
  "data_text": "string",
  "data_pem": "string",
  "data_parsed": null,
  "is_expired": true,
  "is_mismatched": true,
  "is_selfsigned": true,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for Certificate endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
port integer true read-only none
host_id integer true none none
host string false none none
serial_number string¦null false none none
data_text string¦null false none none
data_pem string¦null false none none
data_parsed any false none none
is_expired boolean false none none
is_mismatched boolean false none none
is_selfsigned boolean false none none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none

CertificateLite

{
  "id": 0,
  "port": 0,
  "host": "string",
  "serial_number": "string",
  "data_text": "string"
}

Lite Serializer for Certificate endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
port integer true none none
host string false none none
serial_number string¦null false none none
data_text string¦null false none none

Comment

{
  "id": 0,
  "text": "string",
  "author": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "is_editable": "string"
}

Serializer for comment endpoint

Properties

Name Type Required Restrictions Description
id integer true read-only none
text string true none none
author string true read-only none
created_at string(date-time) true read-only none
is_editable string true read-only none

ComplexityEnum

1

Properties

Name Type Required Restrictions Description
anonymous integer false none * 1 - Low
* 2 - Medium
* 3 - High

Enumerated Values

Property Value
anonymous 1
anonymous 2
anonymous 3

Control

{
  "id": 0,
  "title": "string",
  "status": "string",
  "result": "string",
  "cve_identifiers": [
    "string"
  ],
  "cvss_vector": "string",
  "cvss_score": "string",
  "severity": 0,
  "description": "string",
  "references": [
    "http://example.com"
  ],
  "vendor": "string",
  "products": [
    "string"
  ],
  "assets_impacted": "string",
  "assets_warning": "string",
  "vulnerabilities": "string",
  "started_at": "2019-08-24T14:15:22Z",
  "finished_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for Control endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true none none
status string true none none
result string true read-only none
cve_identifiers [string] false none none
cvss_vector string false none none
cvss_score string true read-only none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
description string false none none
references [string] false none none
vendor string false none none
products [string] false none none
assets_impacted string true read-only none
assets_warning string true read-only none
vulnerabilities string true read-only none
started_at string(date-time)¦null false none none
finished_at string(date-time)¦null false none none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none

ControlAsset

{
  "id": 0,
  "value": "string"
}

Serializer for Control's asset

Properties

Name Type Required Restrictions Description
id integer true read-only none
value string true none none

ControlLite

{
  "id": 0,
  "title": "string",
  "status": "string",
  "result": "string",
  "cve_identifiers": [
    "string"
  ],
  "cvss_vector": "string",
  "cvss_score": "string",
  "severity": 0,
  "description": "string",
  "references": [
    "http://example.com"
  ],
  "vendor": "string",
  "products": [
    "string"
  ],
  "started_at": "2019-08-24T14:15:22Z",
  "finished_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for Control endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true none none
status string true none none
result string true read-only none
cve_identifiers [string] false none none
cvss_vector string false none none
cvss_score string true read-only none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
description string false none none
references [string] false none none
vendor string false none none
products [string] false none none
started_at string(date-time)¦null false none none
finished_at string(date-time)¦null false none none
created_at string(date-time)¦null false none none
updated_at string(date-time) true read-only none

ControlVulnerability

{
  "id": 0,
  "asset": 0,
  "asset_value": "string",
  "title": "string",
  "severity": 0
}

Serializer for Control's vulnerability

Properties

Name Type Required Restrictions Description
id integer true read-only none
asset integer true none none
asset_value string true none none
title string false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical

CriticalityEnum

1

Properties

Name Type Required Restrictions Description
anonymous integer false none * 1 - Low
* 2 - Medium
* 3 - High

Enumerated Values

Property Value
anonymous 1
anonymous 2
anonymous 3

Cybelangel

{
  "id": 0,
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "client_secret": "string",
  "periodic_import_enabled": false,
  "is_token_expired": true
}

CybelangelConfig serializer definition

Properties

Name Type Required Restrictions Description
id integer true read-only none
org_id integer true none none
name string false none none
client_id string true none none
client_secret string true write-only none
periodic_import_enabled boolean false none none
is_token_expired boolean true read-only Check if access token is expired

Domain

{
  "id": 0,
  "name": "string",
  "asset": 0,
  "parent_domain": {
    "id": 0,
    "asset_id": 0,
    "name": "string"
  },
  "subdomains": [
    {
      "id": 0,
      "asset_id": 0,
      "name": "string"
    }
  ],
  "whois": {
    "id": 0,
    "text": "string",
    "registrar": "string",
    "registrar_id": "string",
    "registrar_url": "string",
    "registrar_status": null,
    "registrant_name": "string",
    "registrant_country": "string",
    "registrant_state_province": "string",
    "name_servers": null,
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z",
    "expiration_date": null
  },
  "is_registered": true,
  "dnsrecords": [
    null
  ],
  "ip_addresses": [
    {
      "id": 0,
      "address": "string",
      "asset_id": 0,
      "ports": "string"
    }
  ],
  "popularity_ranks": [
    null
  ],
  "categories": [
    null
  ],
  "search_engines_results": [
    null
  ],
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for Domain endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
name string true none none
asset integer true none none
parent_domain DomainLite false none Lite Serializer for Domain endpoint.
subdomains [DomainLite] false none [Lite Serializer for Domain endpoint.]
whois DomainWhoIsRecord false none Serializer for DomainWhoisRecord endpoint.
is_registered boolean false none none
dnsrecords [any] true none none
ip_addresses [IPAddressLite] false none [Lite Serializer for IPAddress endpoint.]
popularity_ranks [any] true none none
categories [any] true none none
search_engines_results [any] true none none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none

DomainLite

{
  "id": 0,
  "asset_id": 0,
  "name": "string"
}

Lite Serializer for Domain endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
asset_id integer true none none
name string true none none

DomainWhoIsRecord

{
  "id": 0,
  "text": "string",
  "registrar": "string",
  "registrar_id": "string",
  "registrar_url": "string",
  "registrar_status": null,
  "registrant_name": "string",
  "registrant_country": "string",
  "registrant_state_province": "string",
  "name_servers": null,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "expiration_date": null
}

Serializer for DomainWhoisRecord endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
text string¦null false none none
registrar string¦null false none none
registrar_id string¦null false none none
registrar_url string¦null false none none
registrar_status any false none none
registrant_name string¦null false none none
registrant_country string¦null false none none
registrant_state_province string¦null false none none
name_servers any false none none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none
expiration_date any false none none

DownloadReporting

{
  "emails": [
    "user@example.com"
  ],
  "assets": [
    0
  ],
  "vulnerabilities": [
    0
  ],
  "assetgroups": [
    0
  ],
  "assets_from_assetgroups": [
    0
  ],
  "vulnerabilities_from_assetgroups": [
    0
  ],
  "pentests": [
    0
  ],
  "assets_from_pentests": [
    0
  ],
  "vulnerabilities_from_pentests": [
    0
  ],
  "suborganizations": [
    0
  ]
}

Properties

Name Type Required Restrictions Description
emails [string] false none none
assets [integer] false none none
vulnerabilities [integer] false none none
assetgroups [integer] false none none
assets_from_assetgroups [integer] false none none
vulnerabilities_from_assetgroups [integer] false none none
pentests [integer] false none none
assets_from_pentests [integer] false none none
vulnerabilities_from_pentests [integer] false none none
suborganizations [integer] false none none

EffortEnum

"low"

Properties

Name Type Required Restrictions Description
anonymous string false none * low - Low
* medium - Medium
* high - High

Enumerated Values

Property Value
anonymous low
anonymous medium
anonymous high

EventComment

{
  "id": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "message": "string",
  "author": "user@example.com",
  "text": "string",
  "scope": "string",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_editable": "string"
}

Serializer for Comment endpoint.

Properties

Name Type Required Restrictions Description
id string true none none
created_at string(date-time) true none none
message string false none none
author string(email) false none none
text string false none none
scope string false none none
updated_at string(date-time) true none none
is_editable string true read-only none

ExposureEnum

"unknown"

Properties

Name Type Required Restrictions Description
anonymous string false none * unknown - Unknown
* external - External
* internal - Internal
* restricted - Restricted

Enumerated Values

Property Value
anonymous unknown
anonymous external
anonymous internal
anonymous restricted

ExternalVulnerability

{
  "id": 0,
  "title": "string",
  "description": "string",
  "severity": 0,
  "solution_priority": "urgent",
  "solution_effort": "low",
  "cvss_vector": "string",
  "solution_headline": "string",
  "solution": "string"
}

Serializer for ExternalV Vulnerabilities

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string¦null false none none
description string false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
solution_priority SolutionPriorityEnum false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening
solution_effort SolutionEffortEnum false none * low - Low
* medium - Medium
* high - High
cvss_vector string¦null false none none
solution_headline string¦null false none none
solution string false none none

Feed

{
  "id": 0,
  "title": "string",
  "type": "Control",
  "level": "Information",
  "message": "string",
  "ack": "string",
  "control": 0,
  "assets": [
    {
      "id": 0,
      "value": "string"
    }
  ],
  "vulnerabilities": [
    {
      "id": 0,
      "asset": 0,
      "asset_value": "string",
      "title": "string",
      "severity": 0
    }
  ],
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for Alert endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string false none none
type FeedTypeEnum false none * Control - Control
* Vulnerability - Vuln
* Retest - Retest
level LevelEnum false none * Information - Info
* Scanning - Scan
* Not impacted - Not Impacted
* Impacted - Impacted
* Warning - Warning
* Predictive - Predictive
message string false none none
ack string true read-only none
control integer¦null false none none
assets [ControlAsset] true read-only [Serializer for Control's asset]
vulnerabilities [ControlVulnerability] true read-only [Serializer for Control's vulnerability]
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none

FeedTypeEnum

"Control"

Properties

Name Type Required Restrictions Description
anonymous string false none * Control - Control
* Vulnerability - Vuln
* Retest - Retest

Enumerated Values

Property Value
anonymous Control
anonymous Vulnerability
anonymous Retest

IDsList

{
  "ids": [
    0
  ]
}

Properties

Name Type Required Restrictions Description
ids [integer] true none none

IPAddress

{
  "id": 0,
  "asset": 0,
  "address": "string",
  "type": "ipv4",
  "liveness": "unknown",
  "in_blacklist": true,
  "general_infos": {
    "id": 0,
    "asn_cidr": "string",
    "asn_number": "string",
    "asn_registry": "string",
    "asn_description": "string",
    "asn_country_code": "string"
  },
  "domains": "string",
  "blacklists": [
    null
  ],
  "ports": [
    {
      "id": 0,
      "number": -2147483648,
      "protocol": "tcp",
      "is_ssl": true,
      "service_name": "string",
      "state": "open",
      "banners": [
        {
          "id": 0,
          "host": "string",
          "port": 0,
          "text": "string"
        }
      ]
    }
  ],
  "search_engines_results": [
    null
  ],
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for IPAddress endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
asset integer true none none
address string true none none
type IPAddressTypeEnum false none * ipv4 - ipv4
* ipv6 - ipv6
liveness LivenessEnum false none * unknown - Unknown
* up - Up
* down - Down
in_blacklist boolean false none none
general_infos IPGeneralInfo false none Serializer for IPGeneralInfo endpoint.
domains string true read-only none
blacklists [any] true none none
ports [PortLite] false none [Lite serializer for Port endpoint.]
search_engines_results [any] true none none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none

IPAddressLite

{
  "id": 0,
  "address": "string",
  "asset_id": 0,
  "ports": "string"
}

Lite Serializer for IPAddress endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
address string true none none
asset_id integer true none none
ports string true read-only none

IPAddressTypeEnum

"ipv4"

Properties

Name Type Required Restrictions Description
anonymous string false none * ipv4 - ipv4
* ipv6 - ipv6

Enumerated Values

Property Value
anonymous ipv4
anonymous ipv6

IPGeneralInfo

{
  "id": 0,
  "asn_cidr": "string",
  "asn_number": "string",
  "asn_registry": "string",
  "asn_description": "string",
  "asn_country_code": "string"
}

Serializer for IPGeneralInfo endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
asn_cidr string¦null false none none
asn_number string¦null false none none
asn_registry string¦null false none none
asn_description string¦null false none none
asn_country_code string¦null false none none

ImportCSVAsset

{
  "organization": 0,
  "suborganization": "string",
  "file": "http://example.com"
}

Properties

Name Type Required Restrictions Description
organization integer true none none
suborganization string true none none
file string(uri) true none none

InsightBase

{
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Serializer for Insight endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true read-only none
light_description string false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
status InsightBaseStatusEnum false none * 0 - New
* 1 - Acknowledged
* 2 - False positive
* 3 - Done
* 4 - Reopened
* 5 - Duplicate
* 6 - Benign
* 7 - Risk acceptance
subtopic string true read-only none
asset AssetLite true none AssetLite DRF Serializer definition.
topic string true read-only none
created_at string(date-time) true read-only none
last_seen_at string(date-time) true read-only none
serial_number string true read-only none
port string true read-only none
expiration_date string true read-only none
subject string true read-only none
issuer string true read-only none
product string true read-only none
raw_data string true read-only Displayable raw data as alert evidence
provider string true read-only none
protection boolean true read-only none
selector string true read-only none
qualifier string true read-only none
policy string true read-only none
mx_records string true read-only none
protocol string true read-only none

InsightBaseStatusEnum

0

Properties

Name Type Required Restrictions Description
anonymous integer false none * 0 - New
* 1 - Acknowledged
* 2 - False positive
* 3 - Done
* 4 - Reopened
* 5 - Duplicate
* 6 - Benign
* 7 - Risk acceptance

Enumerated Values

Property Value
anonymous 0
anonymous 1
anonymous 2
anonymous 3
anonymous 4
anonymous 5
anonymous 6
anonymous 7

InsightBaseTyped

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Properties

allOf

Name Type Required Restrictions Description
anonymous object false none none
» resourcetype string true none none

and

Name Type Required Restrictions Description
anonymous InsightBase false none Serializer for Insight endpoint.

InsightPolicy

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true none none
description string false none none
is_enabled boolean false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
created_by UserLite true read-only none
organization integer true none none
created_at string(date-time)¦null true read-only none
updated_at string(date-time)¦null true read-only none
active_vulnerabilities string true read-only none
filters string true read-only none
already_applied boolean true read-only none

InsightPolymorphic

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Properties

None

LevelEnum

"Information"

Properties

Name Type Required Restrictions Description
anonymous string false none * Information - Info
* Scanning - Scan
* Not impacted - Not Impacted
* Impacted - Impacted
* Warning - Warning
* Predictive - Predictive

Enumerated Values

Property Value
anonymous Information
anonymous Scanning
anonymous Not impacted
anonymous Impacted
anonymous Warning
anonymous Predictive

LivenessEnum

"unknown"

Properties

Name Type Required Restrictions Description
anonymous string false none * unknown - Unknown
* up - Up
* down - Down

Enumerated Values

Property Value
anonymous unknown
anonymous up
anonymous down

NullEnum

null

Properties

None

Organization

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "is_active": true,
  "owner": "string",
  "user_count": 0,
  "is_poc": true,
  "is_sso": true,
  "risk_insights_enabled": true,
  "technologies_enabled": true,
  "brand_image_url": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "pentested_assets": 0,
  "max_pentested_assets_allowed": 0,
  "pentested_slot_available": 0,
  "max_pentested_slot_allowed": 0,
  "end_of_contract": "2019-08-24T14:15:22Z"
}

Serializer for Organization endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
name string true none The name of the organization
slug string true none The name in all lowercase, suitable for URL identification
is_active boolean false none none
owner string true read-only Return current organization's owner (if any).
user_count integer true read-only Return number of members within the organization.
is_poc boolean true read-only none
is_sso boolean true read-only none
risk_insights_enabled boolean true read-only none
technologies_enabled boolean true read-only none
brand_image_url string true read-only Return brand image url for current organization.
created_at string(date-time) true read-only Return created_at for current organization.
pentested_assets integer true read-only none
max_pentested_assets_allowed integer true read-only none
pentested_slot_available integer true read-only none
max_pentested_slot_allowed integer true read-only none
end_of_contract string(date-time) true read-only none

OrganizationSetting

{
  "id": 0,
  "key": "string",
  "value": "string",
  "is_secret": true,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for OrganizationSetting endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
key string true none none
value string¦null false none none
is_secret boolean false none none
created_at string(date-time)¦null true read-only none
updated_at string(date-time)¦null true read-only none

OrganizationUser

{
  "id": 0,
  "organization": 0,
  "user": 0,
  "username": "string",
  "email": "string",
  "is_admin": true,
  "is_active": true,
  "org_name": "string",
  "role": 0,
  "user_ids": [
    0
  ]
}

Serializer for Organization User endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
organization integer true none none
user integer true none none
username string true read-only Return user's username.
email string true read-only Return user's email.
is_admin boolean false none none
is_active boolean true read-only Return user's status.
org_name string true read-only Return organization name.
role integer true read-only Return user's role.
user_ids [integer] true write-only none

PaginatedAssetGroupLiteList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "assets": [
        null
      ],
      "organization": 0,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "asset_group_tags": "string",
      "is_dynamic": true,
      "criticality": 1
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [AssetGroupLite] false none none

PaginatedAssetInListList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "value": "string",
      "criticality": 1,
      "type": "ip",
      "description": "string",
      "exposure": "unknown",
      "is_active": true,
      "score": -2147483648,
      "is_monitored": true,
      "created_by": "string",
      "activevulns": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "asset_tags": "string",
      "organization": 0,
      "last_checked_at": "string",
      "score_level": "string",
      "asset_owners": "string",
      "liveness": "unknown"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [AssetInList] false none [Asset DRF Serializer definition.]

PaginatedAssetTagList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "value": "string",
      "organization": 0
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [AssetTag] false none [AssetTag DRF Serializer definition.]

PaginatedAutoTagPolicyList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "is_enabled": true,
      "tag": "string",
      "tag_id": 0,
      "tag_value": "string",
      "filters": "string",
      "organization": 0,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [AutoTagPolicy] false none none

PaginatedCertificateList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "port": -2147483648,
      "host_id": 0,
      "host": "string",
      "serial_number": "string",
      "data_text": "string",
      "data_pem": "string",
      "data_parsed": null,
      "is_expired": true,
      "is_mismatched": true,
      "is_selfsigned": true,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Certificate] false none [Serializer for Certificate endpoint.]

PaginatedCommentList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "text": "string",
      "author": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "is_editable": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Comment] false none [Serializer for comment endpoint]

PaginatedControlLiteList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "status": "string",
      "result": "string",
      "cve_identifiers": [
        "string"
      ],
      "cvss_vector": "string",
      "cvss_score": "string",
      "severity": 0,
      "description": "string",
      "references": [
        "http://example.com"
      ],
      "vendor": "string",
      "products": [
        "string"
      ],
      "started_at": "2019-08-24T14:15:22Z",
      "finished_at": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [ControlLite] false none [Serializer for Control endpoint.]

PaginatedCybelangelList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "org_id": 0,
      "name": "string",
      "client_id": "string",
      "client_secret": "string",
      "periodic_import_enabled": false,
      "is_token_expired": true
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Cybelangel] false none [CybelangelConfig serializer definition]

PaginatedDomainList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "name": "string",
      "asset": 0,
      "parent_domain": {
        "id": 0,
        "asset_id": 0,
        "name": "string"
      },
      "subdomains": [
        {
          "id": 0,
          "asset_id": 0,
          "name": "string"
        }
      ],
      "whois": {
        "id": 0,
        "text": "string",
        "registrar": "string",
        "registrar_id": "string",
        "registrar_url": "string",
        "registrar_status": null,
        "registrant_name": "string",
        "registrant_country": "string",
        "registrant_state_province": "string",
        "name_servers": null,
        "created_at": "2019-08-24T14:15:22Z",
        "updated_at": "2019-08-24T14:15:22Z",
        "expiration_date": null
      },
      "is_registered": true,
      "dnsrecords": [
        null
      ],
      "ip_addresses": [
        {
          "id": 0,
          "address": "string",
          "asset_id": 0,
          "ports": "string"
        }
      ],
      "popularity_ranks": [
        null
      ],
      "categories": [
        null
      ],
      "search_engines_results": [
        null
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Domain] false none [Serializer for Domain endpoint.]

PaginatedEventCommentList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "message": "string",
      "author": "user@example.com",
      "text": "string",
      "scope": "string",
      "updated_at": "2019-08-24T14:15:22Z",
      "is_editable": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [EventComment] false none [Serializer for Comment endpoint.]

PaginatedFeedList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "type": "Control",
      "level": "Information",
      "message": "string",
      "ack": "string",
      "control": 0,
      "assets": [
        {
          "id": 0,
          "value": "string"
        }
      ],
      "vulnerabilities": [
        {
          "id": 0,
          "asset": 0,
          "asset_value": "string",
          "title": "string",
          "severity": 0
        }
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Feed] false none [Serializer for Alert endpoint.]

PaginatedIPAddressList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "asset": 0,
      "address": "string",
      "type": "ipv4",
      "liveness": "unknown",
      "in_blacklist": true,
      "general_infos": {
        "id": 0,
        "asn_cidr": "string",
        "asn_number": "string",
        "asn_registry": "string",
        "asn_description": "string",
        "asn_country_code": "string"
      },
      "domains": "string",
      "blacklists": [
        null
      ],
      "ports": [
        {
          "id": 0,
          "number": -2147483648,
          "protocol": "tcp",
          "is_ssl": true,
          "service_name": "string",
          "state": "open",
          "banners": [
            {
              "id": 0,
              "host": "string",
              "port": 0,
              "text": "string"
            }
          ]
        }
      ],
      "search_engines_results": [
        null
      ],
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [IPAddress] false none [Serializer for IPAddress endpoint.]

PaginatedInsightPolicyList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "description": "string",
      "is_enabled": true,
      "severity": 0,
      "created_by": {
        "id": 0,
        "email": "user@example.com"
      },
      "organization": 0,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "active_vulnerabilities": "string",
      "filters": "string",
      "already_applied": true
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [InsightPolicy] false none none

PaginatedInsightPolymorphicList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "resourcetype": "string",
      "id": 0,
      "title": "string",
      "light_description": "string",
      "severity": 0,
      "status": 0,
      "subtopic": "string",
      "asset": {
        "id": 0,
        "value": "string",
        "is_monitored": true
      },
      "topic": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "last_seen_at": "2019-08-24T14:15:22Z",
      "serial_number": "string",
      "port": "string",
      "expiration_date": "string",
      "subject": "string",
      "issuer": "string",
      "product": "string",
      "raw_data": "string",
      "provider": "string",
      "protection": true,
      "selector": "string",
      "qualifier": "string",
      "policy": "string",
      "mx_records": "string",
      "protocol": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [InsightPolymorphic] false none none

PaginatedOrganizationList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "name": "string",
      "slug": "string",
      "is_active": true,
      "owner": "string",
      "user_count": 0,
      "is_poc": true,
      "is_sso": true,
      "risk_insights_enabled": true,
      "technologies_enabled": true,
      "brand_image_url": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "pentested_assets": 0,
      "max_pentested_assets_allowed": 0,
      "pentested_slot_available": 0,
      "max_pentested_slot_allowed": 0,
      "end_of_contract": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Organization] false none [Serializer for Organization endpoint.]

PaginatedOrganizationSettingList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "key": "string",
      "value": "string",
      "is_secret": true,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [OrganizationSetting] false none [Serializer for OrganizationSetting endpoint.]

PaginatedOrganizationUserList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "organization": 0,
      "user": 0,
      "username": "string",
      "email": "string",
      "is_admin": true,
      "is_active": true,
      "org_name": "string",
      "role": 0,
      "user_ids": [
        0
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [OrganizationUser] false none [Serializer for Organization User endpoint.]

PaginatedPentestList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "requested_by": "string",
      "title": "string",
      "provider": "string",
      "organization": 0,
      "description": "string",
      "comments": "string",
      "date_from": "2019-08-24T14:15:22Z",
      "date_to": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "nb_vulns": 0,
      "attachments": "string",
      "nb_assets": 0,
      "is_greybox": true,
      "suborganization": 0,
      "pentest_suborganization": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Pentest] false none [Serializer for Pentest endpoint.]

PaginatedPortList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "ip_address": 0,
      "number": -2147483648,
      "protocol": "tcp",
      "is_ssl": true,
      "service_name": "string",
      "state": "open",
      "certificates": [
        {
          "id": 0,
          "port": 0,
          "host": "string",
          "serial_number": "string",
          "data_text": "string"
        }
      ],
      "banners": [
        {
          "id": 0,
          "host": "string",
          "port": 0,
          "text": "string"
        }
      ],
      "webservers": [
        {
          "id": 0,
          "url": "string",
          "server": "string",
          "title": "string"
        }
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Port] false none [Serializer for Port endpoint.]

PaginatedReadGreyboxRequestList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "user_friendly_id": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "started_at": "2019-08-24T14:15:22Z",
      "finished_at": "2019-08-24T14:15:22Z",
      "complexity": 1,
      "in_scope": "string",
      "contact_info": "string",
      "complexity_text": "string",
      "requested_by": "user@example.com",
      "comments": "string",
      "organization": 0,
      "organization_name": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [ReadGreyboxRequest] false none [Serializer for Greybox Request class]

PaginatedRemediationList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "organization": 0,
      "headline": "string",
      "solution": "string",
      "solution_html": "string",
      "priority": "urgent",
      "effort": "low",
      "gain": 0,
      "owners": [
        {
          "id": 0,
          "email": "user@example.com"
        }
      ],
      "due_date": "2019-08-24T14:15:22Z",
      "status": "new",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "suborganization": 0,
      "suborganization_name": "string",
      "count_vulns": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Remediation] false none [Serializer for Remediation endpoint.]

PaginatedRetestList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "patrowl_id": 0,
      "vulnerability": 0,
      "status": "none",
      "comments": "string",
      "requested_by": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "is_auto": true
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Retest] false none [Serializer for Retest endpoint.]

PaginatedScanInListList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "finished_at": "2019-08-24T14:15:22Z",
      "security_check": 0,
      "id": 0,
      "assets": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [ScanInList] false none none

PaginatedSubOrganizationUserList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "organization": 0,
      "user": 0,
      "username": "string",
      "email": "string",
      "is_admin": true,
      "is_active": true,
      "org_name": "string",
      "role": 0,
      "user_ids": [
        0
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [SubOrganizationUser] false none [Serializer for SubOrganization User endpoint.]

PaginatedSubOrganizationsInListList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "is_default": true,
      "organization": 0,
      "name": "string",
      "slug": "string",
      "user_count": "string",
      "assetgroup_count": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "parent": 0,
      "asset_count": "string",
      "children": "string",
      "parent_name": "string",
      "root_id": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [SubOrganizationsInList] false none [Serializer for suborganization endpoint.]

PaginatedSubOrganizationsListList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "name": "string",
      "slug": "string",
      "parent_name": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [SubOrganizationsList] false none [Serializer for suborganization endpoint.]

PaginatedSubTopicList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "slug": "string",
      "description": "string",
      "is_available": true,
      "default_severity": 0,
      "security_check": 0,
      "remediation": "string",
      "remediation_effort": 0,
      "remediation_priority": 0
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [SubTopic] false none none

PaginatedTicketList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "identifier": "string",
      "status": 0,
      "status_name": "string",
      "link": "string",
      "last_checked_at": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Ticket] false none [Serializer for Ticket endpoint.]

PaginatedTopicList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "title": "string",
      "slug": "string",
      "is_available": true,
      "subtopics": [
        {
          "id": 0,
          "title": "string",
          "slug": "string",
          "description": "string",
          "is_available": true,
          "default_severity": 0,
          "security_check": 0,
          "remediation": "string",
          "remediation_effort": 0,
          "remediation_priority": 0
        }
      ]
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [Topic] false none none

PaginatedUserList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "username": "string",
      "first_name": "string",
      "last_name": "string",
      "email": "user@example.com",
      "last_login": "2019-08-24T14:15:22Z",
      "is_superuser": true,
      "is_staff": true,
      "is_active": true,
      "changed_first_password": true,
      "orgs": {
        "property1": null,
        "property2": null
      },
      "current_org": {
        "property1": null,
        "property2": null
      },
      "is_org_admin": true,
      "role": 2,
      "auth_token": "string",
      "dark_mode": true,
      "suborgs": {
        "property1": null,
        "property2": null
      },
      "asset_assets": "string",
      "assetgroup_assetgroups": "string",
      "vulnerability_vulnerabilities": "string",
      "from_sso": true,
      "emails_subscribed": "string",
      "intercom": "string"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [User] false none [Serializer for User endpoint.]

PaginatedVulnerabilityLiteList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "user_friendly_id": "string",
      "description": "string",
      "solution_headline": "string",
      "solution_priority": "urgent",
      "solution_effort": "low",
      "solution_gain": -2147483648,
      "is_quickwin": true,
      "title": "string",
      "source": "string",
      "status": "new",
      "severity": 0,
      "asset_id": "string",
      "asset_value": "string",
      "asset_criticality": "string",
      "vuln_owners": "string",
      "vuln_solution_owners": "string",
      "asset": 0,
      "reteststatus": "string",
      "ticketstatus": -2147483648,
      "is_retestable": true,
      "last_ticket": "string",
      "solution_duedate": "2019-08-24T14:15:22Z",
      "created_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [VulnerabilityLite] false none [Lite Serializer for Vulnerability endpoint.]

PaginatedWebServerList

{
  "count": 123,
  "next": "http://api.example.org/accounts/?page=4",
  "previous": "http://api.example.org/accounts/?page=2",
  "results": [
    {
      "id": 0,
      "ports": [
        {
          "id": 0,
          "number": -2147483648,
          "protocol": "tcp",
          "is_ssl": true,
          "service_name": "string",
          "state": "open",
          "banners": [
            {
              "id": 0,
              "host": "string",
              "port": 0,
              "text": "string"
            }
          ]
        }
      ],
      "host": "string",
      "url": "string",
      "server": "string",
      "path": "string",
      "title": "string",
      "asset": 0,
      "response_time": "string",
      "status_code": "string",
      "content_length": "string",
      "content_type": "string",
      "jarm": "string",
      "favicon_hash": "string",
      "technologies": [
        null
      ],
      "ips": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer false none none
next string(uri)¦null false none none
previous string(uri)¦null false none none
results [WebServer] false none [Serializer for WebServer endpoint.]

PatchedAsset

{
  "id": 0,
  "value": "string",
  "criticality": 1,
  "type": "ip",
  "description": "string",
  "exposure": "unknown",
  "is_active": true,
  "score": 0,
  "is_monitored": true,
  "created_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "tags": [
    0
  ],
  "score_level": "string",
  "technologies": "string",
  "asset_owners": "string",
  "owners": [
    0
  ],
  "groups": "string",
  "organization": 0,
  "last_checked_at": "string",
  "pentest_data": "string",
  "asset_tags": "string",
  "waf_provider": "string",
  "cdn_provider": "string",
  "saas_provider": "string",
  "cloud_provider": "string",
  "suborganizations": [
    0
  ],
  "monitored_slot_lock_until": "2019-08-24T14:15:22Z",
  "liveness": "unknown",
  "www_related_domain": "string",
  "has_webservers": "string"
}

Asset DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer false read-only none
value string false none none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High
type TypeEf5Enum false none * ip - ip
* ip-range - ip-range
* ip-subnet - ip-subnet
* fqdn - fqdn
* domain - domain
* keyword - keyword
* other - other
description string¦null false none none
exposure ExposureEnum false none * unknown - Unknown
* external - External
* internal - Internal
* restricted - Restricted
is_active boolean false read-only none
score integer false read-only none
is_monitored boolean false none none
created_by string false read-only none
created_at string(date-time)¦null false read-only none
updated_at string(date-time)¦null false read-only none
tags [integer] false write-only none
score_level string false read-only none
technologies string false read-only none
asset_owners string false read-only none
owners [integer] false write-only none
groups string false read-only none
organization integer¦null false none none
last_checked_at string false read-only none
pentest_data string false read-only none
asset_tags string false read-only none
waf_provider string false read-only none
cdn_provider string false read-only none
saas_provider string false read-only none
cloud_provider string false read-only none
suborganizations [integer] false none none
monitored_slot_lock_until string(date-time)¦null false read-only none
liveness LivenessEnum false read-only * unknown - Unknown
* up - Up
* down - Down
www_related_domain string false read-only none
has_webservers string false read-only none

PatchedAssetGroup

{
  "id": 0,
  "title": "string",
  "description": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "tags": [
    0
  ],
  "assets": "string",
  "owners": [
    0
  ],
  "asset_group_owners": "string",
  "asset_group_tags": "string",
  "suborganizations": [
    0
  ],
  "is_dynamic": true,
  "filters": "string",
  "criticality": 1
}

AssetGroup DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer false read-only none
title string false none none
description string false none none
organization integer false none none
created_at string(date-time)¦null false read-only none
updated_at string(date-time)¦null false read-only none
tags [integer] false write-only none
assets string false read-only none
owners [integer] false write-only none
asset_group_owners string false read-only none
asset_group_tags string false read-only none
suborganizations [integer] false none none
is_dynamic boolean false none none
filters string false read-only none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High

PatchedAssetTag

{
  "id": 0,
  "value": "string",
  "organization": 0
}

AssetTag DRF Serializer definition.

Properties

Name Type Required Restrictions Description
id integer false read-only none
value string false none none
organization integer false none none

PatchedCybelangel

{
  "id": 0,
  "org_id": 0,
  "name": "string",
  "client_id": "string",
  "client_secret": "string",
  "periodic_import_enabled": false,
  "is_token_expired": true
}

CybelangelConfig serializer definition

Properties

Name Type Required Restrictions Description
id integer false read-only none
org_id integer false none none
name string false none none
client_id string false none none
client_secret string false write-only none
periodic_import_enabled boolean false none none
is_token_expired boolean false read-only Check if access token is expired

PatchedInsightBase

{
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Serializer for Insight endpoint.

Properties

Name Type Required Restrictions Description
id integer false read-only none
title string false read-only none
light_description string false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
status InsightBaseStatusEnum false none * 0 - New
* 1 - Acknowledged
* 2 - False positive
* 3 - Done
* 4 - Reopened
* 5 - Duplicate
* 6 - Benign
* 7 - Risk acceptance
subtopic string false read-only none
asset AssetLite false none AssetLite DRF Serializer definition.
topic string false read-only none
created_at string(date-time) false read-only none
last_seen_at string(date-time) false read-only none
serial_number string false read-only none
port string false read-only none
expiration_date string false read-only none
subject string false read-only none
issuer string false read-only none
product string false read-only none
raw_data string false read-only Displayable raw data as alert evidence
provider string false read-only none
protection boolean false read-only none
selector string false read-only none
qualifier string false read-only none
policy string false read-only none
mx_records string false read-only none
protocol string false read-only none

PatchedInsightBaseTyped

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Properties

allOf

Name Type Required Restrictions Description
anonymous object false none none
» resourcetype string false none none

and

Name Type Required Restrictions Description
anonymous PatchedInsightBase false none Serializer for Insight endpoint.

PatchedInsightPolicy

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Properties

Name Type Required Restrictions Description
id integer false read-only none
title string false none none
description string false none none
is_enabled boolean false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
created_by UserLite false read-only none
organization integer false none none
created_at string(date-time)¦null false read-only none
updated_at string(date-time)¦null false read-only none
active_vulnerabilities string false read-only none
filters string false read-only none
already_applied boolean false read-only none

PatchedInsightPolymorphic

{
  "resourcetype": "string",
  "id": 0,
  "title": "string",
  "light_description": "string",
  "severity": 0,
  "status": 0,
  "subtopic": "string",
  "asset": {
    "id": 0,
    "value": "string",
    "is_monitored": true
  },
  "topic": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "last_seen_at": "2019-08-24T14:15:22Z",
  "serial_number": "string",
  "port": "string",
  "expiration_date": "string",
  "subject": "string",
  "issuer": "string",
  "product": "string",
  "raw_data": "string",
  "provider": "string",
  "protection": true,
  "selector": "string",
  "qualifier": "string",
  "policy": "string",
  "mx_records": "string",
  "protocol": "string"
}

Properties

None

PatchedPentest

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "suborganization": 0,
  "pentest_suborganization": "string"
}

Serializer for Pentest endpoint.

Properties

Name Type Required Restrictions Description
id integer false read-only none
requested_by string false read-only none
title string false none none
provider string false none none
organization integer false none none
description string false none none
comments string false none none
date_from string(date-time)¦null false none none
date_to string(date-time)¦null false none none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none
nb_vulns integer false read-only Return the number of related vulnerabilities.
attachments string false read-only none
nb_assets integer false read-only Return the number of related assets.
is_greybox boolean false none none
suborganization integer false write-only none
pentest_suborganization string false read-only none

PatchedRemediation

{
  "id": 0,
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "solution_html": "string",
  "priority": "urgent",
  "effort": "low",
  "gain": 0,
  "owners": [
    {
      "id": 0,
      "email": "user@example.com"
    }
  ],
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "suborganization": 0,
  "suborganization_name": "string",
  "count_vulns": "string"
}

Serializer for Remediation endpoint.

Properties

Name Type Required Restrictions Description
id integer false read-only none
organization integer false none none
headline string false none none
solution string false none none
solution_html string false read-only none
priority PriorityEnum false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening
effort EffortEnum false none * low - Low
* medium - Medium
* high - High
gain integer false read-only none
owners [UserLite] false read-only none
due_date string(date-time)¦null false none none
status Status9fcEnum false none * new - New
* ack - Acknowledged
* assigned - Assigned
* patched - Patched
* closed - Closed
* closed-benign - Closed (Benign)
* closed-fp - Closed (False-Positive)
* closed-duplicate - Closed (Duplicate)
* closed-workaround - Closed (Workaround)
* closed-risk-acceptance - Closed (Risk acceptance)
created_at string(date-time) false read-only none
updated_at string(date-time) false read-only none
suborganization integer¦null false none none
suborganization_name string false read-only none
count_vulns string false read-only none

PatchedUpdateAutoTagPolicy

{
  "id": 0,
  "title": "string",
  "is_enabled": true,
  "tag": "string",
  "tag_id": 0,
  "tag_value": "string",
  "filters": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Properties

Name Type Required Restrictions Description
id integer false read-only none
title string false none none
is_enabled boolean false none none
tag string false write-only none
tag_id integer false read-only none
tag_value string false read-only none
filters string false read-only none
organization integer false read-only none
created_at string(date-time) false read-only none
updated_at string(date-time) false read-only none

PatchedUpdateInsightPolicy

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Properties

Name Type Required Restrictions Description
id integer false read-only none
title string false none none
description string false none none
is_enabled boolean false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
created_by UserLite false read-only none
organization integer false read-only none
created_at string(date-time)¦null false read-only none
updated_at string(date-time)¦null false read-only none
active_vulnerabilities string false read-only none
filters string false read-only none
already_applied boolean false read-only none

PatchedVulnerability

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "solution_owners": [
    0
  ],
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Serializer for Vulnerability endpoint.

Properties

Name Type Required Restrictions Description
id integer false read-only none
user_friendly_id string false read-only none
patrowl_id integer¦null false none none
asset integer false none none
asset_id string false read-only Return the asset id.
organization integer¦null false none none
asset_value string false read-only Return the asset value.
asset_type string false read-only Return the asset value.
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
cvss_vector string¦null false none none
cvss_score string false read-only none
status Status9fcEnum false none * new - New
* ack - Acknowledged
* assigned - Assigned
* patched - Patched
* closed - Closed
* closed-benign - Closed (Benign)
* closed-fp - Closed (False-Positive)
* closed-duplicate - Closed (Duplicate)
* closed-workaround - Closed (Workaround)
* closed-risk-acceptance - Closed (Risk acceptance)
title string false none none
description string false none none
description_html string false read-only none
source string false none none
external_id any false none none
category string false none none
business_impacts [string]¦null false none none
last_ticket string false read-only none
has_exploit boolean false none none
solution_headline string¦null false none none
solution string false none none
solution_html string false read-only none
solution_priority SolutionPriorityEnum false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening
solution_effort SolutionEffortEnum false none * low - Low
* medium - Medium
* high - High
solution_gain integer false none none
owners [integer] false write-only none
solution_duedate string(date-time)¦null false none none
is_quickwin boolean false none none
is_auto boolean false none none
is_greybox boolean false none none
is_overdue string false read-only none
remediation_date string(date-time)¦null false none none
last_status_update string(date-time) false none none
found_at string(date-time)¦null false none none
last_checked_at string(date-time)¦null false none none
created_at string(date-time) false none none
updated_at string(date-time) false none none
reteststatus string false read-only none
ticketstatus integer false none none
is_retestable boolean false read-only Check if the vuln is retestable

Returns:
bool: False if vuln has no patrowl_id/org is in PoC/asset is not pentested
attachments string false read-only none
vuln_owners string false read-only none
vuln_solution_owners string false read-only none
solution_owners [integer] false write-only none
suborganizations string false read-only none
external_vulnerability ExternalVulnerability false read-only Serializer for ExternalV Vulnerabilities
last_updated_by VulnerabilityUser false read-only none
updated_by_user_at string(date-time)¦null false none none

Patchedbulk_update_vulns_status

{
  "vulnerabilities_id": [
    null
  ],
  "status": "new"
}

Properties

Name Type Required Restrictions Description
vulnerabilities_id [any] false none none
status Status9fcEnum false none * new - New
* ack - Acknowledged
* assigned - Assigned
* patched - Patched
* closed - Closed
* closed-benign - Closed (Benign)
* closed-fp - Closed (False-Positive)
* closed-duplicate - Closed (Duplicate)
* closed-workaround - Closed (Workaround)
* closed-risk-acceptance - Closed (Risk acceptance)

Patchedserializer_assets_bulk_partial_update

{
  "assets_id": [
    null
  ],
  "criticality": 1,
  "is_monitored": true
}

Properties

Name Type Required Restrictions Description
assets_id [any] false none none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High
is_monitored boolean false none none

Pentest

{
  "id": 0,
  "requested_by": "string",
  "title": "string",
  "provider": "string",
  "organization": 0,
  "description": "string",
  "comments": "string",
  "date_from": "2019-08-24T14:15:22Z",
  "date_to": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "nb_vulns": 0,
  "attachments": "string",
  "nb_assets": 0,
  "is_greybox": true,
  "suborganization": 0,
  "pentest_suborganization": "string"
}

Serializer for Pentest endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
requested_by string true read-only none
title string false none none
provider string false none none
organization integer true none none
description string false none none
comments string false none none
date_from string(date-time)¦null false none none
date_to string(date-time)¦null false none none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none
nb_vulns integer true read-only Return the number of related vulnerabilities.
attachments string true read-only none
nb_assets integer true read-only Return the number of related assets.
is_greybox boolean false none none
suborganization integer false write-only none
pentest_suborganization string true read-only none

Port

{
  "id": 0,
  "ip_address": 0,
  "number": -2147483648,
  "protocol": "tcp",
  "is_ssl": true,
  "service_name": "string",
  "state": "open",
  "certificates": [
    {
      "id": 0,
      "port": 0,
      "host": "string",
      "serial_number": "string",
      "data_text": "string"
    }
  ],
  "banners": [
    {
      "id": 0,
      "host": "string",
      "port": 0,
      "text": "string"
    }
  ],
  "webservers": [
    {
      "id": 0,
      "url": "string",
      "server": "string",
      "title": "string"
    }
  ]
}

Serializer for Port endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
ip_address integer¦null false none none
number integer false none none
protocol ProtocolEnum false none * tcp - TCP
* udp - UDP
is_ssl boolean false none none
service_name string¦null false none none
state StateEnum false none * open - Open
* filtered - Filtered
* closed - Closed
* unknown - Unknown
certificates [CertificateLite] false none [Lite Serializer for Certificate endpoint.]
banners [Banner] false none [Serializer for Banner endpoint.]
webservers [WebServerLite] false none [Lite Serializer for WebServer endpoint.]

PortLite

{
  "id": 0,
  "number": -2147483648,
  "protocol": "tcp",
  "is_ssl": true,
  "service_name": "string",
  "state": "open",
  "banners": [
    {
      "id": 0,
      "host": "string",
      "port": 0,
      "text": "string"
    }
  ]
}

Lite serializer for Port endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
number integer false none none
protocol ProtocolEnum false none * tcp - TCP
* udp - UDP
is_ssl boolean false none none
service_name string¦null false none none
state StateEnum false none * open - Open
* filtered - Filtered
* closed - Closed
* unknown - Unknown
banners [Banner] false none [Serializer for Banner endpoint.]

PriorityEnum

"urgent"

Properties

Name Type Required Restrictions Description
anonymous string false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening

Enumerated Values

Property Value
anonymous urgent
anonymous moderate
anonymous hardening

ProtocolEnum

"tcp"

Properties

Name Type Required Restrictions Description
anonymous string false none * tcp - TCP
* udp - UDP

Enumerated Values

Property Value
anonymous tcp
anonymous udp

ReadGreyboxRequest

{
  "id": 0,
  "user_friendly_id": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "started_at": "2019-08-24T14:15:22Z",
  "finished_at": "2019-08-24T14:15:22Z",
  "complexity": 1,
  "in_scope": "string",
  "contact_info": "string",
  "complexity_text": "string",
  "requested_by": "user@example.com",
  "comments": "string",
  "organization": 0,
  "organization_name": "string"
}

Serializer for Greybox Request class

Properties

Name Type Required Restrictions Description
id integer true read-only none
user_friendly_id string true read-only none
created_at string(date-time) false none none
started_at string(date-time)¦null false none none
finished_at string(date-time)¦null false none none
complexity ComplexityEnum false none * 1 - Low
* 2 - Medium
* 3 - High
in_scope string false none Insert assets
contact_info string false none Insert contact information: name + email + phone number
complexity_text string true none none
requested_by string(email) true none none
comments string false none Additional information about the assessment:
organization integer true none none
organization_name string true none none

Remediation

{
  "id": 0,
  "organization": 0,
  "headline": "string",
  "solution": "string",
  "solution_html": "string",
  "priority": "urgent",
  "effort": "low",
  "gain": 0,
  "owners": [
    {
      "id": 0,
      "email": "user@example.com"
    }
  ],
  "due_date": "2019-08-24T14:15:22Z",
  "status": "new",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "suborganization": 0,
  "suborganization_name": "string",
  "count_vulns": "string"
}

Serializer for Remediation endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
organization integer true none none
headline string false none none
solution string false none none
solution_html string true read-only none
priority PriorityEnum false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening
effort EffortEnum false none * low - Low
* medium - Medium
* high - High
gain integer true read-only none
owners [UserLite] true read-only none
due_date string(date-time)¦null false none none
status Status9fcEnum false none * new - New
* ack - Acknowledged
* assigned - Assigned
* patched - Patched
* closed - Closed
* closed-benign - Closed (Benign)
* closed-fp - Closed (False-Positive)
* closed-duplicate - Closed (Duplicate)
* closed-workaround - Closed (Workaround)
* closed-risk-acceptance - Closed (Risk acceptance)
created_at string(date-time) true read-only none
updated_at string(date-time) true read-only none
suborganization integer¦null false none none
suborganization_name string true read-only none
count_vulns string true read-only none

RemediationEffortEnum

0

Properties

Name Type Required Restrictions Description
anonymous integer false none * 0 - Low
* 1 - Medium
* 2 - High

Enumerated Values

Property Value
anonymous 0
anonymous 1
anonymous 2

RemediationPriorityEnum

0

Properties

Name Type Required Restrictions Description
anonymous integer false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical

Enumerated Values

Property Value
anonymous 0
anonymous 1
anonymous 2
anonymous 3
anonymous 4

Retest

{
  "id": 0,
  "patrowl_id": 0,
  "vulnerability": 0,
  "status": "none",
  "comments": "string",
  "requested_by": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "is_auto": true
}

Serializer for Retest endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
patrowl_id integer¦null true read-only none
vulnerability integer true read-only none
status RetestStatusEnum true read-only * none - None
* pending - Pending
* in-progress - In Progress
* done-fixed - Done (Fixed)
* done-not-fixed - Done (Not Fixed)
* error - Error
* canceled - Canceled
comments string¦null false none none
requested_by string¦null true read-only none
created_at string(date-time) false none none
updated_at string(date-time) false none none
is_auto boolean true read-only none

RetestStatusEnum

"none"

Properties

Name Type Required Restrictions Description
anonymous string false none * none - None
* pending - Pending
* in-progress - In Progress
* done-fixed - Done (Fixed)
* done-not-fixed - Done (Not Fixed)
* error - Error
* canceled - Canceled

Enumerated Values

Property Value
anonymous none
anonymous pending
anonymous in-progress
anonymous done-fixed
anonymous done-not-fixed
anonymous error
anonymous canceled

RoleEnum

2

Properties

Name Type Required Restrictions Description
anonymous integer false none * 2 - Standard
* 3 - Auditor
* 4 - Organization Admin

Enumerated Values

Property Value
anonymous 2
anonymous 3
anonymous 4

ScanInList

{
  "finished_at": "2019-08-24T14:15:22Z",
  "security_check": 0,
  "id": 0,
  "assets": "string"
}

Properties

Name Type Required Restrictions Description
finished_at string(date-time)¦null false none none
security_check integer¦null false none none
id integer true read-only none
assets string true read-only none

ScanTypeEnum

"passive"

Properties

Name Type Required Restrictions Description
anonymous string false none * passive - Passive
* offensive - Offensive

Enumerated Values

Property Value
anonymous passive
anonymous offensive

SecurityCheck

{
  "id": 0,
  "title": "string",
  "description": "string",
  "scan_type": "passive",
  "is_available": true,
  "is_auto": true,
  "latest_scans": "string",
  "vulnerabilities": "string",
  "webservers_required": true
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true none none
description string¦null false none none
scan_type ScanTypeEnum false none * passive - Passive
* offensive - Offensive
is_available boolean false none none
is_auto boolean false none none
latest_scans string true read-only none
vulnerabilities string true read-only none
webservers_required boolean true read-only none

SolutionEffortEnum

"low"

Properties

Name Type Required Restrictions Description
anonymous string false none * low - Low
* medium - Medium
* high - High

Enumerated Values

Property Value
anonymous low
anonymous medium
anonymous high

SolutionPriorityEnum

"urgent"

Properties

Name Type Required Restrictions Description
anonymous string false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening

Enumerated Values

Property Value
anonymous urgent
anonymous moderate
anonymous hardening

StateEnum

"open"

Properties

Name Type Required Restrictions Description
anonymous string false none * open - Open
* filtered - Filtered
* closed - Closed
* unknown - Unknown

Enumerated Values

Property Value
anonymous open
anonymous filtered
anonymous closed
anonymous unknown

Status9fcEnum

"new"

Properties

Name Type Required Restrictions Description
anonymous string false none * new - New
* ack - Acknowledged
* assigned - Assigned
* patched - Patched
* closed - Closed
* closed-benign - Closed (Benign)
* closed-fp - Closed (False-Positive)
* closed-duplicate - Closed (Duplicate)
* closed-workaround - Closed (Workaround)
* closed-risk-acceptance - Closed (Risk acceptance)

Enumerated Values

Property Value
anonymous new
anonymous ack
anonymous assigned
anonymous patched
anonymous closed
anonymous closed-benign
anonymous closed-fp
anonymous closed-duplicate
anonymous closed-workaround
anonymous closed-risk-acceptance

SubOrganization

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "parent_name": "string",
  "root_id": "string",
  "monitored_asset_count": "string",
  "children": "string"
}

Serializer for suborganization endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
is_default boolean true read-only none
organization integer true read-only none
name string true none The name of the organization
slug string true read-only The name in all lowercase, suitable for URL identification
user_count string true read-only none
assetgroup_count string true read-only none
created_at string(date-time) true read-only Return created_at for current suborganization.
parent integer¦null false none none
asset_count string true read-only none
parent_name string true read-only none
root_id string true read-only none
monitored_asset_count string true read-only none
children string true read-only none

SubOrganizationUser

{
  "id": 0,
  "organization": 0,
  "user": 0,
  "username": "string",
  "email": "string",
  "is_admin": true,
  "is_active": true,
  "org_name": "string",
  "role": 0,
  "user_ids": [
    0
  ]
}

Serializer for SubOrganization User endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
organization integer true read-only none
user integer true read-only none
username string true read-only Return user's username.
email string true read-only Return user's email.
is_admin boolean true read-only none
is_active boolean true read-only Return user's status.
org_name string true read-only Return organization name.
role integer true read-only Return user's role.
user_ids [integer] true write-only none

SubOrganizationsInList

{
  "id": 0,
  "is_default": true,
  "organization": 0,
  "name": "string",
  "slug": "string",
  "user_count": "string",
  "assetgroup_count": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "parent": 0,
  "asset_count": "string",
  "children": "string",
  "parent_name": "string",
  "root_id": "string"
}

Serializer for suborganization endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
is_default boolean true read-only none
organization integer true read-only none
name string true none The name of the organization
slug string true read-only The name in all lowercase, suitable for URL identification
user_count string true read-only none
assetgroup_count string true read-only none
created_at string(date-time) true read-only Return created_at for current suborganization.
parent integer¦null false none none
asset_count string true read-only none
children string true read-only none
parent_name string true read-only none
root_id string true read-only none

SubOrganizationsList

{
  "id": 0,
  "name": "string",
  "slug": "string",
  "parent_name": "string"
}

Serializer for suborganization endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
name string true none The name of the organization
slug string true none The name in all lowercase, suitable for URL identification
parent_name string¦null true none none

SubTopic

{
  "id": 0,
  "title": "string",
  "slug": "string",
  "description": "string",
  "is_available": true,
  "default_severity": 0,
  "security_check": 0,
  "remediation": "string",
  "remediation_effort": 0,
  "remediation_priority": 0
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true read-only none
slug string true read-only none
description string true read-only none
is_available boolean true read-only none
default_severity RemediationPriorityEnum true read-only * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
security_check integer¦null true read-only none
remediation string true read-only none
remediation_effort RemediationEffortEnum true read-only * 0 - Low
* 1 - Medium
* 2 - High
remediation_priority RemediationPriorityEnum true read-only * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical

Success

{
  "score": "string"
}

Properties

Name Type Required Restrictions Description
score string true none none

Ticket

{
  "id": 0,
  "identifier": "string",
  "status": 0,
  "status_name": "string",
  "link": "string",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for Ticket endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
identifier string¦null false none none
status TicketStatusEnum true read-only * 0 - Unknown
* 1 - New
* 2 - In Progress
* 3 - On Hold
* 4 - Resolved
* 5 - Closed
* 6 - Canceled
status_name string¦null true read-only none
link string¦null true read-only none
last_checked_at string(date-time)¦null true read-only none
created_at string(date-time) true read-only none
updated_at string(date-time) true read-only none

TicketStatusEnum

0

Properties

Name Type Required Restrictions Description
anonymous integer false none * 0 - Unknown
* 1 - New
* 2 - In Progress
* 3 - On Hold
* 4 - Resolved
* 5 - Closed
* 6 - Canceled

Enumerated Values

Property Value
anonymous 0
anonymous 1
anonymous 2
anonymous 3
anonymous 4
anonymous 5
anonymous 6

Topic

{
  "id": 0,
  "title": "string",
  "slug": "string",
  "is_available": true,
  "subtopics": [
    {
      "id": 0,
      "title": "string",
      "slug": "string",
      "description": "string",
      "is_available": true,
      "default_severity": 0,
      "security_check": 0,
      "remediation": "string",
      "remediation_effort": 0,
      "remediation_priority": 0
    }
  ]
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true read-only none
slug string true read-only none
is_available boolean true read-only none
subtopics [SubTopic] true read-only none

TypeEf5Enum

"ip"

Properties

Name Type Required Restrictions Description
anonymous string false none * ip - ip
* ip-range - ip-range
* ip-subnet - ip-subnet
* fqdn - fqdn
* domain - domain
* keyword - keyword
* other - other

Enumerated Values

Property Value
anonymous ip
anonymous ip-range
anonymous ip-subnet
anonymous fqdn
anonymous domain
anonymous keyword
anonymous other

UpdateAutoTagPolicy

{
  "id": 0,
  "title": "string",
  "is_enabled": true,
  "tag": "string",
  "tag_id": 0,
  "tag_value": "string",
  "filters": "string",
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true none none
is_enabled boolean true none none
tag string true write-only none
tag_id integer true read-only none
tag_value string true read-only none
filters string true read-only none
organization integer true read-only none
created_at string(date-time) true read-only none
updated_at string(date-time) true read-only none

UpdateInsightPolicy

{
  "id": 0,
  "title": "string",
  "description": "string",
  "is_enabled": true,
  "severity": 0,
  "created_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "organization": 0,
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "active_vulnerabilities": "string",
  "filters": "string",
  "already_applied": true
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
title string true none none
description string false none none
is_enabled boolean false none none
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
created_by UserLite true read-only none
organization integer true read-only none
created_at string(date-time)¦null true read-only none
updated_at string(date-time)¦null true read-only none
active_vulnerabilities string true read-only none
filters string true read-only none
already_applied boolean true read-only none

User

{
  "id": 0,
  "username": "string",
  "first_name": "string",
  "last_name": "string",
  "email": "user@example.com",
  "last_login": "2019-08-24T14:15:22Z",
  "is_superuser": true,
  "is_staff": true,
  "is_active": true,
  "changed_first_password": true,
  "orgs": {
    "property1": null,
    "property2": null
  },
  "current_org": {
    "property1": null,
    "property2": null
  },
  "is_org_admin": true,
  "role": 2,
  "auth_token": "string",
  "dark_mode": true,
  "suborgs": {
    "property1": null,
    "property2": null
  },
  "asset_assets": "string",
  "assetgroup_assetgroups": "string",
  "vulnerability_vulnerabilities": "string",
  "from_sso": true,
  "emails_subscribed": "string",
  "intercom": "string"
}

Serializer for User endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
username string true none Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.
first_name string false none none
last_name string false none none
email string(email) true none none
last_login string(date-time)¦null true read-only none
is_superuser boolean true read-only Designates that this user has all permissions without explicitly assigning them.
is_staff boolean true read-only Designates whether the user can log into this admin site.
is_active boolean true read-only Designates whether this user should be treated as active. Unselect this instead of deleting accounts.
changed_first_password boolean true read-only none
orgs object true read-only Return user's organizations.
» additionalProperties any false none none
current_org object true read-only Return current active organization.
» additionalProperties any false none none
is_org_admin boolean true read-only Check if user is an organization adminisrator.
role number false none none

oneOf

Name Type Required Restrictions Description
» anonymous RoleEnum false none * 2 - Standard
* 3 - Auditor
* 4 - Organization Admin

xor

Name Type Required Restrictions Description
» anonymous NullEnum false none none

continued

Name Type Required Restrictions Description
auth_token string true read-only none
dark_mode boolean true read-only none
suborgs object true read-only Return user's suborganizations.
» additionalProperties any false none none
asset_assets string true read-only none
assetgroup_assetgroups string true read-only none
vulnerability_vulnerabilities string true read-only none
from_sso boolean true read-only none
emails_subscribed string true read-only none
intercom string true read-only none

UserLite

{
  "id": 0,
  "email": "user@example.com"
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
email string(email) true none none

Vulnerability

{
  "id": 0,
  "user_friendly_id": "string",
  "patrowl_id": -2147483648,
  "asset": 0,
  "asset_id": "string",
  "organization": 0,
  "asset_value": "string",
  "asset_type": "string",
  "severity": 0,
  "cvss_vector": "string",
  "cvss_score": "string",
  "status": "new",
  "title": "string",
  "description": "string",
  "description_html": "string",
  "source": "string",
  "external_id": null,
  "category": "string",
  "business_impacts": [
    "string"
  ],
  "last_ticket": "string",
  "has_exploit": true,
  "solution_headline": "string",
  "solution": "string",
  "solution_html": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "owners": [
    0
  ],
  "solution_duedate": "2019-08-24T14:15:22Z",
  "is_quickwin": true,
  "is_auto": true,
  "is_greybox": true,
  "is_overdue": "string",
  "remediation_date": "2019-08-24T14:15:22Z",
  "last_status_update": "2019-08-24T14:15:22Z",
  "found_at": "2019-08-24T14:15:22Z",
  "last_checked_at": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "attachments": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "solution_owners": [
    0
  ],
  "suborganizations": "string",
  "external_vulnerability": {
    "id": 0,
    "title": "string",
    "description": "string",
    "severity": 0,
    "solution_priority": "urgent",
    "solution_effort": "low",
    "cvss_vector": "string",
    "solution_headline": "string",
    "solution": "string"
  },
  "last_updated_by": {
    "id": 0,
    "email": "user@example.com"
  },
  "updated_by_user_at": "2019-08-24T14:15:22Z"
}

Serializer for Vulnerability endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
user_friendly_id string true read-only none
patrowl_id integer¦null false none none
asset integer true none none
asset_id string true read-only Return the asset id.
organization integer¦null false none none
asset_value string true read-only Return the asset value.
asset_type string true read-only Return the asset value.
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
cvss_vector string¦null false none none
cvss_score string true read-only none
status Status9fcEnum false none * new - New
* ack - Acknowledged
* assigned - Assigned
* patched - Patched
* closed - Closed
* closed-benign - Closed (Benign)
* closed-fp - Closed (False-Positive)
* closed-duplicate - Closed (Duplicate)
* closed-workaround - Closed (Workaround)
* closed-risk-acceptance - Closed (Risk acceptance)
title string false none none
description string false none none
description_html string true read-only none
source string false none none
external_id any false none none
category string false none none
business_impacts [string]¦null false none none
last_ticket string true read-only none
has_exploit boolean false none none
solution_headline string¦null false none none
solution string false none none
solution_html string true read-only none
solution_priority SolutionPriorityEnum false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening
solution_effort SolutionEffortEnum false none * low - Low
* medium - Medium
* high - High
solution_gain integer false none none
owners [integer] false write-only none
solution_duedate string(date-time)¦null false none none
is_quickwin boolean false none none
is_auto boolean false none none
is_greybox boolean false none none
is_overdue string true read-only none
remediation_date string(date-time)¦null false none none
last_status_update string(date-time) false none none
found_at string(date-time)¦null false none none
last_checked_at string(date-time)¦null false none none
created_at string(date-time) false none none
updated_at string(date-time) false none none
reteststatus string true read-only none
ticketstatus integer false none none
is_retestable boolean true read-only Check if the vuln is retestable

Returns:
bool: False if vuln has no patrowl_id/org is in PoC/asset is not pentested
attachments string true read-only none
vuln_owners string true read-only none
vuln_solution_owners string true read-only none
solution_owners [integer] false write-only none
suborganizations string true read-only none
external_vulnerability ExternalVulnerability true read-only Serializer for ExternalV Vulnerabilities
last_updated_by VulnerabilityUser true read-only none
updated_by_user_at string(date-time)¦null false none none

VulnerabilityLite

{
  "id": 0,
  "user_friendly_id": "string",
  "description": "string",
  "solution_headline": "string",
  "solution_priority": "urgent",
  "solution_effort": "low",
  "solution_gain": -2147483648,
  "is_quickwin": true,
  "title": "string",
  "source": "string",
  "status": "new",
  "severity": 0,
  "asset_id": "string",
  "asset_value": "string",
  "asset_criticality": "string",
  "vuln_owners": "string",
  "vuln_solution_owners": "string",
  "asset": 0,
  "reteststatus": "string",
  "ticketstatus": -2147483648,
  "is_retestable": true,
  "last_ticket": "string",
  "solution_duedate": "2019-08-24T14:15:22Z",
  "created_at": "2019-08-24T14:15:22Z"
}

Lite Serializer for Vulnerability endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
user_friendly_id string true read-only none
description string false none none
solution_headline string¦null false none none
solution_priority SolutionPriorityEnum false none * urgent - Urgent
* moderate - Moderate
* hardening - Hardening
solution_effort SolutionEffortEnum false none * low - Low
* medium - Medium
* high - High
solution_gain integer false none none
is_quickwin boolean false none none
title string false none none
source string false none none
status Status9fcEnum false none * new - New
* ack - Acknowledged
* assigned - Assigned
* patched - Patched
* closed - Closed
* closed-benign - Closed (Benign)
* closed-fp - Closed (False-Positive)
* closed-duplicate - Closed (Duplicate)
* closed-workaround - Closed (Workaround)
* closed-risk-acceptance - Closed (Risk acceptance)
severity RemediationPriorityEnum false none * 0 - Info
* 1 - Low
* 2 - Medium
* 3 - High
* 4 - Critical
asset_id string true read-only Return the asset value.
asset_value string true read-only Return the asset value.
asset_criticality string true read-only Return the asset criticality.
vuln_owners string true read-only none
vuln_solution_owners string true read-only none
asset integer true none none
reteststatus string true read-only none
ticketstatus integer false none none
is_retestable boolean true read-only Check if the vuln is retestable

Returns:
bool: False if vuln has no patrowl_id/org is in PoC/asset is not pentested
last_ticket string true read-only none
solution_duedate string(date-time)¦null false none none
created_at string(date-time) false none none

VulnerabilityUser

{
  "id": 0,
  "email": "user@example.com"
}

Properties

Name Type Required Restrictions Description
id integer true read-only none
email string(email) true none none

WebPortLite

{
  "id": 0,
  "number": -2147483648,
  "protocol": "tcp",
  "is_ssl": true,
  "service_name": "string",
  "state": "open",
  "banners": [
    {
      "id": 0,
      "host": "string",
      "port": 0,
      "text": "string"
    }
  ]
}

Lite serializer for Port endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
number integer false none none
protocol ProtocolEnum false none * tcp - TCP
* udp - UDP
is_ssl boolean false none none
service_name string¦null false none none
state StateEnum false none * open - Open
* filtered - Filtered
* closed - Closed
* unknown - Unknown
banners [Banner] false none [Serializer for Banner endpoint.]

WebServer

{
  "id": 0,
  "ports": [
    {
      "id": 0,
      "number": -2147483648,
      "protocol": "tcp",
      "is_ssl": true,
      "service_name": "string",
      "state": "open",
      "banners": [
        {
          "id": 0,
          "host": "string",
          "port": 0,
          "text": "string"
        }
      ]
    }
  ],
  "host": "string",
  "url": "string",
  "server": "string",
  "path": "string",
  "title": "string",
  "asset": 0,
  "response_time": "string",
  "status_code": "string",
  "content_length": "string",
  "content_type": "string",
  "jarm": "string",
  "favicon_hash": "string",
  "technologies": [
    null
  ],
  "ips": "string",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z"
}

Serializer for WebServer endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
ports [WebPortLite] false none [Lite serializer for Port endpoint.]
host string false none none
url string false none none
server string¦null false none none
path string false none none
title string¦null false none none
asset integer¦null false none none
response_time string¦null false none none
status_code string¦null false none none
content_length string¦null false none none
content_type string¦null false none none
jarm string¦null false none none
favicon_hash string¦null false none none
technologies [any] true read-only none
ips string true read-only none
created_at string(date-time)¦null false none none
updated_at string(date-time)¦null false none none

WebServerLite

{
  "id": 0,
  "url": "string",
  "server": "string",
  "title": "string"
}

Lite Serializer for WebServer endpoint.

Properties

Name Type Required Restrictions Description
id integer true read-only none
url string false none none
server string¦null false none none
title string¦null false none none

WriteGreyboxRequest

{
  "user_friendly_id": "string",
  "requested_by": 0,
  "started_at": "2019-08-24T14:15:22Z",
  "finished_at": "2019-08-24T14:15:22Z",
  "in_scope": "string",
  "comments": "string",
  "contact_info": "string",
  "complexity": 1,
  "organization": 0
}

Serializer for Greybox Request class

Properties

Name Type Required Restrictions Description
user_friendly_id string true read-only none
requested_by integer¦null false none none
started_at string(date-time)¦null false none none
finished_at string(date-time)¦null false none none
in_scope string false none Insert assets
comments string false none Additional information about the assessment:
contact_info string false none Insert contact information: name + email + phone number
complexity ComplexityEnum false none * 1 - Low
* 2 - Medium
* 3 - High
organization integer true none none

add_owners

{
  "users_id": [
    null
  ]
}

Properties

Name Type Required Restrictions Description
users_id [any] true none none

assets_group_add_assets

{
  "assets_id": [
    null
  ]
}

Properties

Name Type Required Restrictions Description
assets_id [any] true none none

assets_group_add_tag

{
  "value": "string"
}

Properties

Name Type Required Restrictions Description
value string true none none

bulk_remove_owners

{
  "ids": [
    null
  ]
}

Properties

Name Type Required Restrictions Description
ids [any] true none none

create_asset

{
  "organization": 0,
  "value": "string",
  "description": "string",
  "criticality": 1,
  "is_monitored": true,
  "exposure": "unknown"
}

Properties

Name Type Required Restrictions Description
organization integer true none none
value string true none none
description string false none none
criticality CriticalityEnum false none * 1 - Low
* 2 - Medium
* 3 - High
is_monitored boolean false none none
exposure ExposureEnum false none * unknown - Unknown
* external - External
* internal - Internal
* restricted - Restricted

custom_remediations_add_owners

{
  "users_id": [
    null
  ]
}

Properties

Name Type Required Restrictions Description
users_id [any] true none none

custom_remediations_add_vulnerabilities

{
  "vulnerabilities_id": [
    null
  ]
}

Properties

Name Type Required Restrictions Description
vulnerabilities_id [any] true none none

response_assets_group_add_tag

{
  "status": "string",
  "data": {
    "id": 0,
    "value": "string",
    "organization": 0
  }
}

Properties

Name Type Required Restrictions Description
status string true none none
data AssetTag true none AssetTag DRF Serializer definition.

retests_update_comment

{
  "comment": "string"
}

Properties

Name Type Required Restrictions Description
comment string true none none

upload_file_attachements

{
  "title": "string",
  "file": "http://example.com"
}

Properties

Name Type Required Restrictions Description
title string true none none
file string(uri) true none none

© 2020-2024 Patrowl.io - All rights reserved.