Technical Forum
Ask questions. Discover Answers.
cancel
Showing results for 
Search instead for 
Did you mean: 
Custom Alert Banner

API REST gtm filter parameter

Kar44
Nimbostratus
Nimbostratus

Hello all,

When I send this call to the GTM BIGIP ver=14.1.4.4

curl -sku "admin:password" "https://<IP or Hostname>/mgmt/tm/ltm/pool?$select=name"

The BIGIP reply with all json field not just the pool name. I would like to receive name only

1 REPLY 1

JRahm
Community Manager
Community Manager

HI @Kar44, the selection just cuts down on the number of fields within the item that are returned, but the response is still going to be valid json. That said, you can use jq to pull that out:

f5devcentral@jrahm-imac EQ Episode Audio % curl -sku "admin:admin" \ 'https://10.0.2.17/mgmt/tm/gtm/pool/a?$select=name' \
| jq '.items[].name'

Results in:
"gslbpool1"
"gslbpool2"