Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

KindCoder-no/node-vipps-api

Repository files navigation

THIS IS OUTDATED

The Vipps api has changed, a new version of this package may come later (Pull Requests are welcome)

node-vipps-api

A simple package to use the Vipps API

You can view the required body models documented in Vipps swagger documentation

Ecom Documentation

Recurring Documentation

This is an updated version of CrystallizeAPI/node-vipps

Install

npm install vipps-api

Usage

Initiate the client

const VippsClient = require('vipps-api')
const client = new VippsClient({
 id: "MY_VIPPS_CLIENT_ID",
 secret: "MY_VIPPS_CLIENT_SECRET",
 subscriptionId: "MY_VIPPS_SUB_KEY",
 testDrive: isProd ? false : true
});

Initiate a payment

await client.initiatePayment({order:VippsCheckoutModel});

Capture a payment

await client.capture({ orderId: VippsOrderId, body: VippsCaptureBodyModel });

Refund a payment

await client.refund({ orderId: VippsOrderId, body: VippsRefundBodyModel });

Get order payment details

await client.getOrderDetails({ orderId: VippsOrderId});

Create Recurring Agreement

await client.createAgreement({ order: VippsAgreementModel});

Get Recurring Agreement details

await client.getAgreement({ agreementId: VippsAgreementId });

Update Recurring Agreement

await client.updateAgreement({ agreementId: VippsAgreementId, body: VippsAgreementModel});

Get an access token

await client.getAccessToken();

Todo:

  • Vipps Login

About

A simple package to use the Vipps API

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

AltStyle によって変換されたページ (->オリジナル) /