HubSpot Configuration as Code package looking for early users and maintaners

HubSpot configuration as code: open-source CLI looking for early users and maintainers

Hi all,

We’ve open-sourced Kalup, a CLI that keeps a HubSpot portal’s properties and property groups as TypeScript files in your repo. We’re looking for people to try it on a sandbox or test account, and for a few people to help maintain it.

Why we built it

Every HubSpot project we’ve worked on starts with a script that creates the custom properties. Then someone renames a label in the UI, a second portal needs the same setup, and a few months later nobody can say what’s live in which portal. Our team has run versions of this as internal scripts for a few years. Kalup is the standardised version.

What it does

  • kalup pull reads a portal and writes its properties and groups into TypeScript files.
  • kalup plan shows every change before anything is written.
  • kalup apply writes the change to the portal you name (a sandbox, a client’s portal, production) after a person confirms it.
  • Edits people make in the HubSpot UI show up as drift. Kalup reports them and doesn’t overwrite them unless you tell it to.
  • Your app imports the same files for its types, so your code and your portal agree on property names and enum values.

A config file looks like this:

import { defineObject, p } from '@kalup/core'

export const Company = defineObject('companies', {
  groups: {
    billing: { label: 'Billing' },
  },
  properties: {
    billingStatus: p.enum('billing_status', {
      label: 'Billing status',
      group: 'billing',
      fieldType: 'select',
      options: [
        { value: 'active', label: 'Active' },
        { value: 'cancelled', label: 'Cancelled' },
      ],
    }),
  },
})

Safety

  • Removing a line from a file never deletes anything in HubSpot. Deletes only happen in takeover mode, which you switch on per portal, and a person confirms each one at a terminal.
  • Config files are parsed as data and never executed, so a plan shows exactly what’s in the repo.

Try it

You need Node 22.13.1 or later and a service key. kalup init prints the exact scopes the key needs.

npm install @kalup/core
npm install -D kalup
npx kalup init --portal <portal-id> --target sandbox
npx kalup pull
npx kalup plan

What we’d like from you

  • Run pull against a sandbox and tell us what it gets wrong and what we get right. GitHub issues are best, replies here are fine too.
  • If you’d like to help maintain it, reply here or message me. People who know the pipelines or association APIs well, or who run many client portals, would help most right now.

GitHub: GitHub - scopiousdigital/kalup: Kalup: configuration as code for HubSpot · GitHub
Docs: https://kalup.dev/docs

It’s early (0.2), free, Apache-2.0, and independent. It is not affiliated with or endorsed by HubSpot.

Hi @AnzeKoprivec and welcome back, great to see you again here! :orange_heart:

Thanks for sharing Kalup with the HubSpot Community! Sharing also this " Install the HubSpot CLI - HubSpot docs " for reference.

For anyone who gives it a try, I’d be curious to hear about your experience, particularly when managing properties across multiple accounts or sandboxes.

As the project is still early, are there specific HubSpot use cases or APIs you’re hoping to support next?

Thanks so much and have a lovely day!

Bérangère

Hi Berangere!

Thanks for the CLI referenca. Want to point out Kalup is not aimed at replacing HubSpots tooling but extends on top of it. We have a dedicated page that talks about our vision here: Kalup and HubSpot's tools · Kalup

We’re looking to support every configuration related API by the v1 release and will be looking at browser extensions to extract out even more if we ever get to the cloud product phase.

For now, as a development agency, kalup solved portal scaffolding and management for us and thats already a huge quality of life improvement for us.