**Description**

I have noticed that the stable REST API doesn't have the ability to run a task (which is possible from the airflow web interface.
I think it would be nice to have either:
- Run task 
- Run all failing tasks (rerun from point of failure)
this ability for integrations.

**Use case / motivation**

I would like the ability to identify the failing tasks on a specific DAG Run and rerun only them.
I would like to do it remotely (non-interactive) using the REST API.
I could write a script that run only the failing tasks, but I couldn't find a way to "Run" a task, when I have the task instance ID.

**Are you willing to submit a PR?**

Not at this stage

**Related Issues**



airflow/models/dag.py
from airflow.models.baseoperator import BaseOperator
from airflow.models.dagbag import DagBag
from airflow.models.dagcode import DagCode
from airflow.models.dagparam import DagParam
from airflow.models.dagpickle import DagPickle
from airflow.models.dagrun import DagRun
from airflow.models.taskinstance import Context, TaskInstance, clear_task_instances
from airflow.security import permissions
from airflow.stats import Stats
from airflow.utils import timezone
from airflow.utils.dates import cron_presets, date_range as utils_date_range
from airflow.utils.file import correct_maybe_zipped
from airflow.utils.helpers import validate_key
from airflow.utils.log.logging_mixin import LoggingMixin
from airflow.utils.session import provide_session
from airflow.utils.sqlalchemy import Interval, UtcDateTime, skip_locked, with_row_locks
from airflow.utils.state import State
from airflow.utils.types import DagRunType
if TYPE_CHECKING:
    from airflow.utils.task_group import TaskGroup
try:
    from re import Pattern as PatternType  
except ImportError:
    PatternType = type(re.compile('', 0))
log = logging.getLogger(__name__)
ScheduleInterval = Union[str, timedelta, relativedelta]
DEFAULT_VIEW_PRESETS = ['tree', 'graph', 'duration', 'gantt', 'landing_times']
ORIENTATION_PRESETS = ['LR', 'TB', 'RL', 'BT']
DagStateChangeCallback = Callable[[Context], None]
def get_last_dagrun(dag_id, session, include_externally_triggered=False):