Skip to Content
NotPixel SDK v1.0.1 — Now with caching, hooks, and browser tracking!
Getting StartedInstallation

Install NotPixel

Before you start

You’ll need an API key from a model provider to complete setup. We suggest starting with OpenAI  , but if you need a provider that doesn’t require a credit card, Google’s Gemini  is also an option.

  • Install Node.js 20 or later.
  • Ensure you have package manager (npm, pnpm, yarn, or bun) installed on your system.
  • Created or edited your .env file with OPENAI_API_KEY

Install with packages

You can install NotPixel using your preferred package manager:

terminal
npm i notpixel

Get your publisher key

Retrieve your unique publisher key from the NotPixel dashboard . This key is essential for monetizing your platform.

Add NotPixel to your code

Import and initialize NotPixel in your application. Replace YOUR_PUBLISHER_KEY with the key obtained in the previous step.

index.ts
import Ads from "notpixel"; const ads = new Ads({ publisherId: "pub_k8h2j9d4f7g1s3a6", model: "openai/gpt-5.2", input: "Analyze the following content and generate relevant, context-aware recommendations.", }); const response = await ads.offer(); console.log(response.text);
You don’t need to pass the model API key as a parameter in our SDK — it automatically detects it in your .env or .env.local file.

Next Steps