# Netskope

> Block and allow sites with Netskope URL lists, search alerts and events, manage users and groups, adjust users' risk scores, see Private Access apps and publishers, and start workflows on new alerts, admin changes and URL list changes.

App · 25 actions. Web page: https://docs.lodol.com/docs/integrations/netskope

## Actions

### Add URLs to list

Add URLs to a URL list, keeping the ones it has, such as to block a site.

**Inputs**

- URL list (`url_list_id`, number, required): The URL list. At least 1.
- URLs (`urls`, list, required): Domains, URLs or IP addresses, such as *.example.com, or regular expressions for a regular-expression list.
- Apply now (`apply_now`, true/false): Deploy the change at once, so policies use it. This applies every pending URL list change in the tenant, not only this one. Leave off to review and apply changes in Netskope, or with the Apply URL list changes step.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "data": {
      "json_version": 1,
      "type": "exact",
      "urls": [
        "example"
      ]
    },
    "id": 1,
    "modify_by": "example",
    "modify_time": "example",
    "modify_type": "Created",
    "name": "example",
    "pending": 1
  }
}
```

### Add users to group

Add users to a group, such as to put them under a stricter policy.

**Inputs**

- Group (`group_id`, text, required): The group.
- Users (`user_ids`, list, required): The users.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "group_id": "example",
    "user_ids": [
      "example"
    ]
  }
}
```

### Apply URL list changes

Deploy every pending URL list change in the tenant, so policies use it.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "deployed": true
  }
}
```

### Create group

Create a user group, optionally with its first members.

**Inputs**

- Name (`name`, text, required): The group's name.
- Users (`user_ids`, list): Users to add to the group.
- External ID (`external_id`, text): The group's ID in your identity provider, if you keep one.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "displayName": "example",
    "externalId": "example",
    "id": "example",
    "members": [
      {
        "display": "example",
        "type": "example",
        "value": "example"
      }
    ]
  }
}
```

### Create URL list

Create a URL list that policies can use to block or allow sites.

**Inputs**

- Name (`name`, text, required): A unique name for the list.
- URLs (`urls`, list, required): Domains, URLs or IP addresses, such as *.example.com, or regular expressions for a regular-expression list.
- Type (`type`, text): Whether the entries are exact domains, URLs and IP addresses or regular expressions. Leave empty for exact. One of: `exact` (Exact (domains, URLs and IP addresses)), `regex` (Regular expressions).
- Apply now (`apply_now`, true/false): Deploy the change at once, so policies use it. This applies every pending URL list change in the tenant, not only this one. Leave off to review and apply changes in Netskope, or with the Apply URL list changes step.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "data": {
      "json_version": 1,
      "type": "exact",
      "urls": [
        "example"
      ]
    },
    "id": 1,
    "modify_by": "example",
    "modify_time": "example",
    "modify_type": "Created",
    "name": "example",
    "pending": 1
  }
}
```

### Create user

Add a user to Netskope, so policies and groups can include them.

**Inputs**

- User name (`user_name`, text, required): The user name, usually the user's email address or user principal name.
- Email (`email`, text, required): The user's email address.
- First name (`given_name`, text): The user's first name.
- Last name (`family_name`, text): The user's last name.
- External ID (`external_id`, text): The user's ID in your identity provider, if you keep one.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "active": true,
    "emails": [
      {
        "primary": true,
        "type": "example",
        "value": "example"
      }
    ],
    "externalId": "example",
    "id": "example",
    "name": {
      "familyName": "example",
      "givenName": "example"
    },
    "userName": "example"
  }
}
```

### Delete group

Delete a user group. Its users stay in Netskope.

**Inputs**

- Group (`group_id`, text, required): The group.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "deleted": true,
    "id": "example"
  }
}
```

### Delete URL list

Delete a URL list. A list a policy still uses can't be deleted.

**Inputs**

- URL list (`url_list_id`, number, required): The URL list. At least 1.
- Apply now (`apply_now`, true/false): Deploy the change at once, so policies use it. This applies every pending URL list change in the tenant, not only this one. Leave off to review and apply changes in Netskope, or with the Apply URL list changes step.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "deleted": true,
    "id": "example"
  }
}
```

