Quickstart
Start in the dashboard, then add an API integration when you need one.
1. Create an account
Sign up at mindgraph.cloud/login. The free tier includes 500 credits per month with unlimited queries and API access.
2. Add a source
Open Knowledge → Sources, add a document or paste text, and let MindGraph index the source with citations and provenance. You can search it immediately or admit it to a Project for a narrower working context.
3. Get an API key
For programmatic access, go to Settings → API Keys and create a new key. Copy it — you won't be able to see it again.
4. Install an SDK
npm install mindgraph
5. Make your first call
import { MindGraph } from "mindgraph"
const graph = new MindGraph({
baseUrl: "https://api.mindgraph.cloud",
apiKey: "mg_your_key_here",
})
// Add a node
const node = await graph.addNode({
label: "User prefers dark mode",
node_type: "Preference",
})
console.log("Created:", node.uid)
// Search for it
const results = await graph.search("dark mode")
console.log("Found:", results.length, "results")
6. Complete example
A realistic workflow: create an entity, make a claim about it, build an argument with evidence, search for it, and traverse the reasoning chain.
import { MindGraph } from "mindgraph"
const graph = new MindGraph({
baseUrl: "https://api.mindgraph.cloud",
apiKey: "mg_your_key_here",
})
// 1. Create entities using first-class type methods (preferred)
const org = await graph.findOrCreateOrganization("Acme Corp", { description: "SaaS startup" })
console.log("Organization:", org.uid)
// findOrCreateEntity still works as a fallback for other types
const entity = await graph.findOrCreateEntity("TypeScript", { entity_type: "language" })
console.log("Entity:", entity.uid)
// 2. Build an argument with claim + evidence
const arg = await graph.argue({
claim: {
label: "TypeScript adoption",
props: { content: "TypeScript improves developer productivity" },
},
evidence: [
{ label: "Type safety", props: { description: "Static types catch bugs at compile time" } },
{ label: "IDE support", props: { description: "Rich autocomplete and refactoring tools" } },
],
warrant: {
label: "Type system principle",
props: { principle: "Static analysis reduces runtime errors" },
},
})
console.log("Claim:", arg.claim_uid)
// 3. Search for it
const results = await graph.search("TypeScript productivity")
console.log("Found:", results.length, "results")
// 4. Traverse the reasoning chain
const chain = await graph.reasoningChain(arg.claim_uid, 3)
console.log("Chain:", chain.map(s => s.label).join(" -> "))
Next steps
- Concepts — Learn about the six cognitive layers, node types, and edge types.
- Cognitive Endpoints — Full reference for all 18 cognitive endpoints with action enums and request/response schemas.
- Operational Ontology — Layer 7: workspace-specific domain objects (Client, Supplier, Patient) extracted from your documents.
- Projects & Living Briefs — Keep retrieval and synthesis grounded in an admitted source corpus.
- Governance & Access — Scope users and agents to the knowledge and tools they are allowed to use.
- API Reference — Full reference for the REST API.
- SDKs — Detailed guides for TypeScript and Python.