interlocute.ai beta

Inform API Reference

Feed knowledge to a node — text, documents, and images. Content is stored as a memory record, optionally comprehended by AI, and made available to all future conversations.

Overview

The POST /inform endpoint lets you push knowledge into a node. Think of it as teaching the node something new — product specs, policy documents, images, spreadsheets — so it can reference that knowledge in future conversations.

Every inform request is asynchronous: the server validates your input, stores any attached files, and returns 202 Accepted immediately with an invocation ID. Background processing extracts text from files, optionally runs AI comprehension, and stores the result as a memory record on the node. The node's recall system automatically includes relevant memories in future conversations.

Poll progress via GET /chit/{invocationId} using the returned pollUrl.

Endpoints

All routes use POST. JSON routes accept application/json; upload routes accept multipart/form-data. See Routes for alternative addressing patterns.

POST /inform

Node-level inform (JSON) — content becomes available for recall in all threads.

POST /inform/{threadId}

Thread-scoped inform (JSON) — content is only recalled within the specified thread.

POST /inform/upload

Node-level inform (file upload) — same as /inform but accepts multipart/form-data. Use this from Postman or cURL with local files.

POST /inform/{threadId}/upload

Thread-scoped inform (file upload).

Authentication

Identical to Chat: pass a tenant or node-scoped API key as Authorization: Bearer YOUR_API_KEY, or a JWT token. Anonymous access is supported if the node operator has enabled it.

Request Body

Content-Type: application/json. At least one of content or attachments must be provided.

Field Type Required Description
content string conditional Text content to internalize. Required when no attachments are provided. Max 100,000 characters.
attachments array conditional File attachments via URL or base64 data URL. Required when no content text is provided. Max 10 files, 20 MB each.
title string optional Human-readable title for the memory. Auto-generated from content if omitted.
mode string optional "raw" (default) or "comprehend". See Processing Modes.
instructions string optional Caller-supplied instructions that guide comprehension. Ignored when mode is "raw".
status string optional "published" (default) or "draft". Published memories are available for recall in all threads; drafts are hidden until promoted.
tags string[] optional Tags for categorization and filtering.

Attachments

File uploads are supported three ways. The JSON routes (/inform) accept url and dataUrl attachments. The upload routes (/inform/upload) accept multipart/form-data with direct file fields.

form-data easiest for Postman — use /inform/upload

Send the request as multipart/form-data to the /inform/upload route and attach files directly — just like any standard file upload. Metadata fields (content, title, mode, etc.) go as text form fields alongside the files. No JSON, no base64, no file hosting.

curl -X POST https://my-node.interlocute.ai/inform/upload \
  -H "Authorization: Bearer $API_KEY" \
  -F "title=Q1 Sales Report" \
  -F "mode=comprehend" \
  -F "instructions=Extract revenue figures and regional breakdowns." \
  -F "file=@report.pdf;type=application/pdf"

In Postman: set the URL to /inform/upload, Body → form-data → add rows for title, mode, etc. as Text, then add a row with type File and pick your file. That's it.

url JSON — server-to-server

Pass a public URL in the JSON body — the server fetches the file for you. Works with pre-signed S3/GCS URLs, Azure Blob SAS tokens, or any public link.

{
  "title": "Q1 Sales Report",
  "attachments": [{
    "name": "report.pdf",
    "contentType": "application/pdf",
    "url": "https://example.com/files/report.pdf"
  }]
}
dataUrl JSON — browser / programmatic

Inline the file as a base64 data URL. This is what browser JavaScript produces from FileReader.

{
  "title": "Q1 Sales Report",
  "attachments": [{
    "name": "report.pdf",
    "contentType": "application/pdf",
    "dataUrl": "data:application/pdf;base64,JVBERi0xLjQ...",
    "sizeBytes": 524288
  }]
}

Form-data fields (/inform/upload)

