Skip to main content
Glama
ghl-mcp-server-v2

ghl-mcp-server-v2

by zackscriven

ghl_oauth_get_location_access_token

Generates a location access token from an agency-level token using companyId and locationId, enabling location-scoped OAuth access for legacy integrations.

Instructions

REQUIRES AN AGENCY-LEVEL (Company) TOKEN — spec security is Agency-Access-Only. Body is application/x-www-form-urlencoded per spec (companyId, locationId as form fields), not JSON. Legacy twin of POST /oauth/location-token (v3); prefer the v3 op for new integrations. [LEGACY FALLBACK — this endpoint is no longer in the live v3 docs (checked 2026-10-28) but is still served under the legacy Version header. Expect removal; prefer a current equivalent.] Get Location Access Token from Agency Token This API allows you to generate locationAccessToken from AgencyAccessToken Endpoint: POST /oauth/locationToken (Version header: 2021-07-28; source: oauth.json) Requires an Agency (company-level) token. OAuth access token only — Private Integration Tokens are rejected. OAuth scopes: oauth.write

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "body": "<body>"
    },
    "name": "ghl_oauth_get_location_access_token"
  }
}

Input Schema

NameRequiredDescriptionDefault
bodyYesRequest body (schema carried verbatim from the official OpenAPI spec).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well past the annotations: annotations cover non-readOnly/non-idempotent/openWorld, while the description adds the auth model (Agency token only, PITs rejected), OAuth scope, the wire format (x-www-form-urlencoded, not JSON), and an explicit removal/deprecation warning checked against a dated docs snapshot. That is exactly the context an agent needs before invoking a token-minting POST.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Important constraints (agency token requirement, legacy status) are front-loaded, but the same points are restated two or three times — the agency-token requirement appears in the first line, mid-description, and again with the Private Integration note, and the legacy/removal warning is duplicated. Trimming the repetition would lose no information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a one-parameter, no-output-schema token endpoint, the definition supplies auth requirements, scoping, body encoding, endpoint/version, and lifecycle status — everything needed to call it correctly and to decide not to. The absence of an output schema is immaterial since the description states what the call yields.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3; the description earns an extra point by clarifying that companyId and locationId must be sent as form fields in a urlencoded body rather than as a JSON object, which the schema itself does not convey. It does not, however, explain any validation or cross-constraint between the two IDs.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource (generate a locationAccessToken from an AgencyAccessToken) and pins the exact endpoint POST /oauth/locationToken. It also differentiates itself from its near-twin by naming POST /oauth/location-token (v3) as the preferred sibling, so an agent can route correctly without opening either schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit routing guidance: use this only as a legacy fallback under the 2021-07-28 Version header, and prefer the v3 op or a current equivalent for new integrations. It also states the precondition (agency/company-level OAuth token; Private Integration Tokens rejected) and the required scope, oauth.write.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools