o
    $iF"                     @  sD  d dl mZ d dlmZmZmZ d dlmZ d dlZddl	m
Z
 ddlmZmZmZmZmZmZmZ ddlmZ dd	lmZ dd
lmZmZ ddlmZmZ ddlmZmZ ddl m!Z!m"Z" ddl#m$Z$ ddl%m&Z& ddl'm(Z( ddgZ)G dd deZ*G dd deZ+G dd dZ,G dd dZ-G dd dZ.G dd dZ/dS )    )annotations)AnyListcast)LiteralN   )_legacy_response)BodyOmitQueryHeadersNotGivenomit	not_given)maybe_transform)cached_property)SyncAPIResourceAsyncAPIResource)to_streamed_response_wrapper"async_to_streamed_response_wrapper)SyncCursorPageAsyncCursorPage)AsyncPaginatormake_request_options)input_item_list_params)ResponseItem)ResponseIncludable
InputItemsAsyncInputItemsc                	   @  F   e Zd ZedddZed ddZeeeeddded	d!ddZdS )"r   returnInputItemsWithRawResponsec                 C     t | S a  
        This property can be used as a prefix for any HTTP method call to return
        the raw response object instead of the parsed content.

        For more information, see https://www.github.com/openai/openai-python#accessing-raw-response-data-eg-headers
        )r!   self r&   f/var/www/html/flask_server/venv/lib/python3.10/site-packages/openai/resources/responses/input_items.pywith_raw_response      zInputItems.with_raw_responseInputItemsWithStreamingResponsec                 C  r"   z
        An alternative to `.with_raw_response` that doesn't eagerly read the response body.

        For more information, see https://www.github.com/openai/openai-python#with_streaming_response
        )r*   r$   r&   r&   r'   with_streaming_response$      z"InputItems.with_streaming_responseNafterincludelimitorderextra_headersextra_query
extra_bodytimeoutresponse_idstrr/   
str | Omitr0   List[ResponseIncludable] | Omitr1   
int | Omitr2   Literal['asc', 'desc'] | Omitr3   Headers | Noner4   Query | Noner5   Body | Noner6   'float | httpx.Timeout | None | NotGivenSyncCursorPage[ResponseItem]c          
      C  V   |s	t d|| jd| dtt t||||	t||||dtjdtt	tdS a  
        Returns a list of input items for a given response.

        Args:
          after: An item ID to list items after, used in pagination.

          include: Additional fields to include in the response. See the `include` parameter for
              Response creation above for more information.

          limit: A limit on the number of objects to be returned. Limit can range between 1 and
              100, and the default is 20.

          order: The order to return the input items in. Default is `desc`.

              - `asc`: Return the input items in ascending order.
              - `desc`: Return the input items in descending order.

          extra_headers: Send extra headers

          extra_query: Add additional query parameters to the request

          extra_body: Add additional JSON properties to the request

          timeout: Override the client-level default timeout for this request, in seconds
        z:Expected a non-empty value for `response_id` but received z/responses/z/input_items)r/   r0   r1   r2   )r3   r4   r5   r6   query)pageoptionsmodel)

ValueError_get_api_listr   r   r   r   r   InputItemListParamsr   r   
r%   r7   r/   r0   r1   r2   r3   r4   r5   r6   r&   r&   r'   list-   *   (
zInputItems.list)r    r!   )r    r*   )r7   r8   r/   r9   r0   r:   r1   r;   r2   r<   r3   r=   r4   r>   r5   r?   r6   r@   r    rA   	__name__
__module____qualname__r   r(   r,   r   r   rL   r&   r&   r&   r'   r          	c                	   @  r   )"r   r    AsyncInputItemsWithRawResponsec                 C  r"   r#   )rS   r$   r&   r&   r'   r(   n   r)   z!AsyncInputItems.with_raw_response$AsyncInputItemsWithStreamingResponsec                 C  r"   r+   )rT   r$   r&   r&   r'   r,   x   r-   z'AsyncInputItems.with_streaming_responseNr.   r7   r8   r/   r9   r0   r:   r1   r;   r2   r<   r3   r=   r4   r>   r5   r?   r6   r@   ;AsyncPaginator[ResponseItem, AsyncCursorPage[ResponseItem]]c          
      C  rB   rC   )
rH   rI   r   r   r   r   r   rJ   r   r   rK   r&   r&   r'   rL      rM   zAsyncInputItems.list)r    rS   )r    rT   )r7   r8   r/   r9   r0   r:   r1   r;   r2   r<   r3   r=   r4   r>   r5   r?   r6   r@   r    rU   rN   r&   r&   r&   r'   r   m   rR   c                   @     e Zd ZdddZdS )	r!   input_itemsr   r    Nonec                 C     || _ t|j| _d S N)_input_itemsr   to_raw_response_wrapperrL   r%   rW   r&   r&   r'   __init__      
z"InputItemsWithRawResponse.__init__NrW   r   r    rX   rO   rP   rQ   r^   r&   r&   r&   r'   r!          r!   c                   @  rV   )	rS   rW   r   r    rX   c                 C  rY   rZ   )r[   r   async_to_raw_response_wrapperrL   r]   r&   r&   r'   r^      r_   z'AsyncInputItemsWithRawResponse.__init__NrW   r   r    rX   ra   r&   r&   r&   r'   rS      rb   rS   c                   @  rV   )	r*   rW   r   r    rX   c                 C     || _ t|j| _d S rZ   )r[   r   rL   r]   r&   r&   r'   r^         
z(InputItemsWithStreamingResponse.__init__Nr`   ra   r&   r&   r&   r'   r*      rb   r*   c                   @  rV   )	rT   rW   r   r    rX   c                 C  re   rZ   )r[   r   rL   r]   r&   r&   r'   r^      rf   z-AsyncInputItemsWithStreamingResponse.__init__Nrd   ra   r&   r&   r&   r'   rT      rb   rT   )0
__future__r   typingr   r   r   typing_extensionsr   httpx r   _typesr	   r
   r   r   r   r   r   _utilsr   _compatr   	_resourcer   r   	_responser   r   
paginationr   r   _base_clientr   r   types.responsesr   types.responses.response_itemr   #types.responses.response_includabler   __all__r   r   r!   rS   r*   rT   r&   r&   r&   r'   <module>   s,   $TT			