Skip to main content

Complete Social Oauth Connection

Immutable Catalog Entry

This descriptor comes from the active versioned Portal catalog.

WRITEghl.complete_social_oauth_connection
  • Contract tier: legacy
  • Risk: write
  • Catalog version: 2026-07-12.2
  • Descriptor hash: 4e0cdc08d7e0e3b7d3814f814458b201d0d7afe300bd5bf5d27e445a7912c902

Complete a Social Planner OAuth connection after the browser bridge captures accountId. If no selectionId/accountName is provided, returns compact connectionOptions. If a selection is provided, attaches that page/profile and returns deleteAccountId for same-flow cleanup. GHL category: Marketing. This writes to GoHighLevel and may change account data.

Request Body

{
"jsonrpc": "2.0",
"id": "ghl-complete-social-oauth-connection-example",
"method": "tools/call",
"params": {
"name": "ghl.complete_social_oauth_connection",
"arguments": {
"sessionId": "sessionId_123",
"dryRun": false,
"tenantId": "tenantId_123",
"attachData": {},
"accountName": "accountName_example",
"selectionId": "selectionId_123"
}
}
}

Arguments Schema

{
"type": "object",
"required": [
"sessionId"
],
"properties": {
"dryRun": {
"type": "boolean",
"default": false,
"description": "When true, return connectionOptions without attaching."
},
"tenantId": {
"type": "string",
"description": "Tenant ID from list_tenants."
},
"sessionId": {
"type": "string",
"description": "OAuth session ID returned by start_social_oauth."
},
"attachData": {
"type": "object",
"description": "Optional override or full attach payload for platforms that require extra fields."
},
"accountName": {
"type": "string",
"description": "Exact page/profile/location name from connectionOptions. Use only when it is unique."
},
"selectionId": {
"type": "string",
"description": "Provider page/profile/location ID from connectionOptions.selectionId."
}
},
"additionalProperties": false
}

Output Schema

{
"type": "object",
"required": [
"ok",
"data",
"error",
"meta"
],
"properties": {
"ok": {
"type": "boolean",
"description": "Whether the GHL MCP operation completed successfully."
},
"data": {
"anyOf": [
{
"type": "object",
"additionalProperties": true
},
{
"type": "array",
"items": {}
},
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
}
],
"description": "Tool-specific GHL or local navigation result when ok is true."
},
"meta": {
"type": "object",
"description": "Safe execution, routing, and timing metadata.",
"additionalProperties": true
},
"error": {
"anyOf": [
{
"type": "object",
"additionalProperties": true
},
{
"type": "null"
}
],
"description": "Safe error details when ok is false; credential values are never returned."
}
},
"description": "Normalized GHL MCP response envelope.",
"additionalProperties": false
}

Code Examples

curl -X POST 'https://portal.madpanda3d.com/api/mcp' \
-H 'Authorization: Bearer mad_live_***' \
-H 'Content-Type: application/json' \
-d '{
"jsonrpc": "2.0",
"id": "ghl-complete-social-oauth-connection-example",
"method": "tools/call",
"params": {
"name": "ghl.complete_social_oauth_connection",
"arguments": {
"sessionId": "sessionId_123",
"dryRun": false,
"tenantId": "tenantId_123",
"attachData": {},
"accountName": "accountName_example",
"selectionId": "selectionId_123"
}
}
}'

Example Responses

{
"ok": true,
"message": "Tool ghl.complete_social_oauth_connection executed successfully.",
"note": "Response shape varies by MCP tool. Inspect live responses for exact fields."
}