Build your first add-on
Ask your AI for the add-on in plain words. The more it knows about who uses it and where, the better the first draft:
- What it does. "Shows the job's billing lines with a running total."
- Where it lives. A button on the job, an Add-ons page (under Account, Addons), or automatic.
- Who uses it. The office on the web, techs in the app, or both.
If you leave out where it should live, your AI asks first. That is deliberate: it is the decision that shapes everything else.
Example prompts
Build me a ServiceM8 add-on called Job Pulse: a button on the job that shows the job's status, client, address and description in one popup. Web and app.
When a job's status changes, add a line to the job diary saying what it changed to. No buttons, just automatic.
Build a Quick Quote button on the job: list the job's billing lines with a running total, and an "Add line" button that adds 1 hour of labour at $120.
Hide any job file whose name starts with PRIVATE from the job diary. Add a Curtain button on the job where business owners can see and restore hidden files, and an Add-ons menu page where they set the rules.What happens next
- Your AI reads FloConnector's built-in guide to ServiceM8 add-ons, and the parts of ServiceM8's API the add-on needs.
- It writes the add-on and saves it as a draft. Nothing reaches ServiceM8 yet.
- FloConnector checks the draft and shows a review: where the add-on will appear and what it will be able to do.
- You try it in the preview and ask for changes. Each change is saved as a new draft.
- When it does what you want, you tell your AI to deploy it.
The review
Every draft comes back with a review in plain words. For Job Pulse it reads:
Where it appears:
- Job button "Job pulse" (web)
- Job button "Job pulse" (app, under More)
- Runs automatically when a job's status changes
What it will be able to do in ServiceM8, on its own, every time it runs:
- read jobs
- read clients
- add job diary entriesRead the second list carefully. Whatever an add-on is allowed to do, it can do every time it runs, for as long as it is deployed, without anyone in the chat.
What FloConnector checks
A draft is refused, with the reason, if:
- it isn't a valid ServiceM8 add-on, or a button or menu entry isn't wired to anything;
- it asks for a permission that isn't on the list below;
- the code doesn't compile as a single file, or loads a package (an add-on can only use what is built into Node, which includes making web requests);
- an icon isn't a public
https://image.
It is saved with a warning if the code uses data its permissions don't cover (those calls would fail once it is live), or if it would write something sensitive to its logs. Your AI sees every reason and fixes the draft.
Permissions
An add-on asks for its permissions up front, and gets exactly those. FloConnector only allows the ones below, and your AI should only ask for what the add-on uses.
| Area | Permissions |
|---|---|
| Jobs | Read jobs · Change jobs · Create jobs |
| Clients | Read clients |
| Job contacts | Read job contacts · Change job contacts |
| Billing | Read job billing lines · Change job billing lines · Read job payments |
| Schedule and staff | Read the schedule · Read staff · Read staff security roles |
| History | Read job email history · Read job SMS history |
| Notes and diary | Read job notes · Add job notes · Add job diary entries |
| Files | Read files and photos · Archive, change or add any file or photo |
| Notifications | Send staff push notifications |
| The add-on's own memory | Read its own saved settings and notes · Save its own settings and notes |
Two are worth a second look when you see them in a review:
- Archive, change or add any file or photo covers every file in the account, not only the ones on the job the add-on was opened from.
- Change jobs lets the add-on edit any field on any job.
Some ServiceM8 permissions aren't available to add-ons built here at all, including sending emails and SMS, staff locations and managing staff.
Icons
Every button and menu entry shows an icon. Your AI uses, in this order:
- Your logo, if you give it a link to one. It must be a public
https://image, ideally square and at least 256 pixels. - The icon from your website, such as
yourbusiness.com/apple-touch-icon.png, once you have confirmed it. - FloConnector's icon, if you have neither. The review says when it used it.
ServiceM8 can't use an image stored inside ServiceM8 itself, because it has no permanent public link for uploaded files, so the icon has to live on a website. Changing an icon later is a new deploy.
Names
Every add-on built here has a short name starting flc-, such as flc-job-pulse. It
identifies the add-on for good, so your AI keeps it when it changes the add-on. The name
your team sees on the button is separate, and can change whenever you like.
