Skip to main content

dyna AI Gateway logo

Getting started

dyna-ai-gateway puts a language model inside a business application. The application calls ask() for an answer or run() for an agent with tools; the gateway assembles the prompt, keeps the conversation, applies the tool policies, pauses for a human when a policy says so, asks your code before every model call, and traces each one.

You don't need to know everything, only what you need. A first answer takes one configuration object and one call. Tools, approvals, memory, the knowledge base and the class replacements are there when a use case asks for them, and not before.

ChapterWhat you get
What is the AI gatewaywhere the library sits between your application and the providers
Installationthe package, the configuration, a model and a profile
Example: aska structured answer on the data of the screen, streamed
Example: runan agent that calls your function to answer
Example: a human in the loopa tool call that waits for an approver, then resumes
Vercel chat clienta useChat screen on the gateway, through dyna-ai-gateway/vercel-ui
FAQthe questions of the first weeks, answered with code

Every exported symbol carries its JSDoc, so the editor shows the contract of each option; the API reference is the same JSDoc as pages.