### Delete user

Remove a user from Netskope.

**Inputs**

- User (`netskope_user_id`, text, required): The user.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "deleted": true,
    "id": "example"
  }
}
```

### Get group

Get a group, and optionally its members.

**Inputs**

- Group (`group_id`, text, required): The group.
- Include members (`include_members`, true/false): Also list the group's members. Your tenant needs Netskope's group membership query setting turned on for this.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "displayName": "example",
    "externalId": "example",
    "id": "example",
    "members": [
      {
        "display": "example",
        "type": "example",
        "value": "example"
      }
    ]
  }
}
```

### Get URL list

Get a URL list with its URLs, type and who changed it last.

**Inputs**

- URL list (`url_list_id`, number, required): The URL list. At least 1.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "data": {
      "json_version": 1,
      "type": "exact",
      "urls": [
        "example"
      ]
    },
    "id": 1,
    "modify_by": "example",
    "modify_time": "example",
    "modify_type": "Created",
    "name": "example",
    "pending": 1
  }
}
```

### Get user

Get a user with their user name, emails and whether they are active.

**Inputs**

- User (`netskope_user_id`, text, required): The user.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "active": true,
    "emails": [
      {
        "primary": true,
        "type": "example",
        "value": "example"
      }
    ],
    "externalId": "example",
    "id": "example",
    "name": {
      "familyName": "example",
      "givenName": "example"
    },
    "userName": "example"
  }
}
```

### Get user risk scores

Get users' current confidence index (UCI), Netskope's risk score from 0 (risky) to 1000 (trusted).

**Inputs**

- User emails (`emails`, list, required): The users' email addresses, as Netskope knows them.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "usersUci": [
      {
        "confidences": [
          {
            "confidenceScore": 1,
            "start": 1
          }
        ],
        "userId": "example"
      }
    ]
  }
}
```

### List alerts

List alerts, such as DLP, malware, policy and anomaly alerts, over a period, optionally of one type or matching a query.

**Inputs**

- From (`start_time`, date and time): Only those at or after this time. Leave empty for the last 24 hours.
- To (`end_time`, date and time): Only those up to this time. Leave empty for now.
- Alert type (`alert_type`, text): Only alerts of this type. Leave empty for every type. One of: `DLP` (Data loss prevention (DLP)), `Malware`, `policy`, `malsite` (Malicious site), `Compromised Credential`, `anomaly`, `uba` (Behavior analytics (UBA)), `watchlist`, `quarantine`, `Remediation`, `Security Assessment`, `Legal Hold`.
- Acknowledged (`acknowledged`, text): Only acknowledged alerts, or only ones not acknowledged yet. Leave empty for both. One of: `yes` (Acknowledged only), `no` (Not acknowledged only).
- Query (`query`, text): A Netskope query to narrow the results, such as app eq 'Dropbox' or user eq 'ann@example.com'.
- How many (`limit`, number): How many to return, up to 10000. Leave empty for 100. From 1 to 10000.
- Skip (`offset`, number): How many to skip, to read the next page. At least 0.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "ok": 1,
    "result": [
      {
        "_id": "example",
        "_insertion_epoch_timestamp": 1,
        "access_method": "example",
        "acked": "example",
        "action": "example",
        "activity": "example",
        "alert_name": "example",
        "alert_type": "example",
        "app": "example",
        "appcategory": "example",
        "category": "example",
        "device": "example",
        "dlp_profile": "example",
        "domain": "example",
        "dst_country": "example",
        "hostname": "example",
        "malware_name": "example",
        "policy": "example",
        "severity": "example",
        "site": "example",
        "src_location": "example",
        "timestamp": 1,
        "url": "example",
        "user": "example"
      }
    ]
  }
}
```

### List events

List events of one type over a period, such as cloud app activity, websites visited or admin changes.