When using /inform/upload with multipart/form-data, all metadata is sent as text form fields (not JSON). Files are sent as standard file fields.

Field Type Description
content text Text content. Optional when files are provided.
title text Title for the memory.
mode text raw or comprehend.
instructions text Comprehension guidance (ignored for raw).
status text published or draft.
tags text Comma-separated tags (e.g. product,specs,v2).
(files) file One or more file fields. Any field name works. Max 10 files, 20 MB each.

JSON attachment fields

When using application/json, each entry in the attachments array must provide exactly one of url or dataUrl.

Field Type Description
name string Original filename (e.g. "report.pdf"). Required.
contentType string MIME type. Required for dataUrl. Optional for url (inferred from response headers).
url string Public HTTP(S) URL. Mutually exclusive with dataUrl.
dataUrl string Base64 data URL. Mutually exclusive with url.
sizeBytes number File size in bytes. Required for dataUrl. Optional for url (server determines). Max 20 MB.
Which mode should I use?
  • Postman / cURL / manual testing/inform/upload with form-data — just pick your file, no prep needed
  • Server-to-server/inform with url attachment — pass a link, the server fetches it
  • Browser JavaScript/inform with dataUrl attachment — use FileReader output directly

Supported file types

application/pdf

DOCX / DOC

XLSX / XLS / CSV

PPTX / PPT

PNG / JPEG / GIF / WEBP

text/plain / text/csv

How extraction works: Files are stored to blob storage immediately. The background task then extracts text using Azure Document Intelligence (for PDFs and Office files) or Google Gemini vision (for images). Plain text and CSV files are read directly. The extracted text is appended to any provided content and then processed through the selected mode (raw or comprehend).

Processing Modes

raw default

Content (text + extracted attachment text) is stored verbatim as the memory record. No LLM call, zero cost. Use this when you trust the source and want exact preservation.

comprehend

An AI side-prompt distills the content into a structured knowledge document with Summary, Key Facts, and Details sections. The node's constitution (identity and mission) is used as context to prioritize and frame the knowledge.

The instructions field lets you steer comprehension:

{
  "content": "...",
  "mode": "comprehend",
  "instructions": "Focus on pricing tiers and SLA guarantees. Ignore marketing language."
}
When both text content and attachments are provided, extracted text from attachments is appended after the text content. In "comprehend" mode, the combined text is distilled together.

How Memory Works

When you call /inform, the node stores the content as a memory record. Here's what happens behind the scenes:

1

Store

Your text and files are stored durably. Files are uploaded to blob storage and text is extracted (OCR for documents, vision analysis for images).

2

Comprehend (optional)

In "comprehend" mode, an AI side-prompt distills the raw content into structured knowledge — a summary, key facts, and organized details — framed by the node's identity.

3

Recall

Published memories enter the node's recall system. In future conversations, the node automatically selects relevant memories and includes them in the prompt context — no additional API calls or configuration needed.

Visibility: A "published" memory is available for recall across all threads on the node. A "draft" memory is stored but hidden from recall until you promote it. Thread-scoped informs (via /inform/{threadId}) are only recalled within that specific thread.

Response

All inform requests return 202 Accepted with a Retry-After: 2 header.

{
  "disposition": "deferred",
  "invocationId": "01KKJBKW08AB4A423HPZ37R1Z2",
  "nodeId": "4dbbcf35-3501-4618-ab95-847fcb6e77df",
  "memoryId": "95374e59-ba3d-4f86-adcf-3d69c00d459c",
  "pollUrl": "nodes/4dbbcf35-.../chit/01KKJBKW08AB4A423HPZ37R1Z2",
  "status": "queued"
}
Field Description
disposition Always "deferred".
invocationId Unique ID. Use this to poll status via /chit.
memoryId Identifier for the stored memory. Use this to reference or manage the informed knowledge later.
pollUrl Relative URL to poll. Append to your base URL.
status "queued" at creation. Progresses to "running""completed" or "failed".

