You are here

public function AcceptJs::getCcaApiId in Commerce Authorize.Net 8

Get the CCA API Identifier.

Return value

string The CCA API Identifier.

File

src/Plugin/Commerce/PaymentGateway/AcceptJs.php, line 155

Class

AcceptJs
Provides the Accept.js payment gateway.

Namespace

Drupal\commerce_authnet\Plugin\Commerce\PaymentGateway

Code

public function getCcaApiId() {
  if ($this->configuration['cca_status']) {

    // Test API Id.
    // @see https://developer.cardinalcommerce.com/try-it-now.shtml
    if ($this->configuration['mode'] == 'test') {
      return '582e0a2033fadd1260f990f6';
    }
    else {
      return $this->configuration['cca_api_id'];
    }
  }
}