**Inputs**

- Event type (`event_type`, text, required): Which events. One of: `application` (Application (activity in cloud apps)), `page` (Page (websites visited)), `network` (Network (traffic through Cloud Firewall and Private Access)), `audit` (Audit (changes made by admins)), `infrastructure` (Infrastructure (Netskope's own components)).
- From (`start_time`, date and time): Only those at or after this time. Leave empty for the last 24 hours.
- To (`end_time`, date and time): Only those up to this time. Leave empty for now.
- Query (`query`, text): A Netskope query to narrow the results, such as app eq 'Dropbox' or user eq 'ann@example.com'.
- How many (`limit`, number): How many to return, up to 10000. Leave empty for 100. From 1 to 10000.
- Skip (`offset`, number): How many to skip, to read the next page. At least 0.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "ok": 1,
    "result": [
      {
        "_id": "example",
        "_insertion_epoch_timestamp": 1,
        "access_method": "example",
        "action": "example",
        "activity": "example",
        "app": "example",
        "audit_log_event": "example",
        "category": "example",
        "domain": "example",
        "dstip": "example",
        "hostname": "example",
        "severity_level": 1,
        "site": "example",
        "srcip": "example",
        "supporting_data": {},
        "timestamp": 1,
        "type": "example",
        "url": "example",
        "user": "example"
      }
    ]
  }
}
```

### List groups

List the user groups in Netskope, or find one by name.

**Inputs**

- Name (`name`, text): Only the group with this name.
- How many (`count`, number): How many to return, up to 100. Leave empty for 100. From 1 to 100.
- Start at (`start_index`, number): Where to start, counting from 1, to read the next page. At least 1.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "Resources": [
      {
        "displayName": "example",
        "externalId": "example",
        "id": "example",
        "members": [
          {
            "display": "example",
            "type": "example",
            "value": "example"
          }
        ]
      }
    ],
    "itemsPerPage": 1,
    "startIndex": 1,
    "totalResults": 1
  }
}
```

### List private apps

List the private apps Netskope Private Access (NPA) publishes, with their hosts, ports and publishers.

**Inputs**

- Query (`query`, text): A Netskope query to narrow the results, such as app eq 'Dropbox' or user eq 'ann@example.com'.
- How many (`limit`, number): How many to return. Leave empty for all. From 1 to 10000.
- Skip (`offset`, number): How many to skip, to read the next page. At least 0.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "data": {
      "private_apps": [
        {
          "app_id": 1,
          "app_name": "example",
          "clientless_access": true,
          "host": "example",
          "modify_time": "example",
          "protocols": [
            {
              "port": "example",
              "type": "example"
            }
          ],
          "real_host": "example",
          "service_publisher_assignments": [
            {
              "primary": true,
              "publisher_id": 1,
              "publisher_name": "example",
              "reachability": {}
            }
          ],
          "tags": [
            {
              "tag_id": 1,
              "tag_name": "example"
            }
          ],
          "trust_self_signed_certs": true,
          "use_publisher_dns": true
        }
      ]
    },
    "status": "example",
    "total": 1
  }
}
```

### List publishers

List Private Access (NPA) publishers with whether each is connected, its version and how many apps it serves.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "data": {
      "publishers": [
        {
          "apps_count": 1,
          "assessment": {
            "hdd_free": "example",
            "ip_address": "example",
            "latency": 1,
            "version": "example"
          },
          "common_name": "example",
          "lbrokerconnect": true,
          "publisher_id": 1,
          "publisher_name": "example",
          "registered": true,
          "status": "example",
          "stitcher_pop": "example"
        }
      ]
    },
    "status": "example",
    "total": 1
  }
}
```

### List URL lists

List the tenant's URL lists with their URLs, type and whether a change is waiting to be applied.

**Inputs**

