# GHL Funnels API **Endpoints:** 7 **Base URL:** `https://rest.gohighlevel.com/v1` **Version Header(s):** `2021-07-28` --- ## Endpoints - [GET /funnels/funnel/list](#get--funnels-funnel-list) — Fetch List of Funnels - [POST /funnels/lookup/redirect](#post--funnels-lookup-redirect) — Create Redirect - [GET /funnels/lookup/redirect/list](#get--funnels-lookup-redirect-list) — Fetch List of Redirects - [DELETE /funnels/lookup/redirect/{id}](#delete--funnels-lookup-redirect-id) — Delete Redirect By Id - [PATCH /funnels/lookup/redirect/{id}](#patch--funnels-lookup-redirect-id) — Update Redirect By Id - [GET /funnels/page](#get--funnels-page) — Fetch list of funnel pages - [GET /funnels/page/count](#get--funnels-page-count) — Fetch count of funnel pages --- ## GET /funnels/funnel/list **Summary:** Fetch List of Funnels Retrieves a list of all funnels based on the given query parameters. **Version Header:** Not required **Operation ID:** `getFunnels` **Tags:** Funnel ### cURL ```bash curl -X GET 'https://rest.gohighlevel.com/v1/funnels/funnel/list?locationId=VALUE&type=VALUE&category=VALUE&offset=VALUE&limit=VALUE&parentId=VALUE&name=VALUE' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ -H 'User-Agent: YourApp/1.0' ``` ### Python (http.client) ```python import http.client import json conn = http.client.HTTPSConnection('rest.gohighlevel.com') headers = { 'Authorization': 'Bearer YOUR_API_TOKEN', 'Content-Type': 'application/json', 'Accept': 'application/json', 'User-Agent': 'YourApp/1.0', } conn.request('GET', '/v1/funnels/funnel/list?locationId=VALUE&type=VALUE&category=VALUE&offset=VALUE&limit=VALUE&parentId=VALUE&name=VALUE', headers=headers) response = conn.getresponse() data = json.loads(response.read().decode()) print(json.dumps(data, indent=2)) conn.close() ``` ### n8n HTTP Node ```json { "name": "GHL - GET list", "type": "n8n-nodes-base.httpRequest", "parameters": { "method": "GET", "url": "https://rest.gohighlevel.com/v1/funnels/funnel/list", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendHeaders": true, "headerParameters": { "parameters": [ { "name": "Authorization", "value": "Bearer YOUR_API_TOKEN" }, { "name": "Content-Type", "value": "application/json" }, { "name": "Accept", "value": "application/json" }, { "name": "User-Agent", "value": "YourApp/1.0" } ] }, "sendBody": false, "bodyParameters": { "parameters": [] }, "options": {}, "sendQuery": true, "queryParameters": { "parameters": [ { "name": "locationId", "value": "VALUE" }, { "name": "type", "value": "VALUE" }, { "name": "category", "value": "VALUE" }, { "name": "offset", "value": "VALUE" }, { "name": "limit", "value": "VALUE" }, { "name": "parentId", "value": "VALUE" }, { "name": "name", "value": "VALUE" } ] } } } ``` **To use in n8n:** 1. Add an HTTP Request node 2. Switch to JSON mode (Parameters → use RAW JSON) 3. Paste the JSON above 4. Update `YOUR_API_TOKEN` with your actual GHL API key ### Request Parameters | Name | Location | Type | Required | Description | |------|----------|------|----------|-------------| | `locationId` | Query | `string` | ✅ | | | `type` | Query | `string` | — | | | `category` | Query | `string` | — | | | `offset` | Query | `string` | — | | | `limit` | Query | `string` | — | | | `parentId` | Query | `string` | — | | | `name` | Query | `string` | — | | ### Response Codes | Code | Description | Schema | |------|-------------|--------| | `200` | Successful response - List of funnels returned | - **funnels** (object) (required) (e.g. `{'_id': 'SkIDfu0S4m3NYQyvWHC6', 'dateAdded': '2024-04-29T15:00:05.681Z', 'dateUpdated': '2024-04-29T15:0... | ### ⚠️ Special Notes & Quirks > ⚠️ **User-Agent Required:** All GHL API requests require a `User-Agent` HTTP header. Requests without it may be rejected with a 403 error. --- ## POST /funnels/lookup/redirect **Summary:** Create Redirect The "Create Redirect" API Allows adding a new url redirect to the system. Use this endpoint to create a url redirect with the specified details. Ensure that the required information is provided in the request payload. **Version Header:** `2021-07-28` **Operation ID:** `create-redirect` **Tags:** Redirect ### cURL ```bash curl -X POST 'https://rest.gohighlevel.com/v1/funnels/lookup/redirect' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Version: 2021-07-28' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ -H 'User-Agent: YourApp/1.0' \ -d '{}' # See request body schema below ``` ### Python (http.client) ```python import http.client import json conn = http.client.HTTPSConnection('rest.gohighlevel.com') headers = { 'Authorization': 'Bearer YOUR_API_TOKEN', 'Version': '2021-07-28', 'Content-Type': 'application/json', 'Accept': 'application/json', 'User-Agent': 'YourApp/1.0', } payload = json.dumps({}) conn.request('POST', '/v1/funnels/lookup/redirect', body=payload, headers=headers) response = conn.getresponse() data = json.loads(response.read().decode()) print(json.dumps(data, indent=2)) conn.close() ``` ### n8n HTTP Node ```json { "name": "GHL - POST redirect", "type": "n8n-nodes-base.httpRequest", "parameters": { "method": "POST", "url": "https://rest.gohighlevel.com/v1/funnels/lookup/redirect", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendHeaders": true, "headerParameters": { "parameters": [ { "name": "Authorization", "value": "Bearer YOUR_API_TOKEN" }, { "name": "Version", "value": "2021-07-28" }, { "name": "Content-Type", "value": "application/json" }, { "name": "Accept", "value": "application/json" }, { "name": "User-Agent", "value": "YourApp/1.0" } ] }, "sendBody": true, "bodyParameters": { "parameters": [] }, "options": {} } } ``` **To use in n8n:** 1. Add an HTTP Request node 2. Switch to JSON mode (Parameters → use RAW JSON) 3. Paste the JSON above 4. Update `YOUR_API_TOKEN` with your actual GHL API key ### Request Body Schema - **locationId** (string) (required) (e.g. `6p2RxpgtMKQwO3E6IUaT`) - **domain** (string) (required) (e.g. `example.com`) - **path** (string) (required) (e.g. `/Hello`) - **target** (string) (required) (e.g. `https://www.google.com`) - **action** (string) (required) (e.g. `URL`) ### Response Codes | Code | Description | Schema | |------|-------------|--------| | `200` | Successful response | - **data** (string) (required): Data containing details of the created redirect | | `422` | Unprocessable Entity | Standard error response for unprocessable entity (422). Contains message, statusCode, errors array fields. | ### ⚠️ Special Notes & Quirks > ⚠️ **User-Agent Required:** All GHL API requests require a `User-Agent` HTTP header. Requests without it may be rejected with a 403 error. --- ## GET /funnels/lookup/redirect/list **Summary:** Fetch List of Redirects Retrieves a list of all URL redirects based on the given query parameters. **Version Header:** `2021-07-28` **Operation ID:** `fetch-redirects-list` **Tags:** Redirect ### cURL ```bash curl -X GET 'https://rest.gohighlevel.com/v1/funnels/lookup/redirect/list?locationId=VALUE&limit=VALUE&offset=VALUE&search=VALUE' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Version: 2021-07-28' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ -H 'User-Agent: YourApp/1.0' ``` ### Python (http.client) ```python import http.client import json conn = http.client.HTTPSConnection('rest.gohighlevel.com') headers = { 'Authorization': 'Bearer YOUR_API_TOKEN', 'Version': '2021-07-28', 'Content-Type': 'application/json', 'Accept': 'application/json', 'User-Agent': 'YourApp/1.0', } conn.request('GET', '/v1/funnels/lookup/redirect/list?locationId=VALUE&limit=VALUE&offset=VALUE&search=VALUE', headers=headers) response = conn.getresponse() data = json.loads(response.read().decode()) print(json.dumps(data, indent=2)) conn.close() ``` ### n8n HTTP Node ```json { "name": "GHL - GET list", "type": "n8n-nodes-base.httpRequest", "parameters": { "method": "GET", "url": "https://rest.gohighlevel.com/v1/funnels/lookup/redirect/list", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendHeaders": true, "headerParameters": { "parameters": [ { "name": "Authorization", "value": "Bearer YOUR_API_TOKEN" }, { "name": "Version", "value": "2021-07-28" }, { "name": "Content-Type", "value": "application/json" }, { "name": "Accept", "value": "application/json" }, { "name": "User-Agent", "value": "YourApp/1.0" } ] }, "sendBody": false, "bodyParameters": { "parameters": [] }, "options": {}, "sendQuery": true, "queryParameters": { "parameters": [ { "name": "locationId", "value": "VALUE" }, { "name": "limit", "value": "VALUE" }, { "name": "offset", "value": "VALUE" }, { "name": "search", "value": "VALUE" } ] } } } ``` **To use in n8n:** 1. Add an HTTP Request node 2. Switch to JSON mode (Parameters → use RAW JSON) 3. Paste the JSON above 4. Update `YOUR_API_TOKEN` with your actual GHL API key ### Request Parameters | Name | Location | Type | Required | Description | |------|----------|------|----------|-------------| | `locationId` | Query | `string` | ✅ | | | `limit` | Query | `number` | ✅ | | | `offset` | Query | `number` | ✅ | | | `search` | Query | `string` | — | | ### Response Codes | Code | Description | Schema | |------|-------------|--------| | `200` | Successful response - List of URL redirects returned | - **data** (object) (required) (e.g. `{'count': 42, 'data': []}`): Object containing the count of redirects and an array of redirect data | | `422` | Unprocessable Entity - The provided data is invalid or incomplete | — | ### ⚠️ Special Notes & Quirks > ⚠️ **User-Agent Required:** All GHL API requests require a `User-Agent` HTTP header. Requests without it may be rejected with a 403 error. --- ## DELETE /funnels/lookup/redirect/{id} **Summary:** Delete Redirect By Id The "Delete Redirect By Id" API Allows deletion of a URL redirect from the system using its unique identifier. Use this endpoint to delete a URL redirect with the specified ID using details provided in the request payload. **Version Header:** `2021-07-28` **Operation ID:** `delete-redirect-by-id` **Tags:** Redirect ### cURL ```bash curl -X DELETE 'https://rest.gohighlevel.com/v1/funnels/lookup/redirect/VALUE?locationId=VALUE' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Version: 2021-07-28' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ -H 'User-Agent: YourApp/1.0' ``` ### Python (http.client) ```python import http.client import json conn = http.client.HTTPSConnection('rest.gohighlevel.com') headers = { 'Authorization': 'Bearer YOUR_API_TOKEN', 'Version': '2021-07-28', 'Content-Type': 'application/json', 'Accept': 'application/json', 'User-Agent': 'YourApp/1.0', } conn.request('DELETE', '/v1/funnels/lookup/redirect/VALUE?locationId=VALUE', headers=headers) response = conn.getresponse() data = json.loads(response.read().decode()) print(json.dumps(data, indent=2)) conn.close() ``` ### n8n HTTP Node ```json { "name": "GHL - DELETE VALUE", "type": "n8n-nodes-base.httpRequest", "parameters": { "method": "DELETE", "url": "https://rest.gohighlevel.com/v1/funnels/lookup/redirect/VALUE", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendHeaders": true, "headerParameters": { "parameters": [ { "name": "Authorization", "value": "Bearer YOUR_API_TOKEN" }, { "name": "Version", "value": "2021-07-28" }, { "name": "Content-Type", "value": "application/json" }, { "name": "Accept", "value": "application/json" }, { "name": "User-Agent", "value": "YourApp/1.0" } ] }, "sendBody": false, "bodyParameters": { "parameters": [] }, "options": {}, "sendQuery": true, "queryParameters": { "parameters": [ { "name": "locationId", "value": "VALUE" } ] } } } ``` **To use in n8n:** 1. Add an HTTP Request node 2. Switch to JSON mode (Parameters → use RAW JSON) 3. Paste the JSON above 4. Update `YOUR_API_TOKEN` with your actual GHL API key ### Request Parameters | Name | Location | Type | Required | Description | |------|----------|------|----------|-------------| | `id` | Path | `string` | ✅ | | | `locationId` | Query | `string` | ✅ | | ### Response Codes | Code | Description | Schema | |------|-------------|--------| | `200` | Successful response - URL redirect deleted successfully | - **data** (object) (required) (e.g. `{'status': 'ok'}`): Status of the delete operation | | `422` | Unprocessable Entity - The provided data is invalid or incomplete | — | ### ⚠️ Special Notes & Quirks > ⚠️ **User-Agent Required:** All GHL API requests require a `User-Agent` HTTP header. Requests without it may be rejected with a 403 error. --- ## PATCH /funnels/lookup/redirect/{id} **Summary:** Update Redirect By Id The "Update Redirect By Id" API Allows updating an existing URL redirect in the system. Use this endpoint to modify a URL redirect with the specified ID using details provided in the request payload. **Version Header:** `2021-07-28` **Operation ID:** `update-redirect-by-id` **Tags:** Redirect ### cURL ```bash curl -X PATCH 'https://rest.gohighlevel.com/v1/funnels/lookup/redirect/VALUE' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Version: 2021-07-28' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ -H 'User-Agent: YourApp/1.0' \ -d '{}' # See request body schema below ``` ### Python (http.client) ```python import http.client import json conn = http.client.HTTPSConnection('rest.gohighlevel.com') headers = { 'Authorization': 'Bearer YOUR_API_TOKEN', 'Version': '2021-07-28', 'Content-Type': 'application/json', 'Accept': 'application/json', 'User-Agent': 'YourApp/1.0', } payload = json.dumps({}) conn.request('PATCH', '/v1/funnels/lookup/redirect/VALUE', body=payload, headers=headers) response = conn.getresponse() data = json.loads(response.read().decode()) print(json.dumps(data, indent=2)) conn.close() ``` ### n8n HTTP Node ```json { "name": "GHL - PATCH VALUE", "type": "n8n-nodes-base.httpRequest", "parameters": { "method": "PATCH", "url": "https://rest.gohighlevel.com/v1/funnels/lookup/redirect/VALUE", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendHeaders": true, "headerParameters": { "parameters": [ { "name": "Authorization", "value": "Bearer YOUR_API_TOKEN" }, { "name": "Version", "value": "2021-07-28" }, { "name": "Content-Type", "value": "application/json" }, { "name": "Accept", "value": "application/json" }, { "name": "User-Agent", "value": "YourApp/1.0" } ] }, "sendBody": true, "bodyParameters": { "parameters": [] }, "options": {} } } ``` **To use in n8n:** 1. Add an HTTP Request node 2. Switch to JSON mode (Parameters → use RAW JSON) 3. Paste the JSON above 4. Update `YOUR_API_TOKEN` with your actual GHL API key ### Request Parameters | Name | Location | Type | Required | Description | |------|----------|------|----------|-------------| | `id` | Path | `string` | ✅ | | ### Request Body Schema - **target** (string) (required) (e.g. `https://www.google.com`) - **action** (string) (required) (e.g. `URL`) - **locationId** (string) (required) (e.g. `6p2RxpgtMKQwO3E6IUaT`) ### Response Codes | Code | Description | Schema | |------|-------------|--------| | `200` | Successful response | - **data** (string) (required): Data containing details of the updated redirect | | `422` | Unprocessable Entity | Standard error response for unprocessable entity (422). Contains message, statusCode, errors array fields. | ### ⚠️ Special Notes & Quirks > ⚠️ **User-Agent Required:** All GHL API requests require a `User-Agent` HTTP header. Requests without it may be rejected with a 403 error. --- ## GET /funnels/page **Summary:** Fetch list of funnel pages Retrieves a list of all funnel pages based on the given query parameters. **Version Header:** Not required **Operation ID:** `getPagesByFunnelId` **Tags:** Funnel ### cURL ```bash curl -X GET 'https://rest.gohighlevel.com/v1/funnels/page?locationId=VALUE&funnelId=VALUE&name=VALUE&limit=VALUE&offset=VALUE' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ -H 'User-Agent: YourApp/1.0' ``` ### Python (http.client) ```python import http.client import json conn = http.client.HTTPSConnection('rest.gohighlevel.com') headers = { 'Authorization': 'Bearer YOUR_API_TOKEN', 'Content-Type': 'application/json', 'Accept': 'application/json', 'User-Agent': 'YourApp/1.0', } conn.request('GET', '/v1/funnels/page?locationId=VALUE&funnelId=VALUE&name=VALUE&limit=VALUE&offset=VALUE', headers=headers) response = conn.getresponse() data = json.loads(response.read().decode()) print(json.dumps(data, indent=2)) conn.close() ``` ### n8n HTTP Node ```json { "name": "GHL - GET page", "type": "n8n-nodes-base.httpRequest", "parameters": { "method": "GET", "url": "https://rest.gohighlevel.com/v1/funnels/page", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendHeaders": true, "headerParameters": { "parameters": [ { "name": "Authorization", "value": "Bearer YOUR_API_TOKEN" }, { "name": "Content-Type", "value": "application/json" }, { "name": "Accept", "value": "application/json" }, { "name": "User-Agent", "value": "YourApp/1.0" } ] }, "sendBody": false, "bodyParameters": { "parameters": [] }, "options": {}, "sendQuery": true, "queryParameters": { "parameters": [ { "name": "locationId", "value": "VALUE" }, { "name": "funnelId", "value": "VALUE" }, { "name": "name", "value": "VALUE" }, { "name": "limit", "value": "VALUE" }, { "name": "offset", "value": "VALUE" } ] } } } ``` **To use in n8n:** 1. Add an HTTP Request node 2. Switch to JSON mode (Parameters → use RAW JSON) 3. Paste the JSON above 4. Update `YOUR_API_TOKEN` with your actual GHL API key ### Request Parameters | Name | Location | Type | Required | Description | |------|----------|------|----------|-------------| | `locationId` | Query | `string` | ✅ | | | `funnelId` | Query | `string` | ✅ | | | `name` | Query | `string` | — | | | `limit` | Query | `number` | ✅ | | | `offset` | Query | `number` | ✅ | | ### Response Codes | Code | Description | Schema | |------|-------------|--------| | `200` | Successful response - List of funnel pages returned | - **_id** (string) (required) (e.g. `0yJbP3q7t7pLmeTWRAE2`)
- **locationId** (string) (required) (e.g. `ojQjykmwNIU88vfsfzvH`)
- **funnelId**... | ### ⚠️ Special Notes & Quirks > ⚠️ **User-Agent Required:** All GHL API requests require a `User-Agent` HTTP header. Requests without it may be rejected with a 403 error. --- ## GET /funnels/page/count **Summary:** Fetch count of funnel pages Retrieves count of all funnel pages based on the given query parameters. **Version Header:** Not required **Operation ID:** `getPagesCountByFunnelId` **Tags:** Funnel ### cURL ```bash curl -X GET 'https://rest.gohighlevel.com/v1/funnels/page/count?locationId=VALUE&funnelId=VALUE&name=VALUE' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Content-Type: application/json' \ -H 'Accept: application/json' \ -H 'User-Agent: YourApp/1.0' ``` ### Python (http.client) ```python import http.client import json conn = http.client.HTTPSConnection('rest.gohighlevel.com') headers = { 'Authorization': 'Bearer YOUR_API_TOKEN', 'Content-Type': 'application/json', 'Accept': 'application/json', 'User-Agent': 'YourApp/1.0', } conn.request('GET', '/v1/funnels/page/count?locationId=VALUE&funnelId=VALUE&name=VALUE', headers=headers) response = conn.getresponse() data = json.loads(response.read().decode()) print(json.dumps(data, indent=2)) conn.close() ``` ### n8n HTTP Node ```json { "name": "GHL - GET count", "type": "n8n-nodes-base.httpRequest", "parameters": { "method": "GET", "url": "https://rest.gohighlevel.com/v1/funnels/page/count", "authentication": "genericCredentialType", "genericAuthType": "httpHeaderAuth", "sendHeaders": true, "headerParameters": { "parameters": [ { "name": "Authorization", "value": "Bearer YOUR_API_TOKEN" }, { "name": "Content-Type", "value": "application/json" }, { "name": "Accept", "value": "application/json" }, { "name": "User-Agent", "value": "YourApp/1.0" } ] }, "sendBody": false, "bodyParameters": { "parameters": [] }, "options": {}, "sendQuery": true, "queryParameters": { "parameters": [ { "name": "locationId", "value": "VALUE" }, { "name": "funnelId", "value": "VALUE" }, { "name": "name", "value": "VALUE" } ] } } } ``` **To use in n8n:** 1. Add an HTTP Request node 2. Switch to JSON mode (Parameters → use RAW JSON) 3. Paste the JSON above 4. Update `YOUR_API_TOKEN` with your actual GHL API key ### Request Parameters | Name | Location | Type | Required | Description | |------|----------|------|----------|-------------| | `locationId` | Query | `string` | ✅ | | | `funnelId` | Query | `string` | ✅ | | | `name` | Query | `string` | — | | ### Response Codes | Code | Description | Schema | |------|-------------|--------| | `200` | Successful response - Count of funnel pages returned | - **count** (number) (required) (e.g. `20`) | ### ⚠️ Special Notes & Quirks > ⚠️ **User-Agent Required:** All GHL API requests require a `User-Agent` HTTP header. Requests without it may be rejected with a 403 error. --- *Documentation generated from GHL OpenAPI specifications. Verify against official docs for latest changes.*