The Form widget is available through our CDN as a single JavaScript file or through NPM as a React component package.

<script type="module">
import Form from 'https://cdn.jsdelivr.net/npm/@zappway/embeds@latest/dist/form/index.js';

Form.initStandard({
formId: 'YOUR_FORM_ID',
});

</script>

Attributes / Props

<script type="module">
import Form from 'https://cdn.jsdelivr.net/npm/@zappway/embeds@latest/dist/form/index.js';

Form.initStandard({
formId: 'YOUR_AGENT_ID',

onEnd: function (values) {
console.log('Form submitted with values:', values);
},
})


</script>
formId
string
required

ID of the AI Employee

onEnd
function

Callback function that is called when the form is submitted. The function receives the form values as an object.

const form = await Form.initBubble({
  agentId: 'YOUR_AGENT_ID',
  onEnd: function (values) {
    console.log('Form submitted with values:', values);
  },
})