# Get Destination Lists

```http
GET /destinationlists
```

API: Cisco Secure Access Destination Lists API (version 2.0.4)

Operation ID: getDestinationLists

Tags: Destination Lists, Secure Access

## Description

Get the destination lists in your organization.

## Servers

```json
[
  {
    "url": "https://api.sse.cisco.com/{basePath}",
    "variables": {
      "basePath": {
        "default": "policies/v2"
      }
    }
  }
]
```

## Authentication

Satisfy any one of the following alternatives. Within each alternative, all listed schemes are required. An empty object allows anonymous access.

```json
[
  {
    "oauthFlow": [
      "policies.destinationLists:read"
    ]
  }
]
```

### Security schemes

```json
{
  "oauthFlow": {
    "type": "oauth2",
    "description": "client credential flow",
    "flows": {
      "clientCredentials": {
        "tokenUrl": "https://api.sse.cisco.com/auth/v2/token",
        "scopes": {
          "policies.destinationLists:write": "Write policies destination lists",
          "policies.destinationLists:read": "Read policies destination lists",
          "policies.destinations:write": "Write policies destinations",
          "policies.destinations:read": "Read policies destinations"
        }
      }
    }
  }
}
```

## Parameters

| Name | In | Required | Type | Description |
| --- | --- | --- | --- | --- |
| page | query | no | integer (int32) | The number of a page in the collection. |
| limit | query | no | integer (int32) | The number of records in the collection to return on the page. |

### Parameter definitions

```json
[
  {
    "name": "page",
    "in": "query",
    "description": "The number of a page in the collection.",
    "required": false,
    "schema": {
      "default": 1,
      "type": "integer",
      "format": "int32",
      "minimum": 1
    },
    "example": 4,
    "$$ref": "#/components/parameters/paginationPageParam"
  },
  {
    "name": "limit",
    "in": "query",
    "description": "The number of records in the collection to return on the page.",
    "required": false,
    "schema": {
      "default": 100,
      "type": "integer",
      "format": "int32",
      "minimum": 1,
      "maximum": 100
    },
    "example": 50,
    "$$ref": "#/components/parameters/paginationLimitParam"
  }
]
```

## Responses

### 200

OK

