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

@edgelinkapp/sdk-node

v0.1.1

Published

Edgelink Node SDK for server-side conversion tracking. Sale and other secret-only events.

Readme

@edgelinkapp/sdk-node

Edgelink 전환 추적용 서버 SDK. 결제 완료처럼 위변조 우려가 있는 이벤트를 secret 키로 안전하게 전송합니다.

설치

npm install @edgelinkapp/sdk-node

ESM(import)과 CJS(require)를 모두 지원하며 TypeScript 타입이 포함되어 있습니다. native fetch만 사용하므로 Node 18+ / Cloudflare Workers / Vercel Edge / Bun / Deno에서 동일하게 동작합니다.

사용법

import { Edgelink } from '@edgelinkapp/sdk-node'

const edgelink = new Edgelink({
  secretKey: process.env.EDGELINK_SECRET_KEY!,
})

// 결제 완료 webhook
app.post('/api/checkout/success', async (req, res) => {
  await edgelink.conversions.create({
    clickId: req.cookies._el_cid,
    eventType: 'sale',
    eventName: 'purchase',
    externalEventId: order.id,
    valueMinor: order.totalAmountKrw, // KRW=원 정수. Float 금지
    currency: 'KRW',
    customerEmailHash: Edgelink.hashEmail(user.email),
  })
  res.json({ ok: true })
})

핵심 정책

  • secretKey는 명시적으로 주입합니다 (process.env 자동 픽업 없음 — 실수로 미설정 시 silent 동작 방지).
  • clickId 또는 externalUserId하나 이상 필수 (TypeScript 타입 시그니처가 강제).
  • valueMinor는 최소 통화 단위 정수 (KRW=원, USD=cents). Float 금지.
  • 5xx/429 응답은 지수 백오프로 자동 재시도 (기본 3회). 4xx는 즉시 throw.

에러 클래스

| 에러 | 상황 | | ------------------------- | ---------------------------------------------- | | EdgelinkAuthError | 401/403 — 키 누락/만료/회수/Origin 불일치 | | EdgelinkValidationError | 400/404/410 — 페이로드 위반, click 미존재/만료 | | EdgelinkRateLimitError | 429 — retryAfter 초 정보 포함 | | EdgelinkServerError | 5xx — 서버 일시 장애 |

Edge runtime 호환

native fetch만 사용합니다. Cloudflare Workers / Vercel Edge / Bun / Deno에서 동일하게 동작합니다.