TanStack Start

07 Deploy

Check TanStack Start runtime, environment, and streaming behavior before deployment.

Runtime Checklist

AreaCheck
Server placementProvider clients, agents, and tools stay in server modules
SecretsProvider keys are available only to server code
StreamingHost and proxy support long-lived response bodies
TimeoutsRoute timeouts exceed expected model and tool duration
StorageConversations, memory, retrieval indexes, and traces use durable stores

Prefer Server Routes For HTTP Surfaces

Server functions are useful inside the app. Server routes are the clearest contract for external clients and streaming endpoints because they return Response directly.

Add Trace Metadata

const response = await supportAgent
  .prompt(message)
  .withTrace({
    name: "support-route",
    userId,
    sessionId: conversationId,
    tags: ["tanstack-start"],
  })
  .send();

Attach observers for logs, metrics, Langfuse, or OpenTelemetry.

Deployment Smoke Test

curl -X POST "$APP_URL/api/support" \
  -H "Content-Type: application/json" \
  -d '{"message":"Say hello"}'

Next

Use Troubleshooting for common failures. Related guides: Observers, Langfuse, and OpenTelemetry.