Assuming its the same fields you want every time, here's a simple way to do it: response = dashboard.switch.getDeviceSwitchPort('####-####-####',1) attribs = ['portId','name','tags','enabled','poeEnabled','type','vlan'] for _key, _value in response.items(): if _key in attribs: print('{}: {}'.format(_key,_value)) would give you this portId: 1 name: None tags: [] enabled: True poeEnabled: True type: trunk vlan: 1
... View more