=encoding utf8

=head1 NAME

OpenAPI::Client::OpenAI::Path::assistants - Documentation for the /assistants path.

=head1 OPERATIONS

=head2 GET /assistants

=head3 listAssistants

  $client->list_assistants({
      body => { ... },
  });

Returns a list of assistants.

=head4 Path/query parameters

=over

=item * C<limit> (in query, optional, integer) - A limit on the number of objects to be returned. Limit can range between 1 and
100, and the default is 20.

Default: 20

=item * C<order> (in query, optional, string) - Sort order by the C<created_at> timestamp of the objects. C<asc> for ascending
order and C<desc> for descending order.

Allowed values: asc, desc

Default: desc

=item * C<after> (in query, optional, string) - A cursor for use in pagination. C<after> is an object ID that defines your
place in the list. For instance, if you make a list request and receive 100
objects, ending with obj_foo, your subsequent call can include after=obj_foo
in order to fetch the next page of the list.

=item * C<before> (in query, optional, string) - A cursor for use in pagination. C<before> is an object ID that defines your
place in the list. For instance, if you make a list request and receive 100
objects, starting with obj_foo, your subsequent call can include
before=obj_foo in order to fetch the previous page of the list.

=back

=head4 Responses

B<200 - OK>

Content-Type: application/json

Example:

    {
       "data" : [
          {
             "created_at" : 1698982736,
             "description" : null,
             "id" : "asst_abc123",
             "instructions" : "You are a helpful assistant designed to make me better at coding!",
             "metadata" : {},
             "model" : "gpt-4o",
             "name" : "Coding Tutor",
             "object" : "assistant",
             "response_format" : "auto",
             "temperature" : 1,
             "tool_resources" : {},
             "tools" : [],
             "top_p" : 1
          },
          {
             "created_at" : 1698982718,
             "description" : null,
             "id" : "asst_abc456",
             "instructions" : "You are a helpful assistant designed to make me better at coding!",
             "metadata" : {},
             "model" : "gpt-4o",
             "name" : "My Assistant",
             "object" : "assistant",
             "response_format" : "auto",
             "temperature" : 1,
             "tool_resources" : {},
             "tools" : [],
             "top_p" : 1
          },
          {
             "created_at" : 1698982643,
             "description" : null,
             "id" : "asst_abc789",
             "instructions" : null,
             "metadata" : {},
             "model" : "gpt-4o",
             "name" : null,
             "object" : "assistant",
             "response_format" : "auto",
             "temperature" : 1,
             "tool_resources" : {},
             "tools" : [],
             "top_p" : 1
          }
       ],
       "first_id" : "asst_abc123",
       "has_more" : false,
       "last_id" : "asst_abc789",
       "object" : "list"
    }

=head2 POST /assistants

=head3 createAssistant

  $client->create_assistant({
      body => { ... },
  });

Create an assistant with a model and instructions.

=head4 Request body

Content-Type: application/json

Example:

    {
       "created_at" : 1698984975,
       "description" : null,
       "id" : "asst_abc123",
       "instructions" : "You are a personal math tutor. When asked a question, write and run Python code to answer the question.",
       "metadata" : {},
       "model" : "gpt-4o",
       "name" : "Math Tutor",
       "object" : "assistant",
       "response_format" : "auto",
       "temperature" : 1,
       "tools" : [
          {
             "type" : "code_interpreter"
          }
       ],
       "top_p" : 1
    }

=head4 Responses

B<200 - OK>

Content-Type: application/json

Example:

    {
       "created_at" : 1698984975,
       "description" : null,
       "id" : "asst_abc123",
       "instructions" : "You are a personal math tutor. When asked a question, write and run Python code to answer the question.",
       "metadata" : {},
       "model" : "gpt-4o",
       "name" : "Math Tutor",
       "object" : "assistant",
       "response_format" : "auto",
       "temperature" : 1,
       "tools" : [
          {
             "type" : "code_interpreter"
          }
       ],
       "top_p" : 1
    }

