Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use coinbase ? #5

Open
skynetweb opened this issue Jul 6, 2015 · 3 comments
Open

How to use coinbase ? #5

skynetweb opened this issue Jul 6, 2015 · 3 comments

Comments

@skynetweb
Copy link

Hi there, i was hoping to get a sample code here's what i got so far

        $gateway = Omnipay::create('Coinbase');
        // Initialise the gateway
        $gateway->initialize(array(
           'amount' => '0.001',
           'currency' => 'BTC',
           'description' => 'Test',
           'apiKey' => 'secret_code',
           'secret' => 'api_key'
        ));

        $request = $gateway->purchase(array(
           'amount'            => '0.01',
           'currency'          => 'USD',
           'description'      => 'socks',
           'apiKey' => 'api_key',
           'secret' => 'secret_code'
        ));

        $response = $request->send();

        var_dump($response->isSuccessful());exit; 

But so far i get false can you please help me ?

@ChristopherDosin
Copy link

+1

1 similar comment
@punkeel
Copy link

punkeel commented Dec 19, 2016

+1

@delatbabel
Copy link
Contributor

I would think that you need to provide the apiKey and secret as part of the $gateway->initialize() call. It also appears that you need an account ID.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants