+
    –°³jf!  ã                   ó0  € R t ^ RIt^ RIHtHtHt ^ RIt^ RIHt ^ RI	H
t
 ^RIHtHtHt ^RIHtHt ^RIHt ]! ]! ]
4      R,          4      t]P*                  ! R	] U u/ uF  q V bK  	  up ]R
7      t]! ]4      t]P*                  ! R] Uu/ uF  qVbK  	  up]R
7      tR R lt]! RR7      t]P9                  R. R+OR7      R,R R ll4       t]P9                  RR.R7      R,R R ll4       t]P9                  R. R-OR7      R.R R ll4       t]P9                  R. R/OR7      R.R R ll4       t ]P9                  RR.R7      R,R  R! ll4       t!]P9                  R"R#.R7      R,R$ R% ll4       t"]P9                  R&R'R(.R7      R0R) R* ll4       t#R# u up i u upi )1z=Contains commands to manage webhooks on the Hugging Face Hub.N)Ú	AnnotatedÚget_argsÚget_type_hints)ÚWEBHOOK_DOMAIN_T)ÚWebhookWatchedItem)ÚTokenOptÚ
get_hf_apiÚtyper_factory)ÚArgumentÚOption)ÚoutÚtypeÚWatchedItemType)r   ÚWebhookDomainc                ó\   € V ^8„  d   QhR\         \        ,          R\         \        ,          /# )é   ÚvaluesÚreturn)ÚlistÚstrr   )Úformats   "Ú]/home/luca/screen-checking/.venv/lib/python3.14/site-packages/huggingface_hub/cli/webhooks.pyÚ__annotate__r   )   s$   € ÷ ñ œœc�ð ¤tÔ,>Õ'?ñ ó    c           	     ób  € . p\        \        4      pV  F—  pRV9  d-   \        P                  ! RV RRP	                  V4       R24      hVP                  R^4      w  rEWB9  d-   \        P                  ! RV RRP	                  V4       R24      hVP                  \        WER7      4       K™  	  V# )a9  Parse 'type:name' strings into WebhookWatchedItem objects.

Args:
    values: List of strings in the format 'type:name'
        (e.g., 'model:bert-base-uncased', 'org:HuggingFace').

Returns:
    List of WebhookWatchedItem objects.

Raises:
    click.BadParameter: If any value doesn't match the expected format.
Ú:zCExpected format 'type:name' (e.g. 'model:bert-base-uncased'), got 'z'. Valid types: z, Ú.zInvalid type ')r   Úname)ÚtupleÚ_WATCHED_TYPESÚclickÚBadParameterÚjoinÚsplitÚappendr   )r   ÚitemsÚvalid_typesÚvÚkindr   s   &     r   Ú_parse_watchr)   )   s»   € ð €EÜœÓ'€KÛˆØ�aŒ<Ü×$Ò$ØUÐVWÐUXð Y!Ø!%§¡¨;Ó!7Ð 8¸ð;óð ð —W‘W˜S !“_‰
ˆØÔ"Ü×$Ò$ ~°d°VÐ;KÈDÏIÉIÐVaÓLbÐKcÐcdÐ%eÓfÐfØ�‰Ô'¨TÔ=Ö>ñ ð €Lr   zManage webhooks on the Hub.©Úhelpz	list | ls)Úexamplesc                ó(   € V ^8„  d   QhR\         RR/# )r   Útokenr   N)r   )r   s   "r   r   r   P   s   € ÷ ñ Üðà	ñr   c                ó¦  € \        V R7      pVP                  4        UUu. uF‡  pRVP                  RVP                  ;'       g    RRVP                  RVP
                  ;'       g    . RVP                  ;'       g    .  Uu. uF  q3P                   RVP                   2NK  	  up/NK‰  	  ppp\        P                  ! V4       R	# u upi u uppi )
z'List all webhooks for the current user.©r.   ÚidÚurlz(job)ÚdisabledÚdomainsÚwatchedr   N)r   Úlist_webhooksr1   r2   r3   r4   r5   r   r   r   Útable)r.   ÚapiÚwÚwiÚresultss   &    r   Úwebhooks_lsr<   H   s»   € ô ˜5Ô
!€Cð ×"Ñ"Ô$ô	ñ %ˆAð �!—$‘$Ø�1—5‘5×#Ð#˜GØ˜Ÿ
™
Ø�q—y‘y—� BØ¸!¿)¹)¿/¸/Àr¸/ÓK¹/°2Ÿ7™7˜) 1 R§W¡W IÓ.¹/ÑKó	
ñ %ð ñ 	ô ‡I‚IˆgÖùò	 Lùó	s)    $CÁ!CÁ'CÁ=CÂ#CÂ%CÃCÚinfozhf webhooks info abc123c                ób   € V ^8„  d   QhR\         \        \        RR7      3,          R\        RR/# )r   Ú
webhook_idzThe ID of the webhook.r*   r.   r   N©r   r   r
   r   )r   s   "r   r   r   h   s6   € ÷ ñ Üœ#œxÐ-EÔFÐFÕGðäðð 
