Search Results for

    Show / Hide Table of Contents

    Class HostedToolChoice

    Only for Responses API. Indicates that the model should use a built-in tool to generate a response.
    Learn more about built-in tools: https://platform.openai.com/docs/guides/tools

    Allowed types (2025-09-21):

    • file_search
    • web_search_preview
    • computer_use_preview
    • code_interpreter
    • image_generation
    Inheritance
    object
    ToolChoice
    HostedToolChoice
    Inherited Members
    ToolChoice.Type_AllowedTools
    ToolChoice.Type_Function
    ToolChoice.Type_Custom
    ToolChoice.Type_Mcp
    ToolChoice.Mode
    ToolChoice.None()
    ToolChoice.Auto()
    ToolChoice.Required()
    ToolChoice.AllowedTools(ToolChoiceMode, List<Tool>)
    ToolChoice.Function(string)
    ToolChoice.Custom(string)
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Glitch9.AIDevKit
    Assembly: Glitch9.AIDevKit.dll
    Syntax
    public class HostedToolChoice : ToolChoice

    Constructors

    | Edit this page View Source

    HostedToolChoice(string)

    Declaration
    public HostedToolChoice(string type)
    Parameters
    Type Name Description
    string type

    Properties

    | Edit this page View Source

    Type

    Declaration
    [JsonProperty("type")]
    public override string Type { get; }
    Property Value
    Type Description
    string
    Overrides
    ToolChoice.Type

    Methods

    | Edit this page View Source

    CodeInterpreter()

    Declaration
    public static HostedToolChoice CodeInterpreter()
    Returns
    Type Description
    HostedToolChoice
    | Edit this page View Source

    ComputerUse()

    Declaration
    public static HostedToolChoice ComputerUse()
    Returns
    Type Description
    HostedToolChoice
    | Edit this page View Source

    FileSearch()

    Declaration
    public static HostedToolChoice FileSearch()
    Returns
    Type Description
    HostedToolChoice
    | Edit this page View Source

    ImageGeneration()

    Declaration
    public static HostedToolChoice ImageGeneration()
    Returns
    Type Description
    HostedToolChoice
    | Edit this page View Source

    WebSearchPreview()

    Declaration
    public static HostedToolChoice WebSearchPreview()
    Returns
    Type Description
    HostedToolChoice

    Extension Methods

    ArrayExtensions.ToArrayOrEmpty<T>(T)
    ArrayExtensions.ToArrayOrNull<T>(T)
    EventExtensions.ToDelta<T>(T, string, int, string, bool)
    EventExtensions.ToDone<T>(T, string, int, string)
    EventExtensions.ToEvent<T>(T)
    EventExtensions.UpcastDelta<T1, T2>(T1, string, int, string, bool)
    FallbackExtensions.IsOr<TParent, TChild>(TParent, TChild)
    ResponseCastingExtensions.GetResult<T>(T)
    SystemExtensions.GetName(object)
    • Edit this page
    • View Source
    In this article
    Back to top AI DevKit Documentation