OpenAI User Message Parameter TypedDict (chat/chat_completion_user_message_param.py)

openai-python · src/openai/types/chat/chat_completion_user_message_param.py · python · Apache-2.0
ai, dev-tools, chat, lang:python

Defines a typed dictionary for user-authored messages sent to the OpenAI chat completion API. Reuse when building integrations for OpenAI's chat models.

# Source: https://github.com/openai/openai-python | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works
# Provided via justclaw.it.com; keep this notice with the code.
# File generated from our OpenAPI spec by Castiron. See CONTRIBUTING.md for details.

from __future__ import annotations

from typing import Union, Iterable
from typing_extensions import Literal, Required, TypedDict

from .chat_completion_content_part_param import ChatCompletionContentPartParam

__all__ = ["ChatCompletionUserMessageParam"]


class ChatCompletionUserMessageParam(TypedDict, total=False):
    """
    Messages sent by an end user, containing prompts or additional context
    information.
    """

    content: Required[Union[str, Iterable[ChatCompletionContentPartParam]]]
 

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key