Skip to main content
Glama

ClickUp Operator

by noah-vh
schemas.cpython-312.pyc7.05 kB
� �MMg=�� �ddlmZddlZddlZddlZddlmZddlmZddl m Z m Z m Z m Z  ddlZGd�de�ZGd�d ej"�Zej&d �ZGd �d �ZGd �de�Zy#e$rdZY�QwxYw)�)� annotationsN)�Request)�Response)� BaseRoute�Host�Mount�Routec��eZdZdZdd�Zy)�OpenAPIResponsezapplication/vnd.oai.openapic��t�Jd��t|t�sJd��tj|d��j d�S)Nz2`pyyaml` must be installed to use OpenAPIResponse.z<The schema passed to OpenAPIResponse should be a dictionary.F)�default_flow_stylezutf-8)�yaml� isinstance�dict�dump�encode)�self�contents �]C:\Users\noahv\Documents\GitHub\clickup-operator\.venv\Lib\site-packages\starlette/schemas.py�renderzOpenAPIResponse.rendersF����U�!U�U���'�4�(�h�*h�h�(��y�y��U�;�B�B�7�K�K�N)rz typing.Any�return�bytes)�__name__� __module__� __qualname__� media_typer�rrr r s ��.�J�Lrr c�,�eZdZUded<ded<ded<y)� EndpointInfo�str�path� http_method� typing.Callable[..., typing.Any]�funcN)rrr�__annotations__rrrr r s�� �I��� *�*rr z:\w+}c�4�eZdZdd�Zdd�Zd d�Zd d�Zd d�Zy) �BaseSchemaGeneratorc��t���N)�NotImplementedError)r�routess r� get_schemazBaseSchemaGenerator.get_schema$s ��!�#�#rc �&�g}|D�]}t|ttf�r�|jxsg}t|t�r|j |j �}nd}|j |�D�cgc]?}tdj||j f�|j|j����A}}|j|���t|t�r |js��tj|j �stj"|j �rm|j |j �}|j$xsdgD]<}|dk(r� |j't||j)�|j ���>���|j |j �}dD]Y}t+|j |�s�t-|j |�}|j't||j)�|���[��|Scc}w)a  Given the routes, yields the following information: - path eg: /users/ - http_method one of 'get', 'post', 'put', 'patch', 'delete', 'options' - func method ready to extract the docstring �)r"r#r%�GET�HEAD)�get�post�put�patch�delete�options)rrrr,�_remove_converterr"� get_endpointsr �joinr#r%�extendr �include_in_schema�inspect� isfunction�endpoint�ismethod�methods�append�lower�hasattr�getattr) rr,�endpoints_info�router"� sub_endpoint� sub_endpoints�methodr%s rr9z!BaseSchemaGenerator.get_endpoints's���.0���E��%�%���/����+����e�U�+��1�1�%�*�*�=�D��D�)-�(:�(:�6�(B� !� )C� � !��W�W�d�L�,=�,=�%>�?�$0�$<�$<�)�.�.�� )C� �!��%�%�m�4���u�-�U�5L�5L���#�#�E�N�N�3�w�7G�7G����7W��-�-�e�j�j�9��#�m�m�6��w�6�F���'� �"�)�)�,�t�V�\�\�^�U�^�^�*\�]�7� �-�-�e�j�j�9��R�F�"�5�>�>�6�:� �"�5�>�>�6�:�D�"�)�)�,�t�V�\�\�^�T�*R�S� S�9�D���7!s�0AHc�.�tjd|�S)z� Remove the converter from the path. For example, a route like this: Route("/users/{id:int}", endpoint=get_user, methods=["GET"]) Should be represented as `/users/{id}` in the OpenAPI schema. �})�_remove_converter_pattern�sub)rr"s rr8z%BaseSchemaGenerator._remove_converterXs��)�,�,�S�$�7�7rc��|j}|siSt�Jd��|jd�d}tj|�}t |t �siS|S)z` Given a function, parse the docstring as YAML and return a dictionary of info. z2`pyyaml` must be installed to use parse_docstring.z---�����)�__doc__r�split� safe_loadrr)r�func_or_method� docstring�parseds r�parse_docstringz#BaseSchemaGenerator.parse_docstringasb��#�*�*� ���I���U�!U�U�� �O�O�E�*�2�.� ���� �*���&�$�'��I�� rc�h�|jj}|j|��}t|�S)N)r,)�appr,r-r )r�requestr,�schemas rr z#BaseSchemaGenerator.OpenAPIResponseys,�����#�#�������/���v�&�&rN�r,�list[BaseRoute]r�dict[str, typing.Any])r,r]rzlist[EndpointInfo])r"r!rr!)rTr$rr^)rZrrr)rrrr-r9r8rWr rrrr(r(#s��$�/�b8��0'rr(c��eZdZdd�Zdd�Zy)�SchemaGeneratorc��||_yr*)� base_schema)rrbs r�__init__zSchemaGenerator.__init__�s ��&��rc�D�t|j�}|jdi�|j|�}|D]b}|j |j �}|s�!|j |dvri|d|j <||d|j |j<�d|S)N�paths)rrb� setdefaultr9rWr%r"r#)rr,r[rFr?rVs rr-zSchemaGenerator.get_schema�s����d�&�&�'�����'�2�&��+�+�F�3��&�H��)�)�(�-�-�8�F����}�}�F�7�O�3�13��w��� � �.�CI�F�7�O�H�M�M� *�8�+?�+?� @�'�� rN)rbr^r�Noner\)rrrrcr-rrrr`r`s ��'�rr`)� __future__rr=�re�typing�starlette.requestsr�starlette.responsesr�starlette.routingrrrr r�ModuleNotFoundErrorr � NamedTupler �compilerMr(r`rrr�<module>rqs���"�� � �&�(�;�;��� L�h�L�+�6�$�$�+� '�B�J�J�x�0��Y'�Y'�x�)���e�� �D��s�A8�8B�B

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/noah-vh/mcp-server-clickup'

If you have feedback or need assistance with the MCP directory API, please join our Discord server