Verida AI Docs
  • Welcome
  • Getting Started
    • How it works
    • Developer Console
    • Get an API key
    • Authentication
    • Scopes
    • API Requests
    • Connectors
      • Build a Connector
    • Example Apps
  • Integrations
    • PersonalAgentKit
    • LangGraph
    • NEAR Protocol
    • Nillion Network
  • Data APIs
    • Overview
    • Data Types
    • API Endpoints
      • Queries
      • Search
      • AI Prompts
      • Actions
      • Other Endpoints
    • API Performance
    • Data examples
    • API Reference
  • Resources
    • Tutorials
      • Accessing User Data (Telegram)
    • Learn
      • Anatomy of an AI Agent
      • Dynamic Loading of Data for Realtime AI
      • Data Privacy Issues
      • Web3 & DePIN solves AI's privacy problems
      • Privacy Preserving AI Tech Stack
      • Confidential Compute Litepaper
    • AI Use Cases
    • Verida Vault
    • Privacy & Security
    • Pricing
    • Grants
    • Support
Powered by GitBook
On this page
Export as PDF
  1. Getting Started

API Requests

Learn how to make an API request

Make an API Request

You will need an auth_token from a user (see Authentication) to make requests to Verida endpoints.

API requests must include the auth_tokenin the Authorization header as a Bearer token.

const API_ENDPOINT = "https://api.verida.ai/api/rest/v1/auth";
// Obtain token from localstorage (or your own database)
const authToken = localStorage.getItem("veridaAuthToken") || "";

// Example: search/universal endpoint
$.get({
    url: `${API_ENDPOINT}/search/universal?keywords=meeting+agenda`,
    headers: {
        "Authorization": `Bearer ${authToken}`,
        "Content-Type": "application/json"
    },
    success: (response) => {
        console.log(response);
        // Handle the response data
    }
});

Important: Ensure you store and handle the auth_token securely. Unauthorized access to this token could compromise your application and user data.

See the Data APIs or API Reference to learn more about all the available endpoints

PreviousScopesNextConnectors

Last updated 4 months ago