---
title: Search Application Token Account
slug: kron-pam-api-collection-381-patch3/search-application-token-account
docTags: 
createdAt: 2026-10-21T06:07:16.182Z
---

{
  "id": "yqKPtIz8VsbC6fc8WcloK",
  "type": "api-oas-v2",
  "data": {
    "method": "POST",
    "url": "{{url}}/aioc-rest-web/rest/aapm/searchAapmAccounts",
    "name": "",
    "description": "<h3><strong>Request Overview</strong></h3>\n<p>The <code>Search Application Token Account</code> API allows users to query application token accounts as a filter. If no value is entered, all records will be returned.</p>\n<p>The <strong>important fields</strong> returned in the response are:</p>\n<ul>\n<li>\n<p><strong><code>applicationName</code></strong> (<code>string</code>)</p>\n<ul>\n<li>\n<p>Filters token accounts by their application name.</p>\n</li>\n<li>\n<p>Leave empty to return all accounts.</p>\n</li>\n</ul>\n</li>\n<li>\n<p><strong><code>applicationIPs</code></strong> (<code>array of strings)</code></p>\n<ul>\n<li>\n<p>Filters accounts by allowed IP addresses in CIDR format (e.g., <code>\"0.0.0.0/0\"</code> or <code>\"192.168.1.1\"</code>).</p>\n</li>\n<li>\n<p>Optional field.</p>\n</li>\n</ul>\n</li>\n<li>\n<p><strong><code>sapmAccounts</code></strong> (<code>array of integers</code>)</p>\n<ul>\n<li>\n<p>Filters tokens associated with specific SAPM account IDs.</p>\n</li>\n<li>\n<p>Optional field.</p>\n</li>\n</ul>\n</li>\n</ul>\n<p><em>To list all tokens, send an empty body</em></p>\n<hr>\n<h3>Search Application Token Account parameters</h3>\n<p><code>POST /rest/aapm/searchAapmAccounts</code> accepts <code>AapmAccountSearchRequestModel</code>. Sending <code>{}</code> applies no filters and returns all AAPM accounts accessible to the session user.</p>\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n<table><thead><tr><th align=\"left\">JSON field</th><th align=\"left\">Type</th><th align=\"left\">Required</th><th align=\"left\">Description</th></tr></thead><tbody><tr><td align=\"left\"><code>dbId</code></td><td align=\"left\">Array[Long]</td><td align=\"left\">No</td><td align=\"left\">Filter by AAPM account database IDs.</td></tr><tr><td align=\"left\"><code>token</code></td><td align=\"left\">Array[String]</td><td align=\"left\">No</td><td align=\"left\">Filter by application tokens.</td></tr><tr><td align=\"left\"><code>level</code></td><td align=\"left\">SecurityLevel</td><td align=\"left\">No</td><td align=\"left\">Filter by security level.</td></tr><tr><td align=\"left\"><code>applicationName</code></td><td align=\"left\">String</td><td align=\"left\">No</td><td align=\"left\">Filter by application name. Empty string is ignored.</td></tr><tr><td align=\"left\"><code>applicationIPs</code></td><td align=\"left\">Array[String]</td><td align=\"left\">No</td><td align=\"left\">Filter by allowed client IP addresses.</td></tr><tr><td align=\"left\"><code>eventUserId</code></td><td align=\"left\">Array[String]</td><td align=\"left\">No</td><td align=\"left\">Filter by event-user UUIDs.</td></tr><tr><td align=\"left\"><code>sapmAccounts</code></td><td align=\"left\">Array[Long]</td><td align=\"left\">No</td><td align=\"left\">Filter by linked SAPM account IDs.</td></tr><tr><td align=\"left\"><code>sapmGroups</code></td><td align=\"left\">Array[Long]</td><td align=\"left\">No</td><td align=\"left\">Filter by linked SAPM group IDs.</td></tr><tr><td align=\"left\"><code>firstResult</code></td><td align=\"left\">Integer</td><td align=\"left\">No</td><td align=\"left\">Zero-based result offset.</td></tr><tr><td align=\"left\"><code>maxResult</code></td><td align=\"left\">Integer</td><td align=\"left\">No</td><td align=\"left\">Maximum number of results to return.</td></tr></tbody></table>",
    "contentType": "application/json",
    "request": {
      "headerParameters": [
        {
          "name": "x-xsrf-token",
          "description": "",
          "default": "{{csrftoken}}",
          "value": "{{csrftoken}}",
          "type": "string"
        }
      ],
      "queryParameters": [],
      "pathParameters": [
        {
          "name": "url",
          "description": "",
          "default": "url",
          "value": "url",
          "type": "string"
        }
      ],
      "bodyDataParameters": [
        {
          "name": "body",
          "description": "",
          "default": "{\n  \"applicationName\": \"ExampleApplication\",\n  \"applicationIPs\": [\n    \"192.0.2.10\"\n  ],\n  \"sapmAccounts\": [\n    100001\n  ],\n  \"firstResult\": 0,\n  \"maxResult\": 50\n}",
          "value": "{\n  \"applicationName\": \"ExampleApplication\",\n  \"applicationIPs\": [\n    \"192.0.2.10\"\n  ],\n  \"sapmAccounts\": [\n    100001\n  ],\n  \"firstResult\": 0,\n  \"maxResult\": 50\n}",
          "type": "object"
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "Search Application Token Account",
        "jsonExample": "[\n  {\n    \"dbId\": 200001,\n    \"applicationName\": \"ExampleApplication\",\n    \"applicationIPs\": [\n      \"192.0.2.10/32\"\n    ],\n    \"sapmAccounts\": [\n      100001\n    ],\n    \"sapmGroups\": [],\n    \"restrictions\": {\n      \"allowListingAccounts\": true,\n      \"maxUsageCount\": 50\n    },\n    \"level\": \"BASIC_PIN_PATH_HASH\",\n    \"properties\": {},\n    \"token\": \"REDACTED_EXAMPLE_TOKEN\",\n    \"lastAccessTime\": null,\n    \"numberOfUsage\": 0\n  }\n]"
      }
    ],
    "examples": {
      "languages": [
        {
          "id": "OsAnhLi8Q6edxibI27Z5D",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request POST \\\n     --url {{url}}/aioc-rest-web/rest/aapm/searchAapmAccounts \\\n     --header 'accept: application/json' \\\n     --header 'content-type: application/json' \\\n     --header 'x-xsrf-token: {{csrftoken}}' \\\n     --data '\"{\\n  \\\"applicationName\\\": \\\"ExampleApplication\\\",\\n  \\\"applicationIPs\\\": [\\n    \\\"192.0.2.10\\\"\\n  ],\\n  \\\"sapmAccounts\\\": [\\n    100001\\n  ],\\n  \\\"firstResult\\\": 0,\\n  \\\"maxResult\\\": 50\\n}\"'"
        },
        {
          "id": "S2GWnl6Nw_XV514LqsUUN",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\nmyHeaders.append(\"x-xsrf-token\", \"{{csrftoken}}\");\n\nvar raw = JSON.stringify(\"{\\n  \\\"applicationName\\\": \\\"ExampleApplication\\\",\\n  \\\"applicationIPs\\\": [\\n    \\\"192.0.2.10\\\"\\n  ],\\n  \\\"sapmAccounts\\\": [\\n    100001\\n  ],\\n  \\\"firstResult\\\": 0,\\n  \\\"maxResult\\\": 50\\n}\");\n\nvar requestOptions = {\n   method: 'POST',\n   headers: myHeaders,\n   body: raw,\n   redirect: 'follow'\n};\n\nfetch(\"{{url}}/aioc-rest-web/rest/aapm/searchAapmAccounts\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "itlSu7_3Gp1rOfHZnKtWx",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"{{url}}/aioc-rest-web/rest/aapm/searchAapmAccounts\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Post.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\nrequest[\"x-xsrf-token\"] = \"{{csrftoken}}\"\nrequest.body = JSON.dump(\"{\\n  \\\"applicationName\\\": \\\"ExampleApplication\\\",\\n  \\\"applicationIPs\\\": [\\n    \\\"192.0.2.10\\\"\\n  ],\\n  \\\"sapmAccounts\\\": [\\n    100001\\n  ],\\n  \\\"firstResult\\\": 0,\\n  \\\"maxResult\\\": 50\\n}\")\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "vhNQRYyvETcbO3shqBQXY",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"{{url}}/aioc-rest-web/rest/aapm/searchAapmAccounts\"\n\npayload = json.dumps(\"{\\n  \\\"applicationName\\\": \\\"ExampleApplication\\\",\\n  \\\"applicationIPs\\\": [\\n    \\\"192.0.2.10\\\"\\n  ],\\n  \\\"sapmAccounts\\\": [\\n    100001\\n  ],\\n  \\\"firstResult\\\": 0,\\n  \\\"maxResult\\\": 50\\n}\")\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json',\n   'x-xsrf-token': '{{csrftoken}}'\n}\n\nresponse = requests.request(\"POST\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "OsAnhLi8Q6edxibI27Z5D"
    },
    "results": {
      "languages": [
        {
          "id": "2NRHcYpuilXF_TeT-DfIt",
          "language": "200",
          "code": "[\n  {\n    \"dbId\": 200001,\n    \"applicationName\": \"ExampleApplication\",\n    \"applicationIPs\": [\n      \"192.0.2.10/32\"\n    ],\n    \"sapmAccounts\": [\n      100001\n    ],\n    \"sapmGroups\": [],\n    \"restrictions\": {\n      \"allowListingAccounts\": true,\n      \"maxUsageCount\": 50\n    },\n    \"level\": \"BASIC_PIN_PATH_HASH\",\n    \"properties\": {},\n    \"token\": \"REDACTED_EXAMPLE_TOKEN\",\n    \"lastAccessTime\": null,\n    \"numberOfUsage\": 0\n  }\n]"
        }
      ],
      "selectedLanguageId": "2NRHcYpuilXF_TeT-DfIt"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}