- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
06-29-2022 06:25 AM
Hello team,
I'm trying to use the extended context feature to keep only the data I'm interrested in and put them where I need them to be.
The automation I'm using is infoblox-get-ip from Infoblox integration.
Here is the output of the automation:
I'm setting the following string in the Extended Context field (splitted on multiple lines for better visibility):
IpInformation.status=result.status::
IpInformation.network=result.network::
IpInformation.names=result.names::
IpInformation.site=result.extattrs.site.value::
IpInformation.macaddress=result.macaddress
I'm getting the following result (information is censored, InRange and Pivate come from another integration):
As you can see only some of the fields are present in the output.
The following fields are missing : macaddress and extattrs.site.value.
Moreover all fields comming from the extended context functionnality are arrays (insteal of single value as the real output, except for names).
Here are the full context printed:
{ "IpInformation": { "status": [ "value" ], "InRange": "value", "names": [ "value", "value", "value" ], "Private": "value", "network": [ "value" ] }, "Infoblox": { "IP": { "Status": "value", "MacAddress": "value", "ReferenceID": "value", "Network": "value", "LeaseState": "value", "Objects": [ "value", "value", "value", "value" ], "IsConflict": false, "Names": [ "value", "value", "value" ], "NetworkView": "value", "Extattrs": { "Organization": { "value": "value", "inheritance_source": { "_ref": "value" } }, "Site": { "value": "value", "inheritance_source": { "_ref": "value" } } }, "Usage": [ "value", "DHCP" ], "IpAddress": "value", "DhcpClientIdentifier": "value", "Types": [ "value", "value", "value", "value" ] } } } |
My questions are :
Thank you for reading and your help on this topic.
06-29-2022 08:15 PM
Hi @AlexandreBorgo, You cannot select the array items inside extended context. Just dump all the data to context and then use what you need. Use the command like below.
!infoblox-get-ip extend-context=data=
06-29-2022 08:15 PM
Hi @AlexandreBorgo, You cannot select the array items inside extended context. Just dump all the data to context and then use what you need. Use the command like below.
!infoblox-get-ip extend-context=data=
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!