CRM Pipelines API Overview

Deals and tickets support multiple pipelines.

Use case for this API: When working with deals, an account might have one pipeline for “New Sales" and another for “Contract Renewals." For tickets, you might have a main support queue and a separate one for escalations. Each of those queues would be a separate ticket pipeline. The CRM Pipelines API can be used to sync one pipeline or another to an external CRM.

Each object stage is a member of exactly one pipeline. Each pipeline always has at least one stage, and each account has at least one pipeline.

Every account initially contains a default pipeline with the pipelineId “default”. On accounts with a single pipeline, the pipeline property for any object will automatically be set to “default” as well. On accounts with multiple pipelines, if you're setting a stage that is not in the default pipeline, you'll also need to set the pipeline property that lines up with that stage.

Response details

Each pipeline will have the following data.

{
  "pipelineId": "api_test_pipeline",
  // String; The internal ID of the pipeline. This ID must be used when referencing the pipeline using the API.
  "createdAt": 1531316781557,
  // Integer; A Unix timestamp in milliseconds representing when the pipeline was created.
  "updatedAt": 1532367855541,
  // Integer; A Unix timestamp in milliseconds representing when the pipeline was last updated.
  "objectType": "TICKET",
  // String, one of TICKET or DEAL; The object type that the pipeline is for.
  "label": "Updated ticket pipeline",
  // String; The label of the pipeline. The label is displayed for the pipeline in HubSpot.
  "displayOrder": 2,
  // Integer; When viewing records in HubSpot, pipelines are displayed starting with the pipeline with the lowest displayOrder value.
  "active": true,
  // Boolean; Only active pipelines can be used when updating records.
  "stages": [
  // A list of stages for the pipeline.
  // Each stage will have the following properties.
    {
      "stageId": "example_stage",
      // String; The internal id of the stage.
      "createdAt": 1531316781557,
      // Integer; A Unix timestamp in milliseconds representing when the stage was created.
      "updatedAt": 1532367855541,
      // Integer; A Unix timestamp in milliseconds representing when the stage was last updated.
      "label": "Example stage",
      // String; The label of the stage. The label is displayed when viewing records in HubSpot.
      "displayOrder": 1,
      // Integer; When viewing records in HubSpot, stages are displayed starting with the stage with the lowest displayOrder value.
      "metadata": {},
      // Reserved for future use.
      "active": true
      // Boolean; only active stages can be used when updating records
    },
    {
      "stageId": "another_example_stage",
      "createdAt": 1531316781557,
      "updatedAt": 1532367855541,
      "label": "Another example stage",
      "displayOrder": 2,
      "metadata": {},
      "active": true
    }
  ],
  "default": false
  // Boolean; Whether or not this pipeline is the default pipeline. 
}

 

Docs for this section or API