- Only pending changes (`only_pending`, true/false): Only lists with changes that haven't been applied yet.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "url_lists": [
      {
        "data": {
          "json_version": 1,
          "type": "exact",
          "urls": [
            "example"
          ]
        },
        "id": 1,
        "modify_by": "example",
        "modify_time": "example",
        "modify_type": "Created",
        "name": "example",
        "pending": 1
      }
    ]
  }
}
```

### List users

List the users provisioned in Netskope, or find one by user name, email or external ID.

**Inputs**

- User name (`user_name`, text): Only the user with this user name.
- Email (`email`, text): Only the user with this email address.
- External ID (`external_id`, text): Only the user with this ID from your identity provider.
- How many (`count`, number): How many to return, up to 100. Leave empty for 100. From 1 to 100.
- Start at (`start_index`, number): Where to start, counting from 1, to read the next page. At least 1.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "Resources": [
      {
        "active": true,
        "emails": [
          {
            "primary": true,
            "type": "example",
            "value": "example"
          }
        ],
        "externalId": "example",
        "id": "example",
        "name": {
          "familyName": "example",
          "givenName": "example"
        },
        "userName": "example"
      }
    ],
    "itemsPerPage": 1,
    "startIndex": 1,
    "totalResults": 1
  }
}
```

### Lower user risk score

Lower a user's confidence index (UCI) by a number of points, such as after another tool flags them, so risk-based policies treat them as riskier.

**Inputs**

- User email (`email`, text, required): The user's email address, as Netskope knows them.
- Points to take off (`score`, number, required): How many points to take off, from 1 to 1000. From 1 to 1000.
- Reason (`reason`, text): Why, shown in Netskope with the change.
- Source (`source`, text): What flagged the user, shown in Netskope. Leave empty for Lodol.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "email": "example",
    "response": {},
    "score": 1
  }
}
```

### Remove URLs from list

Take URLs off a URL list, keeping the rest, such as to unblock a site.

**Inputs**

- URL list (`url_list_id`, number, required): The URL list. At least 1.
- URLs (`urls`, list, required): The URLs to take off, exactly as they appear on the list.
- Apply now (`apply_now`, true/false): Deploy the change at once, so policies use it. This applies every pending URL list change in the tenant, not only this one. Leave off to review and apply changes in Netskope, or with the Apply URL list changes step.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "data": {
      "json_version": 1,
      "type": "exact",
      "urls": [
        "example"
      ]
    },
    "id": 1,
    "modify_by": "example",
    "modify_time": "example",
    "modify_type": "Created",
    "name": "example",
    "pending": 1
  }
}
```

### Remove users from group

Take users out of a group.

**Inputs**

- Group (`group_id`, text, required): The group.
- Users (`user_ids`, list, required): The users.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "group_id": "example",
    "user_ids": [
      "example"
    ]
  }
}
```

### Reset user risk scores

Reset users' confidence index (UCI) to 1000, such as once an investigation clears them.

**Inputs**

- User emails (`emails`, list, required): The users' email addresses, as Netskope knows them.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "emails": [
      "example"
    ],
    "response": {}
  }
}
```

### Update URL list

Rename a URL list, change its type, or replace all its URLs. Fields left empty stay as they are.

**Inputs**

- URL list (`url_list_id`, number, required): The URL list. At least 1.
- Name (`name`, text): The new name.
- URLs (`urls`, list): Every URL the list should hold, in place of the ones it has.
- Type (`type`, text): Exact entries or regular expressions. One of: `exact` (Exact (domains, URLs and IP addresses)), `regex` (Regular expressions).
- Apply now (`apply_now`, true/false): Deploy the change at once, so policies use it. This applies every pending URL list change in the tenant, not only this one. Leave off to review and apply changes in Netskope, or with the Apply URL list changes step.

**Outputs**

- `data` (object): The response from Netskope.

**Example output**

```json
{
  "data": {
    "data": {
      "json_version": 1,
      "type": "exact",
      "urls": [
        "example"
      ]
    },
    "id": 1,
    "modify_by": "example",
    "modify_time": "example",
    "modify_type": "Created",
    "name": "example",
    "pending": 1
  }
}
```