=head1 SCHEMAS

=head2 AssistantObject

Properties:

=over

=item * C<created_at> (integer, required) - The Unix timestamp (in seconds) for when the assistant was created.

=item * C<description> (anyOf, required)

=item * C<id> (string, required) - The identifier, which can be referenced in API endpoints.

=item * C<instructions> (anyOf, required)

=item * C<metadata> (Metadata, required)

See L</Metadata> below for shape.

=item * C<model> (string, required) - ID of the model to use. You can use the
L<List models|https://platform.openai.com/docs/api-reference/models/list> API
to see all of your available models, or see our
L<Model overview|https://platform.openai.com/docs/models> for descriptions of
them.

=item * C<name> (anyOf, required)

=item * C<object> (string, required) - The object type, which is always C<assistant> .

Allowed values: assistant

=item * C<response_format> (anyOf)

=item * C<temperature> (anyOf)

=item * C<tool_resources> (anyOf)

=item * C<tools> (array of object, required) - A list of tool enabled on the assistant. There can be a maximum of 128 tools
per assistant. Tools can be of types C<code_interpreter> , C<file_search> , or
C<function> .

Default: []

=item * C<top_p> (anyOf)

=back

=head2 CreateAssistantRequest

Properties:

=over

=item * C<description> (anyOf)

=item * C<instructions> (anyOf)

=item * C<metadata> (Metadata)

See L</Metadata> below for shape.

=item * C<model> (anyOf, required) - ID of the model to use. You can use the
L<List models|https://platform.openai.com/docs/api-reference/models/list> API
to see all of your available models, or see our
L<Model overview|https://platform.openai.com/docs/models> for descriptions of
them.

=item * C<name> (anyOf)

=item * C<reasoning_effort> (ReasoningEffort)

See L</ReasoningEffort> below for shape.

=item * C<response_format> (anyOf)

=item * C<temperature> (anyOf)

=item * C<tool_resources> (anyOf)

=item * C<tools> (array of object) - A list of tool enabled on the assistant. There can be a maximum of 128 tools
per assistant. Tools can be of types C<code_interpreter> , C<file_search> , or
C<function> .

Default: []

=item * C<top_p> (anyOf)

=back

=head2 ListAssistantsResponse

Properties:

=over

=item * C<data> (array of AssistantObject, required)

=item * C<first_id> (string, required)

=item * C<has_more> (boolean, required)

=item * C<last_id> (string, required)

=item * C<object> (string, required)

=back

=head2 Metadata

Set of 16 key-value pairs that can be attached to an object. This can be
useful for storing additional information about the object in a structured
format, and querying for objects via API or the dashboard.

Keys are strings with a maximum length of 64 characters. Values are strings
with a maximum length of 512 characters.

=head2 ReasoningEffort

Constrains effort on reasoning for
L<reasoning models|https://platform.openai.com/docs/guides/reasoning> .
Currently supported values are C<none> , C<minimal> , C<low> , C<medium> ,
C<high> , and C<xhigh> . Reducing reasoning effort can result in faster
responses and fewer tokens used on reasoning in a response.

- C<gpt-5.1> defaults to C<none> , which does not perform reasoning. The
supported reasoning values for C<gpt-5.1> are C<none> , C<low> , C<medium> ,
and C<high> . Tool calls are supported for all reasoning values in gpt-5.1. -
All models before C<gpt-5.1> default to C<medium> reasoning effort, and do not
support C<none> . - The C<gpt-5-pro> model defaults to (and only supports)
C<high> reasoning effort. - C<xhigh> is supported for all models after
C<gpt-5.1-codex-max> .

=head1 SEE ALSO

L<OpenAPI::Client::OpenAI::Path>

=head1 COPYRIGHT AND LICENSE

Copyright (C) 2023-2026 by Nelson Ferraz

This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself, either Perl version 5.14.0 or,
at your option, any later version of Perl 5 you may have available.

=cut