ñr   c                ól   € \        VR7      pVP                  V 4      p\        P                  ! V4       R# )z'Show full details for a single webhook.r0   N)r   Úget_webhookr   Údict©r?   r.   r8   Úwebhooks   &&  r   Úwebhooks_inforF   b   s(   € ô ˜5Ô
!€CØ�o‰o˜jÓ)€GÜ‡H‚HˆWÖr   Úcreatec                ó´  € V ^8„  d   QhR\         \        \        ,          \        RRR7      3,          R\         \        R,          \        RR7      3,          R\         \        R,          \        R	R
R7      3,          R\         \        \        ,          R,          \        RRR7      3,          R\         \        R,          \        RR7      3,          R\
        RR/# )r   Úwatchú--watchzRItem to watch, in 'type:name' format (e.g. 'model:bert-base-uncased'). Repeatable.r*   r2   NzBURL to send webhook payloads to. Mutually exclusive with --job-id.Újob_idz--job-idz]ID of a Job to trigger (from job.id) instead of pinging a URL. Mutually exclusive with --url.Údomainú--domainzNDomain to watch: 'repo' or 'discussions'. Repeatable. Defaults to all domains.Úsecretz.Optional secret used to sign webhook payloads.r.   r   )r   r   r   r   r   r   )r   s   "r   r   r   z   sé   € ÷ ,1ñ ,1ÜÜŒS�	ÜØØeô	
ð	õð,1ô 
Üˆd�
ÜÐXÔYð	[õ
ð,1ô Üˆd�
ÜØØpô	
ð	õð,1ô& ÜŒ]Õ˜dÕ"ÜØØaô	
ð	õð',1ô4 Üˆd�
ÜÐDÔEð	Gõð5,1ô< ð=,1ð> 
ñ?,1r   c                ól  € Ve   Ve   \         P                  ! R4      hVf   Vf   \         P                  ! R4      h\        VR7      p\        V 4      pV'       d   V Uu. uF  qˆP                  NK  	  upMRp	VP                  WWyVR7      p
\        P                  ! RV
P                  R7       R# u upi )ztCreate a new webhook.

Provide either --url (to ping a remote server) or --job-id (to trigger a Job), but not both.
Nz+Provide either --url or --job-id, not both.z!Provide either --url or --job-id.r0   )r2   rK   r5   r4   rN   zWebhook created©r1   )	r    r!   r   r)   ÚvalueÚcreate_webhookr   Úresultr1   )rI   r2   rK   rL   rN   r.   r8   Úwatched_itemsÚdr4   rE   s   &&&&&&     r   Úwebhooks_createrV   r   sš   € ðX ‚˜6Ò-Ü× Ò Ð!NÓOÐOØ
‚{�v’~Ü× Ò Ð!DÓEÐEÜ
˜5Ô
!€CÜ  Ó'€Mß+1¡Ó'¡˜1�wŒw¡Ò'°t€GØ× Ñ  SÀÐhnÐ Óo€GÜ‡J‚JÐ  W§Z¡Z×0ùò (s   Á B1Úupdatec                ó²  € V ^8„  d   QhR\         \        \        RR7      3,          R\         \        R,          \        RR7      3,          R\         \        \        ,          R,          \        RR	R7      3,          R
\         \        \
        ,          R,          \        RRR7      3,          R\         \        R,          \        RR7      3,          R\        RR/# )r   r?   z The ID of the webhook to update.r*   r2   Nz$New URL to send webhook payloads to.rI   rJ   ziNew list of items to watch, in 'type:name' format. Repeatable. Replaces the entire existing watched list.rL   rM   zBNew list of domains to watch: 'repo' or 'discussions'. Repeatable.rN   z)New secret used to sign webhook payloads.r.   r   )r   r   r
   r   r   r   r   )r   s   "r   r   r   ±   sß   € ÷ "1ñ "1Üœ#œxÐ-OÔPÐPÕQð"1ä	Üˆd�
ÜÐ:Ô;ð	=õ
ð"1ô ÜŒS�	�DÕÜØðIô	
ð	õ	ð"1ô  ÜŒ]Õ˜dÕ"ÜØØUô	
ð	õð!"1ô. Üˆd�
ÜÐ?Ô@ð	Bõð/"1ô6 ð7"1ð8 
ñ9"1r   c                ó  € \        VR7      pV'       d   \        V4      MRpV'       d   V Uu. uF  qˆP                  NK  	  upMRp	VP                  WWyVR7      p
\        P
                  ! RV
