# Get SaaS Plan

GET https://services.leadconnectorhq.com/saas/saas-plan/{planId}

Fetch a specific SaaS plan by plan ID

## Authentication

Send `Authorization: Bearer <token>` using:

- **Agency token: OAuth access token or Private Integration Token.** Scopes: `saas/company.read`

## Parameters

### Header Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `Version` | string | Yes | API Version |

### Path Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `planId` | string | Yes |  |

### Query Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `companyId` | string | Yes |  |

## OpenAPI Specification

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "HighLevel API",
    "version": "v3"
  },
  "servers": [
    {
      "url": "https://services.leadconnectorhq.com"
    }
  ],
  "paths": {
    "/saas/saas-plan/{planId}": {
      "get": {
        "summary": "Get SaaS Plan",
        "operationId": "getSaasPlan",
        "description": "Fetch a specific SaaS plan by plan ID",
        "parameters": [
          {
            "name": "Version",
            "in": "header",
            "description": "API Version",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "v3"
              ]
            }
          },
          {
            "name": "planId",
            "required": true,
            "in": "path",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "companyId",
            "required": true,
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The requested SaaS plan.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SaasPlanResponseDto"
                }
              }
            }
          }
        },
        "security": [
          {
            "Agency-Access": [
              "saas/company.read"
            ]
          }
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearer": {
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "description": "Use the Access Token generated with user type as Sub-Account (OR) Private Integration Token of Sub-Account.",
        "type": "http"
      },
      "Location-Access": {
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "description": "Use the Access Token generated with user type as Sub-Account (OR) Private Integration Token of Sub-Account.",
        "type": "http"
      },
      "Location-Access-Only": {
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "description": "Use the Access Token generated with user type as Sub-Account.",
        "type": "http"
      },
      "Agency-Access": {
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "description": "Use the Access Token generated with user type as Agency (OR) Private Integration Token of Agency.",
        "type": "http"
      },
      "Agency-Access-Only": {
        "scheme": "bearer",
        "bearerFormat": "JWT",
        "description": "Use the Access Token generated with user type as Agency.",
        "type": "http"
      }
    },
    "schemas": {
      "SaasPlanResponseDto": {
        "type": "object",
        "properties": {
          "planId": {
            "type": "string",
            "description": "Unique identifier for the SaaS plan",
            "example": "66c4d36534f21f900dc2a265"
          },
          "companyId": {
            "type": "string",
            "description": "Company ID associated with the SaaS plan",
            "example": "66c4d36534f21f900dc2a265"
          },
          "title": {
            "type": "string",
            "description": "Title of the SaaS plan",
            "example": "AED 1.5 changed"
          },
          "description": {
            "type": "string",
            "description": "Description of the SaaS plan",
            "example": "AED 1.5"
          },
          "saasProducts": {
            "description": "Array of SaaS products included in the plan",
            "example": [
              "2-way-text-messaging",
              "gmb-messaging",
              "web-chat"
            ],
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "features": {
            "description": "Array of v2 feature-permission feature IDs included in the plan. This is the v2-native representation of the plan entitlements (the successor to `saasProducts`); the two are kept in sync via the plan create/update dual-write.",
            "example": [
              "contacts-conversations",
              "web-chat",
              "workflows"
            ],
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "addOns": {
            "description": "Array of add-ons included in the plan",
            "example": [
              "YEXT_V2",
              "WHATSAPP_V1",
              "WORDPRESS_V1",
              "AI_EMPLOYEE",
              "Ad_Publishing_Connect_Your_BM"
            ],
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "planLevel": {
            "type": "number",
            "description": "Level of the plan (0-4)",
            "example": 0
          },
          "trialPeriod": {
            "type": "number",
            "description": "Trial period in days",
            "example": 16
          },
          "setupFee": {
            "type": "number",
            "description": "Setup fee for the plan",
            "example": 100
          },
          "userLimit": {
            "type": "number",
            "description": "User limit for the plan",
            "example": 50
          },
          "contactLimit": {
            "type": "number",
            "description": "Contact limit for the plan",
            "example": 50
          },
          "prices": {
            "type": "array",
            "description": "Prices for the plan",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "example": "66a9edbfcc6c505a22db7976"
                },
                "billingInterval": {
                  "type": "string",
                  "enum": [
                    "month",
                    "year"
                  ],
                  "example": "month"
                },
                "active": {
                  "type": "boolean",
                  "example": true
                },
                "amount": {
                  "type": "number",
                  "example": 150
                },
                "currency": {
                  "type": "string",
                  "example": "AED"
                },
                "symbol": {
                  "type": "string",
                  "example": "$"
                }
              }
            }
          },
          "categoryId": {
            "type": "string",
            "description": "Category ID for the plan",
            "example": "66911cdc98508ec2731979b9"
          },
          "snapshotId": {
            "type": "string",
            "description": "Snapshot ID for the plan",
            "example": "G8KmpIeLnZc7ZMoJoxDx"
          },
          "providerLocationId": {
            "type": "string",
            "description": "Provider location ID",
            "example": "r06mdj4OrrERzYDvsOdh"
          },
          "productId": {
            "type": "string",
            "description": "Product ID for the plan",
            "example": "66a9edbfcc6c5090bedb7974"
          },
          "isSaaSV2": {
            "type": "boolean",
            "description": "Indicates if this is a SaaS V2 plan",
            "example": true
          },
          "createdAt": {
            "format": "date-time",
            "type": "string",
            "description": "Creation timestamp",
            "example": "2024-07-31T07:54:41.885Z"
          },
          "updatedAt": {
            "format": "date-time",
            "type": "string",
            "description": "Last update timestamp",
            "example": "2025-04-01T12:27:29.167Z"
          }
        },
        "required": [
          "planId",
          "companyId",
          "title",
          "description",
          "saasProducts",
          "planLevel",
          "trialPeriod",
          "prices",
          "isSaaSV2",
          "createdAt",
          "updatedAt"
        ],
        "title": "SaasPlanResponseDto"
      }
    }
  }
}
```

## Code Examples

**cURL**

```bash
curl -L -X GET 'https://services.leadconnectorhq.com/saas/saas-plan/<planId>?companyId=<COMPANYID>' \
  -H 'Authorization: Bearer <TOKEN>' \
  -H 'Version: v3'
