# This file was auto generated by Styx.
# Do not edit this file directly.

import typing
import pathlib
from styxdefs import *
import dataclasses

MRIS_SPHERE_METADATA = Metadata(
    id="ff70a8889110348344f49593918baf25bab92371.boutiques",
    name="mris_sphere",
    package="freesurfer",
    container_image_tag="freesurfer/freesurfer:7.4.1",
)


class MrisSphereOutputs(typing.NamedTuple):
    """
    Output object returned when calling `mris_sphere(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    output_patch_file: OutputPathType
    """Output patch file."""


def mris_sphere(
    surface_file: InputPathType,
    patch_file: InputPathType,
    output_patch: str,
    runner: Runner | None = None,
) -> MrisSphereOutputs:
    """
    This program will add a template into an average surface.
    
    Author: FreeSurfer Developers
    
    URL: https://github.com/freesurfer/freesurfer
    
    Args:
        surface_file: Input surface file.
        patch_file: Input patch file name.
        output_patch: Output patch file name.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `MrisSphereOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(MRIS_SPHERE_METADATA)
    cargs = []
    cargs.append("mris_sphere")
    cargs.append(execution.input_file(surface_file))
    cargs.append(execution.input_file(patch_file))
    cargs.append(output_patch)
    ret = MrisSphereOutputs(
        root=execution.output_file("."),
        output_patch_file=execution.output_file(output_patch),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "MRIS_SPHERE_METADATA",
    "MrisSphereOutputs",
    "mris_sphere",
]