P                  R7       R# u upi )z>Update an existing webhook. Only provided options are changed.r0   N)r2   r5   r4   rN   zWebhook updatedrP   )r   r)   rQ   Úupdate_webhookr   rS   r1   )r?   r2   rI   rL   rN   r.   r8   rT   rU   r4   rE   s   &&&&&&     r   Úwebhooks_updater[   ©   sg   € ôL ˜5Ô
!€Cß+0”L Ô'°d€Mß+1¡Ó'¡˜1�wŒw¡Ò'°t€GØ× Ñ  ¸mÐekÐ Ól€GÜ‡J‚JÐ  W§Z¡Z×0ùò (s   ®A?Úenablezhf webhooks enable abc123c                ób   € V ^8„  d   QhR\         \        \        RR7      3,          R\        RR/# )r   r?   z The ID of the webhook to enable.r*   r.   r   Nr@   )r   s   "r   r   r   Ü   s6   € ÷ 1ñ 1Üœ#œxÐ-OÔPÐPÕQð1äð1ð 
ñ1r   c                ó„   € \        VR7      pVP                  V 4      p\        P                  ! RVP                  R7       R# )zEnable a disabled webhook.r0   zWebhook enabledrP   N)r   Úenable_webhookr   rS   r1   rD   s   &&  r   Úwebhooks_enabler`   Ö   s1   € ô ˜5Ô
!€CØ× Ñ  Ó,€GÜ‡J‚JÐ  W§Z¡Z×0r   Údisablezhf webhooks disable abc123c                ób   € V ^8„  d   QhR\         \        \        RR7      3,          R\        RR/# )r   r?   z!The ID of the webhook to disable.r*   r.   r   Nr@   )r   s   "r   r   r   ì   s6   € ÷ 2ñ 2Üœ#œxÐ-PÔQÐQÕRð2äð2ð 
ñ2r   c                ó„   € \        VR7      pVP                  V 4      p\        P                  ! RVP                  R7       R# )zDisable an active webhook.r0   zWebhook disabledrP   N)r   Údisable_webhookr   rS   r1   rD   s   &&  r   Úwebhooks_disablere   æ   s1   € ô ˜5Ô
!€CØ×!Ñ! *Ó-€GÜ‡J‚JÐ! g§j¡j×1r   Údeletezhf webhooks delete abc123zhf webhooks delete abc123 --yesc                ó    € V ^8„  d   QhR\         \        \        RR7      3,          R\         \        \	        RRRR7      3,          R\
        R	R
/# )r   r?   z The ID of the webhook to delete.r*   Úyesz--yesz-yzSkip confirmation prompt.r.   r   N)r   r   r
   Úboolr   r   )r   s   "r   r   r   ý   s^   € ÷ 1ñ 1Üœ#œxÐ-OÔPÐPÕQð1ä	ÜÜØØØ,ô	
ð	õ
ð1ô ð1ð 
ñ1r   c                ó¨   € \         P                  ! RV  R2VR7       \        VR7      pVP                  V 4       \         P                  ! RV R7       R# )zDelete a webhook permanently.z)Are you sure you want to delete webhook 'z'?)rh   r0   zWebhook deletedrP   N)r   Úconfirmr   Údelete_webhookrS   )r?   rh   r.   r8   s   &&& r   Úwebhooks_deleterm   ö   sD   € ô( ‡K‚KÐ;¸J¸<ÀrÐJÐPSÕTÜ
˜5Ô
!€CØ×Ñ�zÔ"Ü‡J‚JÐ  Z×0r   )zhf webhooks lszhf webhooks ls --format jsonzhf webhooks ls --format quiet)N)zQhf webhooks create --url https://example.com/hook --watch model:bert-base-uncasedzjhf webhooks create --url https://example.com/hook --watch org:HuggingFace --watch model:gpt2 --domain repozJhf webhooks create --job-id 687f911eaea852de79c4a50a --watch user:julien-c)NNNNN)z8hf webhooks update abc123 --url https://new-url.com/hookz:hf webhooks update abc123 --watch model:gpt2 --domain repoz,hf webhooks update abc123 --secret newsecret)FN)$Ú__doc__ÚenumÚtypingr   r   r   r    Úhuggingface_hub.constantsr   Úhuggingface_hub.hf_apir   Ú
_cli_utilsr   r   r	   Ú
_frameworkr
   r   Ú_outputr   r   ÚEnumr   r   Ú_DOMAIN_TYPESr   r)   Úwebhooks_cliÚcommandr<   rF   rV   r[   r`   re   rm   )ÚtrU   s   00r   Ú<module>r{      sý  ðñ Dã ß 6Ñ 6ã å 6Ý 5÷ñ ÷
 )Ý ñ ™.Ð);Ó<¸VÕDÓE€Ø—)’)Ð-¹nÓ/M¹n¸°1²¹nÑ/MÐTWÔX€áÐ)Ó*€Ø—	’	˜/¹-Ó+H¹-°Q¨qªD¹-Ñ+HÈsÔS€õñ8 Ð"?Ô@€ð ×ÑØòð ó öóðð$ ×ÑØ
à!ðð ó öóðð ×ÑØòð ó ö,1óð,1ð^ ×ÑØòð ó ö"1óð"1ðJ ×ÑØà#ðð ó ö1óð1ð ×ÑØà$ðð ó ö2óð2ð ×ÑØà#Ø)ðð ó ö1óò1ùòu 0Nùò ,Is   ÁF
ÂF
