Skip to content
Advertisement

How to check the ssm connection status of all the servers with a specific tag value using python boto3

I wanted to check the ssm connection status of all the servers with a specific tag. I am making use of the boto3 module get_connection_status as follows.

JavaScript

However get_connection_status functions accepts only strings and not list. Hence I am getting the below error. How can I get rid of this?

{“ExecutionLog”:”Parameter validation failed: Invalid type for parameter Target, value: [‘i-123xxxxxxxxx’], type: <class ‘list’>, valid types: <class ‘str’> “}

Advertisement

Answer

You are using a list, not a string. It should be:

JavaScript
User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement