Create Inspections Within Your Website
The easiest way to integrate with Truepic Vision — embed a form on your website to create inspections with no API key, no backend changes, and no server-side code.
Website Forms is the easiest way to start creating inspections with Truepic Vision. Drop a pre-built web component into your website, and your customers or employees can submit inspection requests directly from the page. The form handles everything securely on its own.
When a form is submitted, an inspection is created and a link to start it is shown right on the page, with the option to send it by text or email. You review completed inspections in the Vision Dashboard. Whether the webpage is an internal system accessible only by your employees or a public portal for your customers, you can integrate it in a few minutes.
Two lines of HTML is all you need. Allow your domain, add the script tag, drop in the form element, and you're live.
Getting Started
Open the Vision Dashboard and click Settings > Website Forms. Create a Website Form (or open an existing one), and make sure your website's domain (like https://www.example.com) is listed in the form's Allowed Domains, since the form won't work on any other domain. Then copy the token of the Website Form, which you'll need to complete the integration on your website.
Import the Script
Add the following within the <head> of your page, although anywhere within the <body> also works if that's easier:
<script
type="module"
src="https://vision-form.truepic.com/truepic_vision_form.es.js"
crossorigin
></script>This JavaScript module defines the <truepic-vision-form> web component and includes all of the default styling. It's hosted by Truepic on our CDN for speed and convenience, and is evergreen with updates rolling out automatically, without any code redeployment on your end.
Add the Element
With the script imported, you can now add the <truepic-vision-form> element into your page's HTML exactly where you want it to appear:
<truepic-vision-form token="{{REPLACE_WITH_YOUR_TOKEN}}"></truepic-vision-form>Replace {{REPLACE_WITH_YOUR_TOKEN}} with the token that was generated for the Website Form you previously created.
If everything is set up and configured correctly, you should see the form appear on your page. That's it — you're integrated. No API keys to manage, no webhooks to configure, and every submission is secured automatically. Continue reading to learn more about the various ways to configure and customize the form.
Optional: Customize the Form
Attributes
The element can be configured through attributes placed on the opening <truepic-vision-form> tag.
| Name | Description | Required | Default |
|---|---|---|---|
inspection-type-label | The display name to use for the "Inspection Type" field that appears when multiple Inspection Types are configured for the Website Form. | No | Inspection Type |
region | The region your Vision account is in, either US or EU. | No | US |
token | The token generated for the Website Form created in the Vision Dashboard. | Yes |
Example
<truepic-vision-form
token="{{REPLACE_WITH_YOUR_TOKEN}}"
inspection-type-label="Type of Loan"
></truepic-vision-form>Styling
The size and position of the element — such as width and margin — can be controlled with CSS just like any other element. We've built it to be responsive, meaning it will expand or contract to whatever space it's given.
The element will also automatically inherit color and font-family properties set for the page.
All additional customization is done through CSS variables.
| Variable | Description | Default |
|---|---|---|
--tvf-color-primary | The primary color that's used for things like buttons, focused inputs, etc. | #1b1b1b |
--tvf-color-primary-mix | Variations of the primary color are created for states like hover, focus, etc. This is the color that's mixed with the primary color to create the variations. Use a lighter color (like white) for the variations to be lighter or a darker color (like black) for the variations to be darker. | #fff |
Example
truepic-vision-form {
--tvf-color-primary: #1a6dff;
--tvf-color-primary-mix: #000;
}Events
Custom events are emitted from the element to enable a deeper level of integration when necessary. These events can be listened for using the standard element addEventListener() interface.
| Name | Description | detail Property |
|---|---|---|
tvf-success | Dispatched when the user successfully submits the form to create an inspection. | The created inspection, including its id and link. |
Example
// Get a reference to the element:
const element = document.querySelector('truepic-vision-form')
// Use the event to update your page after Vision creates the inspection.
element.addEventListener('tvf-success', (event) => {
// Show a confirmation message or return the user to your application workflow.
// The created inspection's ID is available as `event.detail.id`.
})What to Read Next
- Vision Dashboard — Review inspections submitted through your form.
- Website Forms API reference — Manage Website Forms programmatically.
- Send Your First Inspection — Use the API instead when your backend needs to create inspections and receive webhooks.
Updated 2 days ago

