---
title: JSONpath in Python Tasks
slug: user-guide-10x/jsonpath-in-python-tasks
docTags: 
createdAt: 2025-06-18T11:01:36.088Z
---

﻿This topic contains JSONpath examples.

## Examples

See the following JSON document. It shows how JSONpath expressions can be added to it.

:::BlockQuote
\`\`\`json \{ "json\_response": \{ "entities": \[ \{ "id": "email\:android\@android.com", "name": "android\@android.com", "type": "EmailAddress", "count": 12 }, \{ "id": "email\:creative-review\@mopub.com", "name": "creative-review\@mopub.com", "type": "EmailAddress", "count": 2 }, \{ "id": "email\:firebase-database-client\@google.com", "name": "firebase-database-client\@google.com", "type": "EmailAddress", "count": 5 }, \{ "id": "idn\:firebase.com", "name": "firebase.com", "type": "InternetDomainName", "count": 9 }, \{ "id": "idn\:mopub.com", "name": "mopub.com", "type": "InternetDomainName", "count": 1 }, \{ "id": "ip:23.2.3.3", "name": "23.2.3.3", "type": "IpAddress", "count": 27 }, \{ "id": "ip:123.1.1.1", "name": "123.1.1.1", "type": "IpAddress", "count": 2 }, \{ "id": "ip:123.4.5.6", "name": "123.4.5.6", "type": "IpAddress", "count": 1 } ] } } \`\`\`
:::

You can form expressions to suit your requirement using the supported JSONpath syntax and filters.

| Expression                                      | Result                                    |
| ----------------------------------------------- | ----------------------------------------- |
| $                                               | Entire object                             |
| $.json\_response                                | Entire json\_response object              |
| $.json\_response.entities\[0]                   | First entity                              |
| $.\['json\_response']\['entities']\[0]          | First entity                              |
| $.json\_response.entities\[0,2]                 | First and third entity                    |
| $.json\_response.entities\[:2]                  | First two entities                        |
| $.json\_response.entities\[-2:]                 | Last two entities                         |
| $.json\_response.entities\[\*].name             | The name of all the entities              |
| $..id                                           | All the ids                               |
| $.json\_response.entities\[?(@.count > 6)]      | All entities with count greater than 6    |
| $..entities\[?(@.type == "InternetDomainName")] | All entities with type InternetDomainName |

