Create private apps with projects (BETA)

Create private apps to access your HubSpot data through HubSpot's APIs. Private apps can only be installed into the account where they're defined. Using a private app, you can access account data similar to using an API key, but with additional security and usability benefits. You can create multiple private apps per project and per account.

When created as part of a HubSpot project, private apps are stored in a folder that contains an app.json file, and will also contain extensions and serverless function files needed by the app.

projects-crm-card-folder-structure

Private apps can include extensions, such as CRM cards, along with serverless functions to power the app and extensions. For example, a private app might include a CRM card to track external ticketing on HubSpot CRM records.

Learn more about the components that can be included in a private app.

Create a private app with a project

Below, learn how to create a private app with HubSpot projects, along with the files necessary for successful deployment. To create a private app in a project, you'll first need to install the HubSpot CLI. To get started with HubSpot projects, you can also check out the quick start guide.

To create a private app within your project:

  • Within the src folder of your project directory,  create an app folder.
  • Within the app folder, create an app.json file. This file will contain your app definitions.
  • Copy the following code into your app.json file:
name  string

A unique name for the app.

description  string

The app's description.

scopes  array

The app's allowed scopes. At least one scope is required.

public  boolean

Set to false for private apps.

extensions  object

Contains the extensions included in the app. For CRM cards, include a crm object, followed by a cards array that contains a file field that references the CRM card JSON definition file.

assets  array

Contains any asset definition files that you're including in the project, using a relative path field that references the source code file.

// example app.json file { "name": "Weather Card", "description": "", "scopes": ["crm.objects.contacts.read", "crm.objects.contacts.write"], "public": false, "extensions": { "crm": { "cards": [ { "file": "./weather-card.json" } ] }, "automation": { "actions": [ { "file": "./fetch-temp-action.json" } ] } }, "assets": [ { "path": "./resources/class-schema.json" } ] }

Manage private apps in HubSpot

If you're a super admin, you can access and manage private apps in your HubSpot account, including viewing your apps, their build history, and the access token required to make API calls

To view a private app's details in HubSpot:

  • In your HubSpot account, navigate to CRM Development.
  • In the left sidebar menu, navigate to Private apps.
  • Click the name of the private app.

You'll then be taken to the app's Details page where you can view and manage its access token, view app logs, and delete the app. Learn more about managing private apps in HubSpot.

Private app limits

You can create up to 20 private apps in your HubSpot account. Each private app is subject to HubSpot's API usage guidelines. The number of calls your private app can make is based on your account subscription and whether you've purchased the API add-on:

  Product Tier Per 10 Seconds Per Day
Private Apps

All Hubs CRM Free and Starter

100 / private app 250,000 / account
 

(Any Hub)

Pro and Enterprise

150 / private app 500,000 / account
Private Apps with API Add-on

(Any Hub)

Free, Starter, Professional, and Enterprise

200 / private app 1,000,000 / account