Examples

1. Plain text (JSON, raw mode)

curl -X POST https://my-node.interlocute.ai/inform \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "Our return policy allows returns within 30 days of purchase. Items must be unopened and in original packaging.",
    "title": "Return Policy"
  }'

2. File upload via form-data (easiest for Postman)

Just pick your file — no hosting, no base64, no JSON. Use the /inform/upload route:

curl -X POST https://my-node.interlocute.ai/inform/upload \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -F "title=Q1 Sales Report" \
  -F "mode=comprehend" \
  -F "instructions=Extract revenue figures and regional breakdowns." \
  -F "file=@report.pdf;type=application/pdf"
Postman: Set the URL to /inform/upload. Body → form-data. Add text rows for title, mode, instructions etc. Then add a row, change its type dropdown from Text to File, and pick your file. Hit Send.

3. Multiple files via form-data

curl -X POST https://my-node.interlocute.ai/inform/upload \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -F "title=Onboarding Pack" \
  -F "mode=comprehend" \
  -F "tags=onboarding,hr" \
  -F "file1=@handbook.pdf;type=application/pdf" \
  -F "file2=@org-chart.png;type=image/png"

4. File URL (JSON — server-to-server)

curl -X POST https://my-node.interlocute.ai/inform \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Q1 Sales Report",
    "mode": "comprehend",
    "instructions": "Extract revenue figures and regional breakdowns.",
    "attachments": [{
      "name": "report.pdf",
      "contentType": "application/pdf",
      "url": "https://example.com/files/q1-report.pdf"
    }]
  }'

5. Image URL (JSON)

{
  "title": "Store Floor Plan",
  "attachments": [{
    "name": "floorplan.png",
    "contentType": "image/png",
    "url": "https://mybucket.s3.amazonaws.com/floorplan.png?X-Amz-Signature=..."
  }]
}

6. Comprehend with instructions + tags (JSON)

curl -X POST https://my-node.interlocute.ai/inform \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "... long product specification document ...",
    "title": "Product Specs v2.4",
    "mode": "comprehend",
    "instructions": "Focus on dimensions, weight limits, and safety certifications. Ignore marketing copy.",
    "tags": ["product", "specs", "v2.4"]
  }'

7. Mixed: text + file URL (JSON)

{
  "content": "Context: these are our updated pricing tiers effective March 2026.",
  "title": "Pricing Update March 2026",
  "mode": "comprehend",
  "instructions": "Merge the text context with the spreadsheet data into a single pricing reference.",
  "attachments": [{
    "name": "pricing.xlsx",
    "contentType": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
    "url": "https://sharepoint.example.com/sites/ops/pricing-march-2026.xlsx"
  }]
}

8. JavaScript — URL mode

const res = await fetch(
  `https://my-node.interlocute.ai/inform`,
  {
    method: "POST",
    headers: {
      "Authorization": `Bearer ${apiKey}`,
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      title: "Architecture Diagram",
      attachments: [{
        name: "arch.png",
        contentType: "image/png",
        url: "https://cdn.example.com/arch-diagram.png",
      }],
    }),
  }
);
const { invocationId, pollUrl } = await res.json();

9. JavaScript — base64 data URL (browser uploads)

async function informWithFile(nodeId, apiKey, file) {
  const buffer = await file.arrayBuffer();
  const base64 = btoa(String.fromCharCode(...new Uint8Array(buffer)));
  const dataUrl = `data:${file.type};base64,${base64}`;

  const res = await fetch(
    `https://my-node.interlocute.ai/inform`,
    {
      method: "POST",
      headers: {
        "Authorization": `Bearer ${apiKey}`,
        "Content-Type": "application/json",
      },
      body: JSON.stringify({
        title: file.name,
        mode: "comprehend",
        attachments: [{
          name: file.name,
          contentType: file.type,
          dataUrl,
          sizeBytes: file.size,
        }],
      }),
    }
  );

  const { invocationId, pollUrl } = await res.json();
  return invocationId;
}

