---
title: "How to disable hooks using Bitbucket Command Line Interface"
canonical: "https://support.appfire.com/space/SUPPORT/89142349/How%20to%20disable%20hooks%20using%20Bitbucket%20Command%20Line%20Interface"
format: markdown
---
<span style="color: #333333">This article explains how to disable a hook in a Bitbucket repository using Command Line Interface (CLI)</span>

## <span style="color: #333333">Instructions</span>

1. <span style="color: #333333">Using the </span>[<span style="color: #333333">disableHook</span>](https://appfire.atlassian.net/wiki/spaces/SCLI/pages/73368998/disableHook)<span style="color: #333333"> action, a pre-receive or post-receive hook can be disabled from a repository of Bitbucket. </span>
  <span style="color: #333333">In above CLI action, </span>
  - [*<span style="color: #333333">--project</span>*](https://appfire.atlassian.net/wiki/spaces/SCLI/pages/73368805/--project)<span style="color: #333333"> value refers to Project key, name, or id.</span>
  - [<span style="color: #333333">--repository</span>](https://appfire.atlassian.net/wiki/spaces/SCLI/pages/73368867/--repository)<span style="color: #333333"> value refers to Repository slug, name, or id.</span>
  - [<span style="color: #333333">--hook</span>](https://appfire.atlassian.net/wiki/spaces/SCLI/pages/73367639/--hook)<span style="color: #333333"> value refers to Hook name or key of the form </span>*<span style="color: #333333">plugin key:hook key</span>*<span style="color: #333333">.</span>
2. <span style="color: #333333">To check the status of the hook, navigate to </span>***<span style="color: #333333">Repositories > Repository settings > Hooks</span>***<span style="color: #333333">. The hook is disabled as shown in the screenshot below:</span>  
> Macro (inline-media-image)


> ℹ️ <span style="color: #333333">It is recommended to test this scenario in a non-production environment or run the action with the </span>[*<span style="color: #333333">--simulate</span>*](https://appfire.atlassian.net/wiki/spaces/BCLI/pages/65933690/Parameters#Parameters-simulate)<span style="color: #333333"> parameter to verify the behavior before deploying.</span>

> Macro (__confluenceADFMigrationUnsupportedContentInternalExtension__)