{"id":22015273,"url":"https://github.com/oguzhan-yilmaz/aws-jmespath-utils","last_synced_at":"2026-02-06T02:01:30.873Z","repository":{"id":245615796,"uuid":"816341784","full_name":"oguzhan-yilmaz/aws-jmespath-utils","owner":"oguzhan-yilmaz","description":"jmespath custom functions to filter and exclude AWS resources by tags","archived":false,"fork":false,"pushed_at":"2024-07-24T17:44:00.000Z","size":32,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-07-24T20:28:38.752Z","etag":null,"topics":["aws","aws-cli","jmespath","jq","tagging","tags"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/aws-jmespath-utils/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/oguzhan-yilmaz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-17T14:45:26.000Z","updated_at":"2024-07-24T17:51:36.000Z","dependencies_parsed_at":"2024-06-23T02:42:20.255Z","dependency_job_id":"76e85835-748e-4d3c-8772-4af9c5f92a48","html_url":"https://github.com/oguzhan-yilmaz/aws-jmespath-utils","commit_stats":null,"previous_names":["oguzhan-yilmaz/aws-jmespath-utils"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan-yilmaz%2Faws-jmespath-utils","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan-yilmaz%2Faws-jmespath-utils/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan-yilmaz%2Faws-jmespath-utils/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/oguzhan-yilmaz%2Faws-jmespath-utils/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/oguzhan-yilmaz","download_url":"https://codeload.github.com/oguzhan-yilmaz/aws-jmespath-utils/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227270324,"owners_count":17756298,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aws","aws-cli","jmespath","jq","tagging","tags"],"created_at":"2024-11-30T04:20:27.325Z","updated_at":"2026-02-06T02:01:25.818Z","avatar_url":"https://github.com/oguzhan-yilmaz.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# aws-jmespath-utils\n\n## Installation\n\n```bash\npip3 install aws_jmespath_utils\n```\n\n## Examples\n\nCheck out the example code:\n\n- [examples/01_filter_tags_basic.py](./examples/01_filter_tags_basic.py)\n- [examples/02_filter_tags_exclude.py](./examples/02_filter_tags_exclude.py)\n\n## Usage\n\n**Find resources with 'Name' tag set**\n\n```python\njmespath.search(  # it's important that your expression array must be inside `` backticks\n    '[] | filter_tags(`[\"Name=*\"]`, @)', data_list, options=jmespath_options\n)\n```\n\n**Find tag values starting with 123**\n\n```python\njmespath.search(  # it's important that your expression array must be inside `` backticks\n    '[].filter_tags(`[\"=123*\"]`, @)', data_list, options=jmespath_options\n)\n```\n\n**Find Many tag values**\n\n```python\njmespath.search(  # it's important that your expression array must be inside `` backticks\n    '[].filter_tags(`[\"=123*\", \"=jmespath*\"]`, @)', data_list, options=jmespath_options\n)\n```\n\n**Exclude Tags**\n\n```python\njmespath.search(  # it's important that your expression array must be inside `` backticks\n    '[].exclude_tags(`[\"map-migrated=*\"]`, @)', data_list, options=jmespath_options\n)\n```\n\n**Setting log levels**\n\n```bash\n# set log level as you wish\nexport AWS_JMESPATH_UTILS_LOG_LEVEL=\"DEBUG\"   \nexport AWS_JMESPATH_UTILS_LOG_LEVEL=\"INFO\"  # default   \n```\n\n\n\n## Complete Usage Example\n\n```python\nimport jmespath\nfrom aws_jmespath_utils import jmespath_options\nimport json\ndata_list = [    \n    {\"a\": \"a\", \"Tags\": [{\"Key\": \"Name\", \"Value\": \"jmespath-utils\"}, ]},\n    {\"b\": \"b\", \"Tags\": [{\"Key\": \"Nam\", \"Value\": \"jmespath-utils-nam\"}]},\n    {\"c\": \"c\", \"Tags\": [{\"Key\": \"map-migrated\", \"Value\": \"234\"}]}\n]\n\nprint(\n    json.dumps(\n        jmespath.search('[] | filter_tags(`[\"Name=*\"]`, @)', data_list, options=jmespath_options),\n        indent=2\n    )\n)\n\nprint(\n    json.dumps(\n        jmespath.search('[] | exclude_tags(`[\"Nam*=\"]`, @)', data_list, options=jmespath_options),\n        indent=2\n    )\n)\n\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foguzhan-yilmaz%2Faws-jmespath-utils","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foguzhan-yilmaz%2Faws-jmespath-utils","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foguzhan-yilmaz%2Faws-jmespath-utils/lists"}