npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

paytech-node-ts-sdk

v1.0.7

Published

PayTech SDK for seamless payment integrations

Readme

PayTech SDK 🚀

Un SDK simple pour intégrer PayTech dans vos applications Next.js / Node.js.

📦 Installation

Ajoutez le package à votre projet :

npm i paytech-node-ts-sdk



🔧 Configuration

Dans votre fichier .env, vous devez ajouter ces informations:

PAYTECH_API_KEY=Votre_API_KEY
PAYTECH_API_SECRET=Votre_API_SECRET

Ces clés sont fournies par PayTech lorsque vous vous inscrivez.

🚀 Utilisation
1️⃣ Créer une instance du SDK

Dans votre projet Next.js / Node.js, importez et configurez le SDK :

import { PayTech } from "paytech-node-ts-sdk";

const paytech = new PayTech(
  {
    apiKey: process.env.PAYTECH_API_KEY!,
    apiSecret: process.env.PAYTECH_API_SECRET!,
  }
);

2️⃣ Créer un paiement

Utilisez la méthode createPayment() pour générer un lien de paiement :

const paymentData = {
  item_name: "Iphone 7",
  item_price: "560000", 
  ref_command: "HBZZYZVUZZZV",
  ipn_url: "https://domaine.com/ipn",
  success_url: "https://domaine.com/success",
  cancel_url: "https://domaine.com/cancel", 
  env: 'test'
};

paytech.createPayment(paymentData)
  .then(response => {
    console.log("Lien de paiement :", response.redirect_url);  // URL pour rediriger l'utilisateur vers la page de paiement
  })
  .catch(error => console.error("Erreur paiement :", error));


Explication des paramètres :
item_name : Le nom de l'article ou du produit à payer.
item_price : Le prix de l'article (en format string).
ref_command : Une référence unique pour identifier la commande.
ipn_url : L'URL où PayTech enverra des notifications IPN (Instant Payment Notification) lors de l'évolution du paiement.
success_url : L'URL où l'utilisateur sera redirigé en cas de paiement réussi.
cancel_url : L'URL où l'utilisateur sera redirigé en cas d'annulation du paiement.
env: // C'est l'environnement dans lequel tu utilise paytech. Il a deux valeurs possibles: "test" ou "prod" selon votre besoin (Contactez l'équipe de PayTech pour activer votre compte en production.)

Note : Assurez-vous que votre serveur est configuré pour accepter des requêtes POST vers l'URL ipn_url pour la gestion des notifications de paiement.