# Get API Key

### Get started

To start using the DappLooker SDK, follow these steps:

**1. Install the SDK:**

```
npm install dapplooker-sdk
```

**2. Generate an API Key:**

* Begin by sign in to [DappLooker](https://dapplooker.com/user/signup)  either through Metamask or email.
* Proceed to the Products section and locate the [API SDK](https://dapplooker.com/user/api). Click on it to proceed.

<img src="https://411387007-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmieVdsFLVYWfiCpr2WSr%2Fuploads%2FYH6pptmHoIapB2vsJIL9%2FScreenshot%202024-03-23%20014145.png?alt=media&#x26;token=36e3e1c4-cbb7-4001-b40d-b5b4156283c7" alt="" data-size="original">

* Within the API SDK interface, select the option labeled "+API Key"&#x20;

<img src="https://411387007-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmieVdsFLVYWfiCpr2WSr%2Fuploads%2FRKgi9tdC4xJWaBzZGYLZ%2FScreenshot%202024-03-23%20013709.png?alt=media&#x26;token=df41194d-e147-44c9-8cd3-e4a6bc872ff9" alt="" data-size="original">

and designate a name for your API key. Subsequently, click on "Generate Key" to generate the key.&#x20;

<img src="https://411387007-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmieVdsFLVYWfiCpr2WSr%2Fuploads%2F4B7t25BeA4wfGiiSdQr9%2FScreenshot%202024-03-23%20014017.png?alt=media&#x26;token=bc4cd0cc-6b25-4707-8910-9cb2d73bef49" alt="" data-size="original">

3. **Import the SDK**

Once you have installed the SDK, import it into your project. With the imported SDK, create an instance of the DappLookerChartsAPI and make API calls using the API key

### Example

Here's an example of how you can use the DappLooker SDK using API key and Chart UUID

```javascript
const DappLookerChartsAPI = require("dapplooker-sdk");

async function getChartData() => {
  let chartUUID = "dc9b69d8-7ca1-45d4-8ad0-a17f915f3f0"; // Replace it with chart UUID you are working with
  let apiKey = "qzusb5p3q246ip246ab6g0p8ppzb7u"; // Replace it with your API key
  let outputFormat = 'json' // This is a optional argument, valid value is `json`.
  let filterParameter = {}; // Add Parameter if required

  let response = await DappLookerChartsAPI.getChartData(chartUUID, apiKey, outputFormat);
  console.log("API Response Data: ", JSON.stringify(response));
};

getChartData();
```
