
Security News
The Changelog Podcast: Practical Steps to Stay Safe on npm
Learn the essential steps every developer should take to stay secure on npm and reduce exposure to supply chain attacks.
cybersource-rest-auth
Advanced tools
This project provides a simple Node.js helper library that simplifies authentication to the CyberSource REST API
Note: Support for building the SDK with npm has been made. All initial libraries were installed with npm, however.
The Authentication SDK works for POST, GET, PUT and DELETE requests. It works with any one of the two authentication mechanisms, which are HTTP signature and JWT token.
   "authenticationType"  : "http_signature"
   "merchantID"          : <merchantID>
   "runEnvironment"      : "CyberSource.Environment.SANDBOX"
   "merchantKeyId"       : <merchantKeyId>
   "merchantsecretKey"   : <merchantsecretKey>
   "enableLog"           : true
   "logDirectory"        : "./log"
   "logMaximumSize"      : 10485760
   "logFilename"         : "cybs"
   "useMetaKey"          : false
   "authenticationType"  : "jwt"
   "merchantID"          : <merchantID>
   "runEnvironment"      : "CyberSource.Environment.SANDBOX"
   "keyAlias"            : <keyAlias>
   "keyPass"             : <keyPass>
   "keyFileName"         : <keyFileName>
   "keysDirectory"       : <keysDirectory>
   "enableLog"           : true
   "logDirectory"        : "./log"
   "logMaximumSize"      : 10485760
   "logFilename"         : "cybs"
   "useMetaKey"          : false
MetaKey can be used for HTTP Signature and JWT authentication
For HTTP Signature Authentication -
   "authenticationType"  : "http_Signature"
   "merchantID"          : <child merchantID>
   "merchantKeyId"       : <MetaKey merchantKeyId>
   "merchantsecretKey"   : <Metakey merchantsecretKey>
   "useMetaKey"          : true
   "portfolioID"         : <Portfolio ID>
For JWT Authentication -
   "authenticationType"  : "jwt"
   "merchantID"          : <child merchantID>
   "keyAlias"            : <keyAlias>
   "keyPassword"         : <keyPassword>
   "keyFileName"         : <keyFileName>
   "keysDirectory"       : <keysDirectory>
   "useMetaKey"          : true
Cybersource-rest-auth maintains a complete sandbox environment for testing and development purposes. This sandbox environment is an exact duplicate of our production environment with the transaction authorization and settlement process simulated. By default, this SDK is configured to communicate with the sandbox environment. To switch to the production environment, set the appropriate environment constant in cybs.json file.
For example:
  // For PRODUCTION use
  "runEnvironment"      : "CyberSource.Environment.PRODUCTION"
The API Reference Guide provides examples of what information is needed for a particular request and how that information would be formatted. Using those examples, you can easily determine what methods would be necessary to include that information in a request using this SDK.
    $ git clone https://github.com/CyberSource/cybersource-rest-auth-nodejs
    $ npm install
    $ node src\[CodeSampleName]
For example:
    $ node src\GetMethod.js
This repository is distributed under a proprietary license.
FAQs
CyberSource SDK for authenticating to the REST API
We found that cybersource-rest-auth demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Learn the essential steps every developer should take to stay secure on npm and reduce exposure to supply chain attacks.

Security News
Experts push back on new claims about AI-driven ransomware, warning that hype and sponsored research are distorting how the threat is understood.

Security News
Ruby's creator Matz assumes control of RubyGems and Bundler repositories while former maintainers agree to step back and transfer all rights to end the dispute.