10. C# / .NET — URL mode

var payload = new
{
    title = "Q1 Report",
    mode = "comprehend",
    instructions = "Summarize revenue by region.",
    attachments = new[]
    {
        new
        {
            name = "report.pdf",
            contentType = "application/pdf",
            url = "https://storage.example.com/reports/q1-2026.pdf",
        }
    }
};

var response = await httpClient.PostAsJsonAsync(
    "https://my-node.interlocute.ai/inform", payload);
var result = await response.Content
    .ReadFromJsonAsync<JsonElement>();

var invocationId = result.GetProperty("invocationId").GetString();
Console.WriteLine($"Poll: https://my-node.interlocute.ai/chit/{invocationId}");

Polling for Status

Use the pollUrl from the 202 response to check progress. See Chit API Reference for the full polling contract.

curl https://my-node.interlocute.ai/chit/01KKJBKW08AB4A423HPZ37R1Z2 \
  -H "Authorization: Bearer YOUR_API_KEY"

The receipt progresses through queuedrunningcompleted (or failed). When completed, the outputs array contains:

  • artifact — pointer to the informed artifact thread
  • assistantMessage — the full comprehended (or raw) content as text
  • extractionRecord — one per attachment, with extraction metadata (file name, size, char count, profile, duration)

Completed receipt example

{
  "invocationId": "01KKJBKW08AB4A423HPZ37R1Z2",
  "status": "completed",
  "durationMs": 8500,
  "outputs": [
    {
      "kind": "artifact",
      "outputId": "artifact-001",
      "threadId": "f8a6dcda-...",
      "metadata": { "artifactType": "informed" }
    },
    {
      "kind": "assistantMessage",
      "outputId": "msg-002",
      "threadId": "f8a6dcda-...",
      "content": "## Summary\nThe Q1 report shows revenue of $4.2M..."
    },
    {
      "kind": "extractionRecord",
      "outputId": "extraction-0",
      "metadata": {
        "fileName": "report.pdf",
        "contentType": "application/pdf",
        "extractionKind": "Document",
        "profile": "TextAndLanguage",
        "extractedCharCount": "20678",
        "sizeBytes": "6286344",
        "durationMs": "3100"
      }
    },
    {
      "kind": "extractionRecord",
      "outputId": "extraction-1",
      "metadata": {
        "fileName": "org-chart.png",
        "contentType": "image/png",
        "extractionKind": "Image",
        "profile": "FullIntelligence",
        "extractedCharCount": "240",
        "sizeBytes": "524288",
        "durationMs": "1200"
      }
    }
  ]
}

Extraction record metadata fields

Field Description
fileName Original filename of the attachment.
contentType MIME type of the source file.
extractionKind Pipeline used: PlainText, Document, Image, or Unsupported.
profile Noma analysis profile used (e.g. TextAndLanguage, FullIntelligence). Absent for plain text.
extractedCharCount Number of characters extracted from this attachment.
sizeBytes Source file size in bytes.
durationMs Extraction wall-clock time in milliseconds.
The extractionRecord outputs give you a lightweight summary of what happened per attachment. For full structured extraction intelligence (layout, form fields, image analysis results), fetch the artifact thread and inspect artifactManifest.extractionIntelligence.

Errors

Status Condition Meaning
400 No content or attachments At least one of content or attachments is required.
400 Too many attachments Maximum 10 attachments per request.
401 Missing / invalid credentials No valid API key or JWT provided.
404 Node or thread not found The nodeId doesn't exist, or inform capability is not enabled on the node.
413 Content or attachment too large Content exceeds 100K chars, or an attachment exceeds 20 MB.

Limits

Limit Value
Text content length 100,000 characters
Attachments per request 10
Max size per attachment 20 MB
Comprehension output tokens ~4,096 tokens (model-dependent)

Next steps