# iFrame Transaction NPM Module

## iFrame-Transaction-NPM-Module-Demo

Files to demonstrate how to use the Merrco Payfirma Simple Payment Module. <https://www.npmjs.com/package/merrco-payfirma-simple-pay-module?activeTab=readme>&#x20;

Install:`npm i merrco-payfirma-simple-pay-module`

### Basic HTML Demo files

* Follow source code and comments in the following files
* `basic-html-demo/simple_test.html`
* `basic-html-demo/custom_css_test.html`

### React Demo

* View souce code + comments `react-demo/iframe-demo/src/App.js`
* cd into `react-demo/iframe-demo`
* Make sure you are using **Node LTS v18.17.1** (Latest LTS: Hydrogen) or higher `nvm use lts/hydrogen`
* Run with `npm start`

### To get Iframe Access Token

Please, Login at PayHQ ang go to Settings. [PayHQ Settings](https://hq.payfirma.com/#/settings/hpp)

<figure><img src="https://user-images.githubusercontent.com/67436452/153307893-f063df7d-8459-42fd-876c-eb364c9fc489.png" alt=""><figcaption></figcaption></figure>

#### Create Iframe Access Token

<figure><img src="https://user-images.githubusercontent.com/67436452/153307684-87572649-d819-43fa-acab-19f53b6fb226.png" alt=""><figcaption></figcaption></figure>
