import { workflow, collectFirstName, saveToContact } from '@candoa/workflows'

export default workflow('welcome-new-user', {
  description: "Collects the user's first name when they start a chat",
})
  .on('chat.started')
  .use(
    collectFirstName({ prompt: "Hi! What's your first name?" }),
    saveToContact({ field: 'firstName', value: '{{firstName}}' }),
  )
