t1mmen/opauth-bitbucket

Opauth strategy for Bitbucket

1.0 2016-04-29 16:58 UTC

This package is not auto-updated.

Last update: 2024-04-13 17:19:01 UTC


README

Opauth strategy for Bitbucket authentication.

Implemented based on https://confluence.atlassian.com/bitbucket/oauth-on-bitbucket-cloud-238027431.html

Getting started

  1. Install Opauth-Bitbucket:

    Using git:

    cd path_to_opauth/Strategy
    git clone https://github.com/t1mmen/opauth-bitbucket.git bitbucket

Or, using Composer, just add this to your composer.json:

{
    "require": {
        "t1mmen/opauth-bitbucket": "*"
    }
}

Then run composer install.

  1. Create Bitbucket application at https://bitbucket.org/account under "Oauth" in left menu. This implementation requires the "email" scope set.

  2. Configure Opauth-Bitbucket strategy with at least Client ID and Client Secret.

  3. Direct user to http://path_to_opauth/bitbucket to authenticate

Strategy configuration

Required parameters:

<?php
'Bitbucket' => array(
  'client_id' => 'YOUR CLIENT ID',
  'client_secret' => 'YOUR CLIENT SECRET'
)

License

Opauth-Bitbucket is MIT Licensed Copyright © 2016 Timm Stokke (http://timm.stokke.me)