paymentiq-1click-client
v1.0.0-RC-19
Published
Integration bootstrapper for the PaymentIQ 1click client
Downloads
40
Maintainers
Readme
PaymentIQ-1click-client
Setup
npm install
npm start // serves built file at http://localhost:9092/dist/paymentiq-1click-client.js
Configure
Include paymentiq-1click-client script or npm package
<script type="text/javascript" src="http://static.paymentiq.io/paymentiq-1click-client/paymentiq-1click-client.js"></script>
or
npm i paymentiq-1click-client --save
<div id='piq-1-click'></div>
<script>
new _PaymentIQ1Click('#piq-1-click', {
environment: 'test',
clientId: 'CLIENT_ID',
provider: 'gii-bankid-se',
redirect_uri: 'https://www.getpostman.com/oauth2/callback', // just some endpoint that returns 200 + is registered in
country: 'SE',
ssn: 'YYMMDDXXXX',
authCookieName: 'JSESSIONID',
display: 'inline-popup'
},
(oneClick) => {
oneClick.on({
onComplete: (url, params) => {
console.log('Authorized and ready to show as signed in')
}
})
}
)
</script>
Parameters
|key |type |required|values |description |
|---------------|----------|--------|---------------------------------|------------------------------------------------------|
|clientId |string | true |CLIENT_ID |Your unique clientID generated in PIQ |
|environment |string | false |production
test
development
|What environment of PIQ to target |
|redirect_url |string | false |Endpoint that returns 200 . |Endpoint that will be called when a login is done. |
|provider |string | false |See Devcode identity providers|Pre select what login provider to use |
|country |string | true |SE
, NO
, GB
|What country do you want to target |
|authCookieName |string | true |JSESSIONID
|Name of the authCookie |
|ssn |string | false |NationalId |NationalId, will prefill and auto submit a login if provided |
|display |string | false |page
popup
inline-popup
|How should the login component be displayed. Defaults to page |
Build
npm run build // comiles project into a single dist file at dist/paymentiq-1click-client.js
Deploy
Jenkins is configured in 4 steps
- Build
- Deploy experimental version
- Deploy new version
- Deploy new version to npm
Changelog
Changes made for every version can be found here