New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More

@adyen/adyen-web

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@adyen/adyen-web

[![npm](https://img.shields.io/npm/v/@adyen/adyen-web.svg)](https://www.npmjs.com/package/@adyen/adyen-web)


Version published
Maintainers
5
Created

What is @adyen/adyen-web?

@adyen/adyen-web is a comprehensive JavaScript library for integrating Adyen's payment solutions into web applications. It provides a wide range of functionalities to handle various payment methods, including credit cards, wallets, and local payment methods. The package is designed to simplify the integration process, ensuring secure and seamless payment experiences for users.

What are @adyen/adyen-web's main functionalities?

Drop-in Integration

The Drop-in integration provides a ready-made UI for accepting payments. It supports a wide range of payment methods and handles the entire payment flow, including payment submission and additional details collection.

const AdyenCheckout = require('@adyen/adyen-web');
const checkout = new AdyenCheckout({
  clientKey: 'test_CLIENT_KEY',
  environment: 'test',
  onSubmit: (state, dropin) => {
    // Handle the payment submission
  },
  onAdditionalDetails: (state, dropin) => {
    // Handle additional details
  }
});
const dropin = checkout.create('dropin').mount('#dropin-container');

Component Integration

The Component integration allows you to integrate individual payment method components, such as credit cards, into your custom UI. This provides more flexibility and control over the payment experience.

const AdyenCheckout = require('@adyen/adyen-web');
const checkout = new AdyenCheckout({
  clientKey: 'test_CLIENT_KEY',
  environment: 'test'
});
const card = checkout.create('card').mount('#card-container');

Handling Payment Methods

This feature allows you to retrieve and handle the available payment methods for a specific merchant account. It provides a list of payment methods that can be displayed to the user.

const AdyenCheckout = require('@adyen/adyen-web');
const checkout = new AdyenCheckout({
  clientKey: 'test_CLIENT_KEY',
  environment: 'test'
});
checkout.paymentMethodsResponse.then(paymentMethodsResponse => {
  // Handle the available payment methods
  console.log(paymentMethodsResponse);
});

Other packages similar to @adyen/adyen-web

FAQs

Package last updated on 21 Jan 2025

Did you know?

Socket

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.

Install

Related posts