Hubspot - sgml/signature GitHub Wiki

Mappings

README: Mapping Boutique Proto-CRM Stacks to HubSpot Product Areas via OSI Model

This document maps the components of non-commercial, non-Windows proto-CRM systems (circa 1995–2000) to modern HubSpot CRM product categories using the OSI model as a semantic scaffold. It enables comparative lineage tracing between early open-source CRM logic and contemporary SaaS abstractions.

Scope

  • Timeframe: 1995–2000
  • Stack: Boutique, open-source, non-Windows
  • CRM Type: Proto-CRM (contact tracking, email logging, reminders, reporting)
  • Mapping: HubSpot product areas → OSI model layers

HubSpot → OSI Model Mapping

HubSpot Product Area OSI Model Layers Engaged
Marketing Hub Layer 7 (Application), Layer 6 (Presentation)
Sales Hub Layer 7 (Application), Layer 5 (Session)
Service Hub Layer 7 (Application), Layer 4 (Transport)
CMS Hub Layer 7 (Application), Layer 6 (Presentation), Layer 3 (Network)
Operations Hub Layer 7 (Application), Layer 2 (Data Link), Layer 1 (Physical)

Example: FreeBSD CRM Stack (1999)

Component HubSpot Analog OSI Layer(s)
HTML + JavaScript CMS Hub 7, 6
Perl CGI Scripts Sales Hub 7, 5
PostgreSQL Sales Hub 7
sendmail + Mail::Send Marketing Hub 7
cron + rsync Operations Hub 7, 2, 1

OSI Model Layers and Related RFCs

OSI Layer Name Function Summary Key RFCs & Notes
7 Application Interfaces for end-user services (e.g., HTTP, SMTP) RFC 5321 (SMTP), RFC 7230 (HTTP/1.1), RFC 1939 (POP3), RFC 3501 (IMAP)
6 Presentation Data translation, encryption, compression RFC 1421–1424 (PEM), RFC 2045–2049 (MIME), RFC 5246 (TLS 1.2)
5 Session Connection management between applications RFC 6455 (WebSockets), RFC 5352 (SCTP)
4 Transport Reliable delivery, flow control (TCP, UDP) RFC 793 (TCP), RFC 768 (UDP), RFC 9293 (Updated TCP)
3 Network Routing, addressing (IP, ICMP) RFC 791 (IPv4), RFC 2460 (IPv6), RFC 792 (ICMP), RFC 1191 (Path MTU Discovery)
2 Data Link Framing, MAC addressing, error detection IEEE 802.3 (Ethernet), RFC 894 (IP over Ethernet), RFC 1042 (IP over IEEE 802)
1 Physical Transmission media, signaling Defined by hardware standards (e.g., RS-232, IEEE 802.3); not governed by RFCs

Usage

This mapping supports:

  • Credential lineage overlays
  • Migration burden analysis
  • Audit hygiene documentation
  • Educational reuse in CRM architecture history

Notes

  • All components are open-source and non-commercial.
  • No Windows-based tools are included.
  • Mapping is symbolic and modular, suitable for ASCII-only overlays.

API SDKs

SDK Test Directories

SDK Repo URL Test Directory Path
Python https://github.com/HubSpot/hubspot-api-python /tests/
Node.js https://github.com/HubSpot/hubspot-api-nodejs /test/crm/
Java https://github.com/HubSpot/hubspot-api-java /src/test/java/com/hubspot/api/crm/

PublicObjectSearchRequest Files

SDK File Path Example Purpose
Python tests/test_crm_contacts.py Tests do_search with filters and pagination
Node.js test/crm/contacts.spec.ts Validates PublicObjectSearchRequest structure
Java CrmSearchApiTest.java Verifies filter group behavior and limits

Key Constraints Validated

  • Max 5 filterGroups per request
  • Max 3 filters per group
  • Max 100 properties returned
  • Cursor-based pagination via paging.next.after

References

OpenAPI Hubspot

OAuth

Activity Log

HTTP Response Codes

  • 409: duplicate; fix search logic
  • 429: rate limit; set a large sleep interval

Certifications

Hubspot Forms

Webhooks

Error Codes

  • urllib3.exceptions.MaxRetryError
  • urllib3.exceptions.NewConnectionError
  • socket.gaierror: [Errno -2] Name or service not known

Properties

  • 'hs_object_source': 'IMPORT'

Imports

Duplicates

Custom Objects

Custom Search API

HubDB CMS API

Hubspot Markup Language: HubL/JinJava

Hubspot App Marketplace

Hubspot Rate Limits and API Request Monitoring

Blogs

Idioms

IDS

  • IDs go by the name vid, id, and hs_object_id` in the legacy API, modern contacts API, and modern properties API respectively

Legacy Contacts API

  • set both the formSubmissionMode=none and the showListMemberships=false URL params to minimize the signal/noise ratio in the API response
  • set the propertyMode=value_only URL param to only return the current property value; unset it to return the history of the property over time

V3 Search API

  • The token search filters only accept alphanumeric values, which is different from the Hubspot GUI, which accepts all characters

Custom Object Creation to deserialize JSON

Definition

from hubspot import HubSpot
from hubspot.crm.objects import SimplePublicObjectInput
from hubspot.crm.schemas import ObjectTypeDefinition, ObjectTypePropertyCreate

# Initialize the HubSpot client
client = HubSpot(api_key='your_hubspot_api_key')

# Define the custom object schema
object_type = ObjectTypeDefinition(
    name='foo',
    labels={'singular': 'Foo', 'plural': 'Foos'},
    primaryDisplayProperty='bar'
)

# Define the property for the custom object
property_definition = ObjectTypePropertyCreate(
    name='bar',
    label='Bar',
    type='string',
    fieldType='text'
)

# Create the custom object schema
custom_object_response = client.crm.schemas.core_api.create(object_type)
property_response = client.crm.schemas.properties_api.create(
    custom_object_response.object_type_id, property_definition
)

print(f"Custom Object Created: {custom_object_response}")
print(f"Property Created: {property_response}")

Instantiation

import json

# Example JSON data
json_data = '{"foo": [{"bar":"baz"}]}'
data = json.loads(json_data)

# Create custom object records
for item in data['foo']:
    custom_object = SimplePublicObjectInput(properties={
        'bar': item['bar']
    })
    record_response = client.crm.objects.basic_api.create(
        object_type=custom_object_response.object_type_id, simple_public_object_input=custom_object
    )
    print(f"Custom Object Record Created: {record_response}")