Skip to Content
SDKsTypeScriptQuickstart

TypeScript Quickstart

Who This Is For

Application engineers integrating governed session + execution calls in under 5 minutes.

Prerequisites

  • DriftGate session token
  • Staging workspace access
  • Agent identifier (example: refund-agent)

Two-Line Hello World

TypeScript

const session = await dg.session.start({ agent: "refund-agent" })
await session.execute({ input: { orderId: "123" } })

Production Considerations

  • Keep staging as default during integration
  • Capture meta.requestId on every call
  • Add retry logic only for retryable errors

Failure Handling

See Error Codes and Envelope Reference.

Last updated on