Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Bitbucket Api Laravel Package

gentle/bitbucket-api

PHP Bitbucket API wrapper (PHP 5.4+) using cURL and Buzz. Provides a simple client for interacting with Bitbucket endpoints, with full documentation and optional PHPUnit test suite. MIT licensed.

View on GitHub
Deep Wiki
Context7

layout: default permalink: /examples/repositories/webhooks.html title: WebHooks

WebHooks

This resource manages webhooks on a repository. The administrators of the repository are the only users who can create, access, update, or delete the webhook.

Prepare:

$uuid	= '30b60aee-9cdf-407d-901c-2de106ee0c9d'; // unique identifier of the webhook

{% include auth.md var_name="hooks" class_ns="Repositories\Hooks" %}

Get a webhook:

$hooks->get($account_name, $repo_slug, $uuid);

HINT: You can use $hooks->all() method to get a list of all available hooks and their unique identifiers.

Get a list of webhooks:

$hooks->all($account_name, $repo_slug);

Create a new webhook:

$hook->create($account_name, $repo_slug, array(
    'description' => 'Webhook Description',
    'url' => 'http://requestb.in/xxx',
    'active' => true,
    'events' => array(
        'repo:push',
        'issue:created',
        'issue:updated'
    )
));

HINT: For a full list of available events, see Event Payloads page.

Update a webhook:

Add a new event pullrequest:approved to our webhook:

$hook->update($account_name, $repo_slug, $uuid, array(
    'description' => 'Webhook Description',
    'url' => 'http://requestb.in/xxx',
    'active' => true,
    'events' => array(
        'repo:push',
        'issue:created',
        'issue:updated',
        'pullrequest:approved'
    )
));

HINT: Bitbucket doesn't offer a patch endpoint, so you need to send the entire object represensation in order to update.

Delete a webhook:

$hook->delete($account_name, $repo_slug, $uuid);

Related:

  • [Authentication]({{ site.url }}/examples/authentication.html)
  • BB Wiki
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky