def METHOD_NAME(end_time: Optional[str] = None,
                      machine_group_name: Optional[str] = None,
                      resource_group_name: Optional[str] = None,
                      start_time: Optional[str] = None,
                      workspace_name: Optional[str] = None,
                      opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetMachineGroupResult:
    """
    Returns the specified machine group as it existed during the specified time interval.
    Azure REST API version: 2015-11-01-preview.
    :param str end_time: UTC date and time specifying the end time of an interval. When not specified the service uses DateTime.UtcNow
    :param str machine_group_name: Machine Group resource name.
    :param str resource_group_name: Resource group name within the specified subscriptionId.
    :param str start_time: UTC date and time specifying the start time of an interval. When not specified the service uses DateTime.UtcNow - 10m
    :param str workspace_name: OMS workspace containing the resources of interest.
    """
    __args__ = dict()
    __args__['endTime'] = end_time
    __args__['machineGroupName'] = machine_group_name
    __args__['resourceGroupName'] = resource_group_name
    __args__['startTime'] = start_time
    __args__['workspaceName'] = workspace_name
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('azure-native:operationalinsights:getMachineGroup', __args__, opts=opts, typ=GetMachineGroupResult).value
    return AwaitableGetMachineGroupResult(
        count=pulumi.get(__ret__, 'count'),
        display_name=pulumi.get(__ret__, 'display_name'),
        etag=pulumi.get(__ret__, 'etag'),
        group_type=pulumi.get(__ret__, 'group_type'),
        id=pulumi.get(__ret__, 'id'),
        kind=pulumi.get(__ret__, 'kind'),
        machines=pulumi.get(__ret__, 'machines'),
        name=pulumi.get(__ret__, 'name'),
        type=pulumi.get(__ret__, 'type'))