```json
{
  "description": "OK",
  "headers": {
    "Content-Type": {
      "schema": {
        "type": "string"
      },
      "description": "The MIME content type of the response body.",
      "example": "application/json",
      "$$ref": "#/components/headers/Content-Type"
    },
    "Date": {
      "schema": {
        "type": "string",
        "pattern": "^[0-90-90-90-9-0-90-9-0-90-9T0-90-9:0-90-9:0-90-9Z]+$"
      },
      "description": "The timestamp of the response.",
      "example": "2023-03-14T18:34:25Z",
      "$$ref": "#/components/headers/Date"
    }
  },
  "content": {
    "application/json": {
      "schema": {
        "type": "object",
        "description": "The status, metadata, and properties of the destination lists.",
        "required": [
          "status",
          "meta",
          "data"
        ],
        "properties": {
          "status": {
            "type": "object",
            "required": [
              "code",
              "text"
            ],
            "description": "The status information for the response.",
            "properties": {
              "code": {
                "type": "integer",
                "description": "The HTTP status code of the response.",
                "example": 200
              },
              "text": {
                "type": "string",
                "description": "The HTTP message that describes the response.",
                "example": "OK"
              }
            },
            "example": {
              "code": 200,
              "text": "OK"
            },
            "$$ref": "#/components/schemas/status"
          },
          "meta": {
            "type": "object",
            "description": "The pagination information for the response.",
            "properties": {
              "page": {
                "type": "integer",
                "description": "The number of the page in the collection.",
                "example": 50
              },
              "limit": {
                "type": "integer",
                "description": "The maximum number of items the server returns on the page.",
                "example": 10
              },
              "total": {
                "type": "integer",
                "description": "The total number of items in the collection.",
                "example": 20
              }
            },
            "$$ref": "#/components/schemas/meta"
          },
          "data": {
            "type": "array",
            "description": "The list of destination lists.",
            "items": {
              "type": "object",
              "required": [
                "id",
                "organizationId",
                "access",
                "isGlobal",
                "name",
                "thirdpartyCategoryId",
                "createdAt",
                "modifiedAt",
                "isMspDefault",
                "markedForDeletion"
              ],
              "properties": {
                "id": {
                  "type": "integer",
                  "example": 1234567,
                  "description": "The unique ID of the destination list.",
                  "$$ref": "#/components/schemas/id"
                },
                "organizationId": {
                  "type": "integer",
                  "example": 2345678,
                  "description": "The organization ID.",
                  "$$ref": "#/components/schemas/organizationId"
                },
                "access": {
                  "type": "string",
                  "example": "none",
                  "description": "Configure your access rules to block or allow certain destination lists.\nNo support for the access type on destination lists.\nValid values are: `allow`, `block`, `url_proxy`, `no_decrypt`, `warn`, `none`, or `third_party_block`.",
                  "enum": [
                    "allow",
                    "block",
                    "url_proxy",
                    "no_decrypt",
                    "warn",
                    "none",
                    "thirdparty_block"
                  ],
                  "$$ref": "#/components/schemas/access"
                },
                "isGlobal": {
                  "type": "boolean",
                  "example": false,
                  "description": "Specifies whether the destination list is a global destination list.\nThere is only one default `allow` destination list and one default `block` destination list for an organization.\n**Note:** No support for global destination lists. When you creat a destination list, set the `isGlobal` field to `false`.",
                  "$$ref": "#/components/schemas/isGlobal"
                },
                "name": {
                  "type": "string",
                  "example": "Global Allow list",
                  "description": "The name of the destination list.",
                  "$$ref": "#/components/schemas/name"
                },
                "thirdpartyCategoryId": {
                  "type": "integer",
                  "example": 1,
                  "description": "The third-party category ID of the destination list."
                },
                "createdAt": {
                  "type": "integer",
                  "example": 1490206249,
                  "description": "The date and time when the system created the destination list."
                },
                "modifiedAt": {
                  "type": "integer",
                  "example": 1520476127,
                  "description": "The date and time when the system modified the destination list."
                },
                "isMspDefault": {
                  "type": "boolean",
                  "description": "Specifies whether MSP is the default.",
                  "example": false
                },
                "markedForDeletion": {
                  "type": "boolean",
                  "example": false,
                  "description": "Specifies whether the system marks the destination list for deletion."
                },
                "bundleTypeId": {
                  "type": "integer",
                  "enum": [
                    1,
                    2,
                    4
                  ],
                  "example": 2,
                  "description": "The type of the destination list.\nIn your policy rules, the system applies security controls to your destination lists.",
                  "$$ref": "#/components/schemas/bundleTypeId"
                },
                "meta": {
                  "type": "object",
                  "description": "The total number of each type of destination in the destination list. The fields in the `meta` object are optional.",
                  "properties": {
                    "destinationCount": {
                      "type": "integer",
                      "example": 5,
                      "description": "The total number of destinations in a destination list."
                    },
                    "domainCount": {
                      "type": "integer",
                      "example": 5,
                      "description": "The total number of domains in a destination list.\nDomains are part of the total number of destinations in a destination list."
                    },
                    "urlCount": {
                      "type": "integer",
                      "example": 0,
                      "description": "The total number of URLs in a destination list.\nUrls are part of the total number of destinations in a destination list."
                    },
                    "ipv4Count": {
                      "type": "integer",
                      "example": 0,
                      "description": "The total number of IPv4 addresses in a destination list.\nIPv4 addresses are part of the total number of destinations in a destination list."
                    },
                    "ipv6Count": {
                      "type": "integer",
                      "example": 0,
                      "description": "The total number of IPv6 addresses in a destination list.\nIPv6 addresses are part of the total number of destinations in a destination list."
                    },
                    "applicationCount": {
                      "type": "integer",
                      "example": 0,
                      "description": "The total number of applications in a destination list.\nApplications are part of the total number of destinations in a destination list."
                    }
                  },
                  "example": {
                    "domainCount": 1,
                    "urlCount": 0,
                    "ipv4Count": 1,
                    "ipv6Count": 0,
                    "destinationCount": 2,
                    "applicationCount": 0
                  }
                }
              },
              "example": {
                "id": 1234567,
                "organizationId": 2345678,
                "access": "none",
                "isGlobal": false,
                "name": "Global Allow List",
                "thirdpartyCategoryId": 0,
                "createdAt": 1490206249,
                "modifiedAt": 1520476127,
                "isMspDefault": false,
                "markedForDeletion": false,
                "bundleTypeId": 2,
                "meta": {
                  "destinationCount": 5,
                  "domainCount": 5,
                  "urlCount": 0,
                  "ipv4Count": 0,
                  "ipv6Count": 0,
                  "applicationCount": 0
                }
              },
              "$$ref": "#/components/schemas/DestinationListObject"
            }
          }
        },
        "$$ref": "#/components/schemas/PaginatedDestinationListsResponse"
      },
      "example": {
        "status": {
          "code": 200,
          "text": "OK"
        },
        "meta": {
          "page": 1,
          "limit": 100,
          "total": 100
        },
        "data": [
          {
            "id": 1234567,
            "organizationId": 2345678,
            "access": "allow",
            "isGlobal": true,
            "name": "Global Allow List",
            "thirdpartyCategoryId": 0,
            "createdAt": 1490206249,
            "modifiedAt": 1520476127,
            "isMspDefault": false,
            "markedForDeletion": false,
            "bundleTypeId": 2,
            "meta": {
              "destinationCount": 5,
              "domainCount": 5,
              "urlCount": 0,
              "ipv4Count": 0,
              "ipv6Count": 0,
              "applicationCount": 0
            }
          }
        ]
      }
    }
  }
}
```

