# Authentication

All requests to the NETTS API require authentication using an API key. This page explains how to obtain and use your API key.

# Obtaining an API Key

To get your API key:

  1. Contact our support team at [email protected]
  2. Provide your account details and the IP addresses that will be making API requests
  3. Once your request is approved, you will receive your API key

# Using Your API Key

To authenticate your requests, you need to include your API key in the HTTP headers of each request:

X-API-KEY: your_api_key

# Example Request with Authentication

curl -X GET "https://netts.io/apiv2/prices" \
  -H "Content-Type: application/json" \
  -H "X-API-KEY: your_api_key"

# IP Whitelisting

For security reasons, NETTS API uses IP whitelisting. This means that requests to the API will only be accepted from pre-approved IP addresses that are associated with your API key.

Important

Regular API users must send requests from whitelisted IP addresses. When you apply for an API key, make sure to include all IP addresses that will be making API requests.

# API Key Types

NETTS offers two types of API keys:

  1. Regular API Keys: These require IP whitelisting and are typically used for server-to-server integrations.
  2. TG API Keys: These are used for Telegram bot integrations and do not require IP whitelisting.

# Security Best Practices

To keep your API access secure:

  • Keep your API key confidential
  • Never include your API key in client-side code
  • Rotate your API keys periodically
  • Only whitelist the IP addresses you need
  • Monitor API usage for unexpected patterns