def list_instances(ClusterId=None, InstanceGroupId=None, InstanceGroupTypes
    =None, InstanceFleetId=None, InstanceFleetType=None, InstanceStates=
    None, Marker=None):
    """
    Provides information about the cluster instances that Amazon EMR provisions on behalf of a user when it creates the cluster. For example, this operation indicates when the EC2 instances reach the Ready state, when instances become available to Amazon EMR to use for jobs, and the IP addresses for cluster instances, etc.
    See also: AWS API Documentation
    
    
    :example: response = client.list_instances(
        ClusterId='string',
        InstanceGroupId='string',
        InstanceGroupTypes=[
            'MASTER'|'CORE'|'TASK',
        ],
        InstanceFleetId='string',
        InstanceFleetType='MASTER'|'CORE'|'TASK',
        InstanceStates=[
            'AWAITING_FULFILLMENT'|'PROVISIONING'|'BOOTSTRAPPING'|'RUNNING'|'TERMINATED',
        ],
        Marker='string'
    )
    
    
    :type ClusterId: string
    :param ClusterId: [REQUIRED]
            The identifier of the cluster for which to list the instances.
            

    :type InstanceGroupId: string
    :param InstanceGroupId: The identifier of the instance group for which to list the instances.

    :type InstanceGroupTypes: list
    :param InstanceGroupTypes: The type of instance group for which to list the instances.
            (string) --
            

    :type InstanceFleetId: string
    :param InstanceFleetId: The unique identifier of the instance fleet.

    :type InstanceFleetType: string
    :param InstanceFleetType: The node type of the instance fleet. For example MASTER, CORE, or TASK.

    :type InstanceStates: list
    :param InstanceStates: A list of instance states that will filter the instances returned with this request.
            (string) --
            

    :type Marker: string
    :param Marker: The pagination token that indicates the next set of results to retrieve.

    :rtype: dict
    :return: {
        'Instances': [
            {
                'Id': 'string',
                'Ec2InstanceId': 'string',
                'PublicDnsName': 'string',
                'PublicIpAddress': 'string',
                'PrivateDnsName': 'string',
                'PrivateIpAddress': 'string',
                'Status': {
                    'State': 'AWAITING_FULFILLMENT'|'PROVISIONING'|'BOOTSTRAPPING'|'RUNNING'|'TERMINATED',
                    'StateChangeReason': {
                        'Code': 'INTERNAL_ERROR'|'VALIDATION_ERROR'|'INSTANCE_FAILURE'|'BOOTSTRAP_FAILURE'|'CLUSTER_TERMINATED',
                        'Message': 'string'
                    },
                    'Timeline': {
                        'CreationDateTime': datetime(2015, 1, 1),
                        'ReadyDateTime': datetime(2015, 1, 1),
                        'EndDateTime': datetime(2015, 1, 1)
                    }
                },
                'InstanceGroupId': 'string',
                'InstanceFleetId': 'string',
                'Market': 'ON_DEMAND'|'SPOT',
                'InstanceType': 'string',
                'EbsVolumes': [
                    {
                        'Device': 'string',
                        'VolumeId': 'string'
                    },
                ]
            },
        ],
        'Marker': 'string'
    }
    
    
    """
    pass
