Neville,
In the manageable endpoint, you can find the SNMP Profile as SNMPProfileID and that corresponds to the profiles endpoint. The alternate name is also contained within the manageable endpoint. Here is a pair of examples utilizing a filter to list all devices that have the SNMP Profile ID of 4943:
CLI Curl:
curl --header "Content-Type: application/xml" --request POST --data '<FilterSelect xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="filter.xsd"><Filter><ManageableDevice.SNMPProfileID type="EQUAL">4943</ManageableDevice.SNMPProfileID></Filter><Select use="exclude" isa="exclude"><Item><AlternateName use="include"/></Item></Select></FilterSelect>' --url http://$DAhostname:8581/rest/devices/manageable/filtered
Via a REST client:
Method: POST
Type: application/xml
URL: http://$DAhostname:8581/rest/devices/manageable/filtered
Body:
<FilterSelect xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="filter.xsd">
<Filter>
<ManageableDevice.SNMPProfileID type="EQUAL">4943</ManageableDevice.SNMPProfileID>
</Filter>
<Select use="exclude" isa="exclude">
<Item>
<AlternateName use="include"/>
</Item>
</Select>
</FilterSelect>
The body of this specifies to MATCH a SNMPProfileID EQUAL to 4943 then EXCLUDE all data (will always show at least the item id) then INCLUDE AlternateName.
The result will look something like:
<ManageableDeviceList>
<ManageableDevice version="1.0.0">
<ID>5858</ID>
<Item version="1.0.0">
<AlternateName>MyNameIs-ALTERNATE</AlternateName>
</Item>
</ManageableDevice>
</ManageableDeviceList>
You will need to run through as many iterations of this as you have SNMP Profile ID's. I will leave the parsing of the data up to you but in my experiences, I have utilized the CURL version above and use xml_grep to parse IDs out of a returned query to get them in a numerical list with no extra characters.
Regards,
Troy