Skip to content

Thank you for installing the FileManager app

There is just one more step you need to do before it works.

Since our app requires an additional custom object called 'filerecords', and HubSpot does not allow us to automatically create that during the installatiion we do need your help with this. You have two ways of achieving this:

Make a single postman request to get you sorted.

**Method**: POST
**URL**: `https://api.hubapi.com/crm/v3/schemas`
**Headers**:
```
Authorization: Bearer YOUR_PRIVATE_APP_TOKEN
Content-Type: application/json
```

### Request Body
{
"name": "filerecords",
"labels": {
"singular": "File Record",
"plural": "File Records"
},
"primaryDisplayProperty": "file_name",
"secondaryDisplayProperties": ["file_path", "file_type"],
"searchableProperties": ["file_name", "file_path", "description", "tags"],
"requiredProperties": ["file_name", "file_path"],
"properties": [
{
"name": "file_path",
"label": "File Path",
"type": "string",
"fieldType": "text",
"description": "The path or URL of the file"
},
{
"name": "file_name",
"label": "File Name",
"type": "string",
"fieldType": "text",
"description": "The name of the file"
},
{
"name": "file_size",
"label": "File Size",
"type": "number",
"fieldType": "number",
"description": "Size of the file in bytes"
},
{
"name": "file_type",
"label": "File Type",
"type": "string",
"fieldType": "text",
"description": "MIME type of the file"
},
{
"name": "external_id",
"label": "External ID",
"type": "string",
"fieldType": "text",
"description": "ID of the associated CRM object"
},
{
"name": "external_type",
"label": "External Type",
"type": "enumeration",
"fieldType": "select",
"description": "Type of the associated CRM object",
"options": [
{
"label": "Contact",
"value": "contact"
},
{
"label": "Company",
"value": "company"
},
{
"label": "Deal",
"value": "deal"
},
{
"label": "Ticket",
"value": "ticket"
}
]
},
{
"name": "description",
"label": "Description",
"type": "string",
"fieldType": "textarea",
"description": "Description of the file"
},
{
"name": "tags",
"label": "Tags",
"type": "string",
"fieldType": "text",
"description": "Comma-separated tags for categorization"
},
{
"name": "status",
"label": "Status",
"type": "enumeration",
"fieldType": "select",
"description": "Status of the file record",
"options": [
{
"label": "Active",
"value": "active"
},
{
"label": "Archived",
"value": "archived"
},
{
"label": "Deleted",
"value": "deleted"
}
]
}
],
"associatedObjects": ["CONTACT", "COMPANY", "DEAL", "TICKET"]
}
 
=====

Alternatively you can create them through the UI. For that you do not need postman nor create a private app token for postman to use. But it will take a bit more time.:

## Step 1: Create the Custom Object

1. Go to **Settings** > **Objects** > **Custom Objects**
2. Click **Create custom object**
3. **Object name**: Enter `p_filerecords` (MUST be exactly this)
4. Click **Create**

## Step 2: Configure Basic Settings

1. **Display name (singular)**: File Record
2. **Display name (plural)**: File Records
3. **Primary display property**: Select `file_name` (you'll create this property next)

## Step 3: Create Properties

Click **Create property** for each of the following. Create them in this exact order:

### 1. File Name (REQUIRED)
- **Property name**: `file_name`
- **Label**: File Name
- **Description**: The name of the file
- **Field type**: Single-line text
- Click **Create**

### 2. File Path (REQUIRED)
- **Property name**: `file_path`
- **Label**: File Path
- **Description**: The path or URL of the file
- **Field type**: Single-line text
- Click **Create**

### 3. File Size
- **Property name**: `file_size`
- **Label**: File Size
- **Description**: Size of the file in bytes
- **Field type**: Number
- **Number format**: Formatted number
- Click **Create**

### 4. File Type
- **Property name**: `file_type`
- **Label**: File Type
- **Description**: MIME type of the file
- **Field type**: Single-line text
- Click **Create**

### 5. External ID
- **Property name**: `external_id`
- **Label**: External ID
- **Description**: ID of the associated CRM object
- **Field type**: Single-line text
- Click **Create**

### 6. External Type
- **Property name**: `external_type`
- **Label**: External Type
- **Description**: Type of the associated CRM object
- **Field type**: Dropdown select
- **Options** (add in this order):
  - Label: `Contact`, Internal value: `contact`
  - Label: `Company`, Internal value: `company`
  - Label: `Deal`, Internal value: `deal`
  - Label: `Ticket`, Internal value: `ticket`
- Click **Create**

### 7. Description
- **Property name**: `description`
- **Label**: Description
- **Description**: Description of the file
- **Field type**: Multi-line text
- Click **Create**

### 8. Tags
- **Property name**: `tags`
- **Label**: Tags
- **Description**: Comma-separated tags for categorization
- **Field type**: Single-line text
- Click **Create**

### 9. Status
- **Property name**: `status`
- **Label**: Status
- **Description**: Status of the file record
- **Field type**: Dropdown select
- **Options** (add in this order):
  - Label: `Active`, Internal value: `active`
  - Label: `Archived`, Internal value: `archived`
  - Label: `Deleted`, Internal value: `deleted`
- Click **Create**

## Step 4: Configure Display Properties

1. Go back to the custom object settings
2. Under **Record customization**:
   - **Primary display property**: `file_name`
   - **Secondary display properties**: Add `file_path` and `file_type`
   - **Search properties**: Add `file_name`, `file_path`, `description`, and `tags`

## Step 5: Set Required Properties

1. In the properties list, find `file_name` and `file_path`
2. For each one:
   - Click the property name
   - Toggle **Required** to ON
   - Click **Save**

## Step 6: Create Associations

1. Still in the custom object settings
2. Go to the **Associations** tab
3. Click **Add association**
4. Add these associations (check all four):
   - ✓ Contact
   - ✓ Company
   - ✓ Deal
   - ✓ Ticket
5. Click **Save**