Neocortex
IntegrationsWeb API

Quick Start

Learn how to interact with the Neocortex Web API

The Neocortex Web API lets you interact directly with Smart NPCs via HTTP endpoints. This guide will help you authenticate and make your first request using standard web tools like curl or Postman.

Requirements

Sending Your First Message

The /chat endpoint allows you to send a message to a Smart NPC and receive a response. Let's walk through the steps to make your first request.

Run Terminal

Open your terminal or command prompt. You can also use tools like Postman or Insomnia for testing API requests. Run the following command to ensure you have curl installed: curl --version

Set Up API Key

Make sure you have your API key ready. You can find it in your Neocortex dashboard under API Keys.

Create a Character

If you haven't created a character yet, go to your Neocortex Dashboard and create a new project.

Send a Message

Use the following curl command or JavaScript code to send a message to your character and receive a response. Replace YOUR_API_KEY and YOUR_PROJECT_ID with your actual API key and character ID you created earlier.

Curl Example
curl ^
-X POST https://neocortex.link/api/v2/chat ^
-H "x-api-key: YOUR_API_KEY" ^
-H "Content-Type: application/json" ^
-d "{\"characterId\": \"YOUR_PROJECT_ID\", \"message\": \"Hello there!\"}"

On this page