The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

OpenAI::API::Response - base class for OpenAI API responses.

SYNOPSIS

This module should not be used directly. Instead, you should use a subclass for specific response types, such as OpenAI::API::Response::Chat.

    use OpenAI::API::Request::Chat;

    my $request  = OpenAI::API::Request::Chat->new(...);
    my $response = $request->send();

    # You should be using OpenAI::API::Response::Chat or other subclasses directly, not OpenAI::API::Response.

DESCRIPTION

The OpenAI::API::Response module provides a generic representation for responses received from the OpenAI API. This module should not be used directly. Instead, you should use subclasses for specific response types.