New:Microsoft Teams Notifications Are Now Available in Socket.Learn more
Get Started

@aibind/solidstart

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aibind/solidstart

AI SDK bindings for SolidStart — reactive hooks with defaults, server handlers, and agents

latest
Source
npmnpm
Version
0.12.0
Version published
Maintainers
1
Created
Source

@aibind/solidstart

AI SDK bindings for SolidStart. Reactive SolidJS hooks, server handlers, and agents — all wired up with sensible defaults.

Install

npm install @aibind/solidstart ai solid-js

Peer dependencies: solid-js ^1.8, ai ^6.0.

Quick Start

1. Add the server handler

// src/routes/api/__aibind__/[...path].ts
import { createStreamHandler } from "@aibind/solidstart/server";
import { anthropic } from "@ai-sdk/anthropic";

const handler = createStreamHandler({
  model: anthropic("claude-sonnet-4-20250514"),
});

export async function POST({ request }: { request: Request }) {
  return handler(request);
}

2. Stream in a component

import { useStream } from "@aibind/solidstart";

function Chat() {
  const { text, loading, send } = useStream({
    system: "You are a helpful assistant.",
  });

  let prompt = "";

  return (
    <form
      onSubmit={(e) => {
        e.preventDefault();
        send(prompt);
      }}
    >
      <input value={prompt} onInput={(e) => (prompt = e.target.value)} />
      <button disabled={loading()}>Send</button>
      <Show when={text()}>
        <p>{text()}</p>
      </Show>
    </form>
  );
}

Entry Points

Import PathWhat You Get
@aibind/solidstartuseStream, useStructuredStream, defineModels
@aibind/solidstart/servercreateStreamHandler, ServerAgent
@aibind/solidstart/agentuseAgent
@aibind/solidstart/historyReactiveChatHistory, ReactiveMessageTree
@aibind/solidstart/markdownuseStreamMarkdown
@aibind/solidstart/projectProject

Documentation

Full documentation, API reference, and guides: aibind.dev

License

MIT

Keywords

solid

FAQs

Package last updated on 10 Mar 2026

Related posts