```

**Node.js**

```javascript
const options = {
  method: 'GET',
  headers: {
    Authorization: 'Bearer <TOKEN>',
    Version: 'v3'
  }
};

try {
  const response = await fetch('https://services.leadconnectorhq.com/saas/saas-plan/<planId>?companyId=<COMPANYID>', options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

**Python**

```python
import requests

url = "https://services.leadconnectorhq.com/saas/saas-plan/{planId}"

headers = {
    "Authorization": "Bearer <TOKEN>",
    "Version": "v3"
}

params = {
    "companyId": "<COMPANYID>"
}

response = requests.get(url, params=params, headers=headers)
print(response.json())
```

**PHP**

```php
<?php
$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => 'https://services.leadconnectorhq.com/saas/saas-plan/<planId>?companyId=<COMPANYID>',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_CUSTOMREQUEST => 'GET',
  CURLOPT_HTTPHEADER => [
    'Authorization: Bearer <TOKEN>',
    'Version: v3',
  ],
]);

$response = curl_exec($curl);
curl_close($curl);
echo $response;
```

**Java**

```java
HttpResponse<String> response = Unirest
  .get("https://services.leadconnectorhq.com/saas/saas-plan/<planId>?companyId=<COMPANYID>")
  .header("Authorization", "Bearer <TOKEN>")
  .header("Version", "v3")
  .asString();
```

**Go**

```go
package main

import (
  "fmt"
  "net/http"
  "io"
)

func main() {
  url := "https://services.leadconnectorhq.com/saas/saas-plan/<planId>?companyId=<COMPANYID>"
  req, _ := http.NewRequest("GET", url, nil)
  req.Header.Add("Authorization", "Bearer <TOKEN>")
  req.Header.Add("Version", "v3")

  res, _ := http.DefaultClient.Do(req)
  defer res.Body.Close()
  body, _ := io.ReadAll(res.Body)
  fmt.Println(string(body))
}
```

**Ruby**

```ruby
require 'uri'
require 'net/http'

url = URI("https://services.leadconnectorhq.com/saas/saas-plan/<planId>?companyId=<COMPANYID>")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = "Bearer <TOKEN>"
request["Version"] = "v3"

response = http.request(request)
puts response.read_body
```

**PowerShell**

```powershell
$headers = @{
  "Authorization" = "Bearer <TOKEN>"
  "Version" = "v3"
}

$response = Invoke-RestMethod -Uri 'https://services.leadconnectorhq.com/saas/saas-plan/<planId>?companyId=<COMPANYID>' -Method 'GET' -Headers $headers
$response | ConvertTo-Json
```
