Installation

Install the Metigan SDK in your project using npm, yarn, or pnpm. The SDK is lightweight, type-safe, and works seamlessly with TypeScript and JavaScript.

Package Managers

Choose your preferred package manager and install the Metigan SDK:

TerminalTerminal
1
2
3
4
5
6
7
8
# Using npm
npm install metigan

# Using yarn
yarn add metigan

# Using pnpm
pnpm add metigan
Current Version

The current stable version is 2.2.1. Make sure you're using the latest version for the best experience and latest features.

Requirements

Before installing, make sure you have the following prerequisites:

1

Node.js

Version 14.0.0 or higher is required. You can check your version by running node --version

2

TypeScript (Optional)

TypeScript 4.0.0 or higher is recommended but not required. The SDK works great with plain JavaScript too!

3

API Key

A valid Metigan API key is required. Get one from your dashboard.

Verifying Installation

After installation, verify that the package is installed correctly:

verify-installation.tsTypeScript
1
2
3
4
5
6
7
8
9
10
11
import Metigan from 'metigan';

// Check if Metigan is available
console.log('Metigan version:', Metigan.VERSION || '2.2.1');

// Initialize (this will throw if there's an issue)
const metigan = new Metigan({
  apiKey: 'your_api_key'
});

console.log('✅ Metigan SDK installed successfully!');
TypeScript Support

The Metigan SDK is written in TypeScript and includes complete type definitions out of the box. No additional @types package is needed. You'll get full autocomplete and type checking in your IDE.