+
    Di0                       ^ RI Ht ^ RIt^ RIt^ RIHt ^ RIHtHt ^ RI	H
t
 ^ RIHt ^ RIHtHtHtHt  ^ RIt ! R R	]4      t ! R
 R]4      t]P,                  ! R4      t ! R R4      t ! R R]4      tR#   ] d    Rt LJi ; i)    )annotationsN)Callable)Any
NamedTuple)Request)Response)	BaseRouteHostMountRoutec                  &    ] tR t^tRtR R ltRtR# )OpenAPIResponsezapplication/vnd.oai.openapic                    V ^8  d   QhRRRR/# )   contentr   returnbytes )formats   "o/Users/tonyclaw/.openclaw/workspace/services/omi-webhook/venv/lib/python3.14/site-packages/starlette/schemas.py__annotate__OpenAPIResponse.__annotate__   s     L Lc Le L    c                	    \         f   Q R4       h\        V\        4      '       g   Q R4       h\         P                  ! VRR7      P	                  R4      # )Nz2`pyyaml` must be installed to use OpenAPIResponse.z<The schema passed to OpenAPIResponse should be a dictionary.F)default_flow_stylezutf-8)yaml
isinstancedictdumpencode)selfr   s   &&r   renderOpenAPIResponse.render   sI    U!UU'4((h*hh(yyU;BB7KKr   r   N)__name__
__module____qualname____firstlineno__
media_typer"   __static_attributes__r   r   r   r   r      s    .JL Lr   r   c                  6    ] tR t^t$ R]R&   R]R&   R]R&   RtR# )EndpointInfostrpathhttp_methodCallable[..., Any]funcr   N)r$   r%   r&   r'   __annotations__r)   r   r   r   r+   r+      s    
I
r   r+   z:\w+}c                  R    ] tR t^$tR R ltR R ltR R ltR R ltR	 R
 ltRt	R# )BaseSchemaGeneratorc                    V ^8  d   QhRRRR/# r   routeslist[BaseRoute]r   dict[str, Any]r   )r   s   "r   r    BaseSchemaGenerator.__annotate__%   s     $ $ $^ $r   c                	    \        4       hN)NotImplementedError)r!   r6   s   &&r   
get_schemaBaseSchemaGenerator.get_schema%   s    !##r   c                    V ^8  d   QhRRRR/# )r   r6   r7   r   zlist[EndpointInfo]r   )r   s   "r   r   r9   (   s     / /O /8J /r   c           
        . pV EFL  p\        V\        \        ,          4      '       d   VP                  ;'       g    . p\        V\        4      '       d   V P	                  VP
                  4      pMRpV P                  V4       Uu. uF?  p\        RP                  WEP
                  34      VP                  VP                  R7      NKA  	  ppVP                  V4       K  \        V\        4      '       d   VP                  '       g   EK  \        P                  ! VP                   4      '       g'   \        P"                  ! VP                   4      '       dy   V P	                  VP
                  4      pVP$                  ;'       g    R. F?  pVR8X  d   K  VP'                  \        WGP)                  4       VP                   4      4       KA  	  EK  V P	                  VP
                  4      pR F`  p\+        VP                   V4      '       g   K!  \-        VP                   V4      pVP'                  \        WGP)                  4       V4      4       Kb  	  EKO  	  V# u upi )z
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.   r0   GETHEAD)getpostputpatchdeleteoptions)r   r   r
   r6   _remove_converterr-   get_endpointsr+   joinr.   r0   extendr   include_in_schemainspect
isfunctionendpointismethodmethodsappendlowerhasattrgetattr)	r!   r6   endpoints_inforouter-   sub_endpointsub_endpointsmethodr0   s	   &&       r   rK   !BaseSchemaGenerator.get_endpoints(   s    .0E%..++eU++11%**=DD )-(:(:6(B! )C !WWd,=,=%>?$0$<$<)..
 )C  ! %%m4u--U5L5L5L##ENN33w7G7G7W7W--ejj9#mm66w6F' ")),t\\^U^^*\] 7
 --ejj9RF"5>>6:: "5>>6:D")),t\\^T*RS	 S9 D 7!s   AIc                    V ^8  d   QhRRRR/# )r   r-   r,   r   r   )r   s   "r   r   r9   Y   s     8 8c 8c 8r   c                .    \         P                  RV4      # )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)r!   r-   s   &&r   rJ   %BaseSchemaGenerator._remove_converterY   s     ),,S$77r   c                    V ^8  d   QhRRRR/# )r   func_or_methodr/   r   r8   r   )r   s   "r   r   r9   b   s      .@ ^ r   c                    VP                   pV'       g   / # \        f   Q R4       hVP                  R4      R,          p\        P                  ! V4      p\	        V\
        4      '       g   / # V# )zP
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_loadr   r   )r!   re   	docstringparseds   &&  r   parse_docstring#BaseSchemaGenerator.parse_docstringb   se     #**	IU!UU
 OOE*2.		*&$'' Ir   c                    V ^8  d   QhRRRR/# )r   requestr   r   r   r   )r   s   "r   r   r9   z   s     ' 'w '8 'r   c                	h    VP                   P                  pV P                  VR 7      p\        V4      # ))r6   )appr6   r=   r   )r!   rp   r6   schemas   &&  r   r   #BaseSchemaGenerator.OpenAPIResponsez   s,    ##/v&&r   r   N)
r$   r%   r&   r'   r=   rK   rJ   rm   r   r)   r   r   r   r3   r3   $   s!    $/b80' 'r   r3   c                  .    ] tR t^tR R ltR R ltRtR# )SchemaGeneratorc                    V ^8  d   QhRRRR/# )r   base_schemar8   r   Noner   )r   s   "r   r   SchemaGenerator.__annotate__   s     ' 'N 't 'r   c                	    Wn         R # r;   rx   )r!   rx   s   &&r   __init__SchemaGenerator.__init__   s    &r   c                    V ^8  d   QhRRRR/# r5   r   )r   s   "r   r   rz      s       ^ r   c                	z   \        V P                  4      pVP                  R / 4       V P                  V4      pV F|  pV P	                  VP
                  4      pV'       g   K(  VP                  VR ,          9  d   / VR ,          VP                  &   WRR ,          VP                  ,          VP                  &   K~  	  V# )paths)r   rx   
setdefaultrK   rm   r0   r-   r.   )r!   r6   rs   rX   rQ   rl   s   &&    r   r=   SchemaGenerator.get_schema   s    d&&''2&++F3&H))(--8F}}F7O313w.CI7OHMM*8+?+?@ ' r   r|   N)r$   r%   r&   r'   r}   r=   r)   r   r   r   rv   rv      s    ' r   rv   )
__future__r   rO   recollections.abcr   typingr   r   starlette.requestsr   starlette.responsesr   starlette.routingr	   r
   r   r   r   ModuleNotFoundErrorr   r+   compilera   r3   rv   r   r   r   <module>r      s    "  	 $ " & ( ; ;
Lh L:  JJx0 Y' Y'x) e  Ds   A9 9	BB