Runner.js
Runner.js Overview
Runner.js is a browser-side JavaScript library used to tokenize and send sensitive payment information directly from a user’s browser, keeping your customers’ data secure and your software fully PCI-compliant. A single integration to Runner.js can be used to handle tokenization for all supported Payments API products in Run Developer.
The library is continually updated to support the gateways available through Run Developer and to provide more flexibility to you, our integrated partners. If you have any feedback or questions about the service, please reach out to us at integrations@runpayments.io
Runner.js Parameters
The following table is a list of possible parameters that can be passed when calling Runner.js to tokenize a customer’s payment account:
Examples
Cardpointe Gateway
Passing Merchant ID while using the same Public Key to render the correct version of the iFrame
Example:
Full HTML example:
Example:
Then in the init function, you should have cvvFieldSelector: '#cvvId',
Example:
Full HTML example:
When there is an error where the html element cannot be specified, check to ensure html includes form ID or credit card field identifier. The below must be present if using element: '#run-form'
<div id="run-form"></div>
Since cvvFieldSelector was omitted, runner.js will use the default #securityCode-container selector as well as the cardNumberFieldSelector if omitted, so #cardNumber-container selector should be used.
CYBS Gateway
The CBYS gateway uses custom field selectors for the card number and CVV iframes, and native <select> elements for expiration month/year. Pass the selectors via cardNumberFieldSelector and cvvFieldSelector in the runner.init call.
Example:
Payroc Gateway
The Payroc Gateway implementation requires specific field selectors and configuration options to properly handle form validation and tokenization.
ACH (iStream and Fiserv ACH)
Both iStream and Fiserv ACH gateways provide bank account tokenization with customizable field labels and validation. The implementation supports automatic or manual tokenization depending on your requirements.
iStream — Full Page Example
The following is a complete iStream ACH implementation using native HTML elements for account type and customer name. The accountTypeField and customerNameField parameters wire Runner.js directly to those elements — no separate label rendering is needed. The last4 of the account number is captured from the tokenization message event and can be used for display or reconciliation.
iStream does not apply CSS sanitization to the hosted iframe fields. Styles passed via the css parameter are applied directly.