- Products
- Learn
- Local User Groups
- Partners
- More
What’s New in Device Diagnostics?
Dec 2nd @ 5pm CET / 11am EST
AI Security Masters
Security in the Pace of AI:
From Threat to Force Multiplier
CPX is Back!
Join us in Las Vegas, Vienna, and/or Bangkok!
Check Point Named a Leader
The Forrester Wave:
Enterprise Firewall Solutions, Q4 2026
What’s New in Agentic Network Orchestration
CheckMates Go:
Fun Ding
Hello,
How can I get a specific value returned only using API commands in a bash script ?
E.g. I need a rule name and the rule type reurned only.
Assuming the API was developped using object oriented programming, it should be possible to get a specific value returned only instead all the information related to the rule like listed below.
like
access-rule.name
or
access-rule.type
From the API command listed below I'd like to see following only:
access-rule.name = "Stealth Rule"
or
rulebase.type = "access-rule"
or
access-rule.comments = "MY COMMENT"
=========================================================================================
[[email protected]:0]# mgmt_cli show access-rule --domain 'Domain1' layer 'Policy1 Network' uid '1ba15eb2-9fef-4042-9a6e-3842b8a9a231'
Username: script
Password:
uid: "1ba15eb2-9fef-4042-9a6e-3842b8a9a231"
name: "Stealth Rule"
type: "access-rule"
domain:
uid: "ad3744cb-55c1-4467-8119-1359dd7ca5f4"
name: "Domain1"
domain-type: "domain"
track:
type:
uid: "598ead32-aa42-4615-90ed-f51a5928d41d"
name: "Log"
type: "Track"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
per-session: false
per-connection: true
accounting: false
alert: "none"
layer: "e1c4e6af-1788-4f05-a598-6a995b841948"
source:
- uid: "97aeb369-9aea-11d5-bd16-0090272ccb30"
name: "Any"
type: "CpmiAnyObject"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
source-negate: false
destination:
- uid: "97aeb369-9aea-11d5-bd16-0090272ccb30"
name: "Any"
type: "CpmiAnyObject"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
destination-negate: false
service:
- uid: "97aeb369-9aea-11d5-bd16-0090272ccb30"
name: "Any"
type: "CpmiAnyObject"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
service-negate: false
vpn:
- uid: "97aeb369-9aea-11d5-bd16-0090272ccb30"
name: "Any"
type: "CpmiAnyObject"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
action:
uid: "6c488338-8eec-4103-ad21-cd461ac2c473"
name: "Drop"
type: "RulebaseAction"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
action-settings: {}
content:
- uid: "97aeb369-9aea-11d5-bd16-0090272ccb30"
name: "Any"
type: "CpmiAnyObject"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
content-negate: false
content-direction: "any"
time:
- uid: "97aeb369-9aea-11d5-bd16-0090272ccb30"
name: "Any"
type: "CpmiAnyObject"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
custom-fields:
field-1: ""
field-2: ""
field-3: ""
meta-info:
lock: "unlocked"
validation-state: "ok"
last-modify-time:
posix: 1542012857319
iso-8601: "2018-11-12T09:54+0100"
last-modifier: "script"
creation-time:
posix: 1542012857319
iso-8601: "2018-11-12T09:54+0100"
creator: "script"
comments: "MY COMMENT"
enabled: false
install-on:
- uid: "6c488338-8eec-4103-ad21-cd461ac2c476"
name: "Policy Targets"
type: "Global"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
...
.....
Thank you for the help .
This is more of a RFE ![]()
Hello Günther,
so you are saying this is not object oriented programmed ?
The language the API is programmed in is irrelevant. What he is saying is, it's not feature we currently provide, therefor a request for enhancement would need to be submitted.
Bash is not object oriented so can't. You can use usual bash tools like grep, sed, awk to process API output, but your variables won't be object oriented type of course.
You can call for json format and use JQ to parse the returned data.

Hi,
have a look at the SDK GitHub - CheckPointSW/cp_mgmt_api_python_sdk: Check Point API Python Development Kit and the examples included. with parsing the output as "data", you can just say "give me the value of "rulename""
i.e.(what i did)
| if monitor_ips_version.success: |
| ips_info=monitor_ips_version.data |
| ips_current_ver_info=ips_info["installed-version"] |
ips_update_ver_info=ips_info["latest-version"]
i am aware, you asked for bash and i answered with python, but maybe it helps
Hello David.
yes, it is.
Than you
Leaderboard
Epsum factorial non deposit quid pro quo hic escorol.
| User | Count |
|---|---|
| 1 | |
| 1 |
Wed 02 Dec 2026 @ 02:00 PM (CET)
E-Mail-Agent-Hijacking: E-Mail-Sicherheit im Zeitalter der KI neu überdenkenWed 02 Dec 2026 @ 02:00 PM (GMT)
Why Email Agent Hijacking Marks the End of Post-Delivery Email SecurityWed 02 Dec 2026 @ 03:30 PM (GMT)
The New DDoS Reality: Autonomy, Scale, and the Future of DefenseWed 02 Dec 2026 @ 11:00 AM (PST)
Why Email Agent Hijacking Marks the End of Post-Delivery Email SecurityWed 02 Dec 2026 @ 02:00 PM (EST)
Why Email Agent Hijacking Marks the End of Post-Delivery Email SecurityWed 02 Dec 2026 @ 02:00 PM (CET)
E-Mail-Agent-Hijacking: E-Mail-Sicherheit im Zeitalter der KI neu überdenkenWed 02 Dec 2026 @ 02:00 PM (GMT)
Why Email Agent Hijacking Marks the End of Post-Delivery Email SecurityWed 02 Dec 2026 @ 03:30 PM (GMT)
The New DDoS Reality: Autonomy, Scale, and the Future of DefenseWed 02 Dec 2026 @ 11:00 AM (PST)
Why Email Agent Hijacking Marks the End of Post-Delivery Email SecurityWed 02 Dec 2026 @ 02:00 PM (EST)
Why Email Agent Hijacking Marks the End of Post-Delivery Email SecurityAbout CheckMates
Learn Check Point
Advanced Learning
WE SECURE YOUR AI TRANSFORMATION