### 400

Bad Request

```json
{
  "description": "Bad Request",
  "content": {
    "application/json": {
      "schema": {
        "type": "object",
        "description": "Bad Request",
        "properties": {
          "statusCode": {
            "type": "integer",
            "example": 400,
            "description": "HTTP status code"
          },
          "error": {
            "type": "string",
            "example": "Bad Request",
            "description": "A brief description of the error"
          },
          "message": {
            "type": "string",
            "example": "Validation Error"
          },
          "txId": {
            "type": "string",
            "example": "d479k9i2b723"
          }
        },
        "$$ref": "#/components/schemas/BadRequestError"
      },
      "examples": {
        "example_bad_request": {
          "summary": "Bad Request Example Response",
          "value": {
            "statusCode": 400,
            "error": "Bad Request",
            "message": "Validation Error",
            "txId": "d479k9i2b723-abdj1-672635-45362"
          },
          "$$ref": "#/components/examples/400BadRequestExample"
        }
      }
    }
  },
  "$$ref": "#/components/responses/BadRequest"
}
```

### 401

Unauthorized

```json
{
  "description": "Unauthorized",
  "content": {
    "application/json": {
      "schema": {
        "type": "object",
        "description": "Unauthorized",
        "properties": {
          "statusCode": {
            "type": "integer",
            "example": 401,
            "description": "HTTP status code"
          },
          "error": {
            "type": "string",
            "example": "Unauthorized",
            "description": "The authorization header is missing or the token is unauthorized."
          },
          "txId": {
            "type": "string",
            "example": "a478k9i2b723"
          }
        },
        "$$ref": "#/components/schemas/UnauthorizedError"
      }
    }
  },
  "$$ref": "#/components/responses/Unauthorized"
}
```

### 403

Forbidden

```json
{
  "description": "Forbidden",
  "content": {
    "application/json": {
      "schema": {
        "type": "object",
        "description": "Forbidden",
        "properties": {
          "statusCode": {
            "type": "integer",
            "example": 403,
            "description": "HTTP status code"
          },
          "error": {
            "type": "string",
            "example": "Forbidden",
            "description": "The token is invalid."
          },
          "txId": {
            "type": "string",
            "example": "a478k9i2b723"
          }
        },
        "$$ref": "#/components/schemas/ForbiddenError"
      }
    }
  },
  "$$ref": "#/components/responses/Forbidden"
}
```

### 404

Not Found

```json
{
  "description": "Not Found",
  "content": {
    "application/json": {
      "schema": {
        "type": "object",
        "description": "Not Found",
        "properties": {
          "statusCode": {
            "type": "integer",
            "example": 404,
            "description": "HTTP status code"
          },
          "error": {
            "type": "string",
            "example": "Not Found",
            "description": "A resource specified in the URL was not found."
          },
          "txId": {
            "type": "string",
            "example": "a478k9i2b723"
          }
        },
        "$$ref": "#/components/schemas/NotFoundError"
      }
    }
  },
  "$$ref": "#/components/responses/NotFound"
}
```

### 500

Internal Server Error

```json
{
  "description": "Internal Server Error",
  "content": {
    "application/json": {
      "schema": {
        "type": "object",
        "description": "Internal Server Error",
        "properties": {
          "statusCode": {
            "type": "integer",
            "example": 500,
            "description": "HTTP status code"
          },
          "error": {
            "type": "string",
            "example": "Internal Server Error",
            "description": "The server can not process the request."
          },
          "message": {
            "type": "string",
            "example": "An internal server error occurred"
          },
          "txId": {
            "type": "string",
            "example": "l477k9i2b893"
          }
        },
        "$$ref": "#/components/schemas/ServerError"
      }
    }
  },
  "$$ref": "#/components/responses/ServerErr"
}
```

## Additional OpenAPI fields

```json
{
  "__originalOperationId": "getDestinationLists"
}
```
