Skip to main content

Prerequisites

Before you begin, make sure you have:
  • Node.js 18.0.0 or higher installed
  • An API key (get one by creating an account and generating an API key)

Step 1: Install the SDK

Install the package using your preferred package manager:
npm install @plank-proofly/api

Step 2: Initialize the Client

Import the SDK and initialize it with your API key.
import { PlankProofly } from '@plank-proofly/api';

const client = new PlankProofly({ 
  apiKey: 'sk_your_api_key_here' 
});
You can also provide configuration options like timeout and retries:
const client = new PlankProofly({ 
  apiKey: 'sk_your_api_key_here',
  timeout: 30000,
  retries: 3
});

Step 3: Make Your First Request

Let’s start with a simple profile search. The SDK handles job creation and polling automatically, so you can just await the result.
try {
  const result = await client.profiles.search({
    name: 'John Doe',
    location: 'New York, NY',
    birthYear: 1990
  });

  console.log('Results:', result);
} catch (error) {
  console.error('Error:', error);
}

Type Definitions

The SDK includes full TypeScript definitions. You can import types directly:
import { PlankProofly, ProfileSearchResult } from '@plank-proofly/api';

const searchParams = {
  name: 'John Doe',
  location: 'New York, NY'
};

const result: ProfileSearchResult = await client.profiles.search(searchParams);

Next Steps