Documentation

HomeBAMLCLICloudTutorialsExamples

BAML documentation

  • Overview
  • Get started
  • Book
    • 3. Common programming concepts
    • 8. Handle errors
    • 11. Interfaces
    • 12. Run work concurrently
  • Language reference
    • Functions
  • Standard packages
  • Language bridges
    • TypeScript

Products

  • BAML CLI
  • Cloud

Resources

  • Tutorials
    • Structured extraction
  • Examples
    • Classify support tickets
    • Images and vision models
HomeBAMLCLICloudTutorialsExamples
Start

Sections

  • Overview
  • Get started
  • Book
    • 3. Common programming concepts
    • 8. Handle errors
    • 11. Interfaces
    • 12. Run work concurrently
  • Language reference
    • Functions
  • Standard packages
  • Language bridges
    • TypeScript

Products

  • BAML CLI
  • Cloud

Resources

  • Tutorials
    • Structured extraction
  • Examples
    • Classify support tickets
    • Images and vision models
BAMLStandard packagesv0.21.0bamlws_connect

baml.ws._connect

function in the baml package.

Reference version

Signature

function baml.ws._connect(
url: string,
headers: map<string, string>,
timeout_nanos: bigint
) -> baml.ws.WebSocket throws baml.errors.Io | baml.errors.Timeout

Source:<builtin>/baml/ns_ws/ws.bamlbytes 2794–2975

Related definitions

  • baml.Bigint
  • baml.errors.Io
  • baml.errors.Timeout
  • baml.Map
  • baml.String
  • baml.ws.WebSocket

On this page

  • Signature
  • Related definitions

Build with BAML

Start with the language guide and a checked BAML function.

Continue into generated package and CLI references for the exact selected toolchain.

Get started
Developer documentation for BAML and Boundary products. Source available on GitHub. View release notes