Troubleshooting
HTML response instead of JSON
Section titled “HTML response instead of JSON”Usually means the request hit a wrong path, lost the ApiKey, or reached a generic error page:
- Verify Named Credential URL is
https://apis.threelevers.com/only (no duplicated path segments). - Confirm External Credential → Named Principal → APIKey is set and enabled.
- Confirm Flow/Apex uses the imported External Service tied to Three_Levers_API, not a hard-coded URL with the key in query string.
401 Unauthorized
Section titled “401 Unauthorized”- Named Principal value matches the key Three Levers issued for production.
- Key is active and includes access to the
serviceyou are calling (your key may list many services—use the correct name per call). - Custom setting API Key is set if you are testing hosted map or token callouts (both places should match).
- The running user is assigned a permission set with External Credential Principal access to Three Levers API → Named Principal (see Authentication).
Duplicate URL in callout
Section titled “Duplicate URL in callout”If the full URL appears twice (e.g. https://host/https://host/... or /gis/v1/gis/v1/):
- Remove the host from either the Named Credential merge field or the External Service relative path—keep it in one place only.
- Named Credential = base host; OpenAPI
basePath=/gis/v1.
Hosted map unavailable
Section titled “Hosted map unavailable”| Symptom | Likely cause |
|---|---|
| Only local map shown | APIKey__c blank on Three Levers GIS Setting |
| Token error in debug log | Named Principal missing/wrong; service not licensed |
| Blank iframe | CSP frame-src missing for https://apis.threelevers.com |
| Stale token after key change | Update both key locations; click Refresh on component |
Unexpected empty properties
Section titled “Unexpected empty properties”- Confirm lat/long are decimal degrees in the expected order (not swapped).
- Verify
servicematches one of the names on your key exactly (not a layer from another org or an old name). - Test coordinates known to fall inside the layer extent.
- In Flow, map Action output to the correct type; success often under Code200.
Cache behavior
Section titled “Cache behavior”Responses may include a cache hint (fromcache or similar). Cached answers are normal for repeated lookups; wait for TTL or retry with a distinct test point when validating config changes.
Flow mapping surprises
Section titled “Flow mapping surprises”Generated External Service types may expose optional fields with companion _set flags. Map the fields your Flow actually uses; ignore unused optional groups.
Map token-specific errors
Section titled “Map token-specific errors”Token API returned 4xx: Principal key orservicename; confirm body includes licensedservice.No Named Credential endpoint candidates: Package Named Credential missing or disabled; reinstall or enable Three_Levers_API.
Still stuck?
Section titled “Still stuck?”Contact support — paid API clients include phone support.