def reload_experiment(api, exp_id, duration=None, start_time=None):
    """Reload given experiment, duration and start_time can be adapted.

    :param api: API Rest api object
    :param exp_id: experiment id
    :param duration: experiment duration in minutes. None for same duration.
    :param start_time: experiment start time timestamp.
        None for as soon as possible
    """
    exp_json = {}
    if duration is not None:
        exp_json['duration'] = str(duration)
    if start_time is not None:
        exp_json['reservation'] = str(start_time)
    return api.reload_experiment(exp_id, exp_json)
