Undefined index: secret
lluminateFoundationBootstrapHandleExceptions::handleError
C:wamp64wwwchefruntownvendorsrmklivepaypalsrcTraitsPayPalRequest.php:329
private function setApiProviderConfiguration($credentials){
// Setting PayPal API Credentials
collect($credentials[$this->mode])->map(function ($value, $key) {
$this->config[$key] = $value;
});
// Setup PayPal API Signature value to use.
$this->config['signature'] = empty($this->config['certificate']) ?
$this->config['secret'] : $this->config['certificate'];
$this->paymentAction = $credentials['payment_action'];
$this->locale = $credentials['locale'];
$this->certificate = $this->config['certificate'];
$this->validateSSL = $credentials['validate_ssl'];
$this->setApiProvider($credentials);
}
2
Answers
I updated the paypal.php file found in my config folder with this
Basically, you need to match the
.env
variables andconfig/paypa.php
variables.You can retrieve these information by navigating to
paypal sandbox dashboard > leftnav > accounts > sandbox > list of account > view/edit account (action drop down) > API Credentials tab
.and your config/paypal.php should have the same variables passed.
Note the sandbox and live array, I have commented the default array items with new one.