Geo Compliance

Evaluates the account's most recent Sonar session and returns the current geocompliance status. Use this endpoint to check whether an account holder is currently in a restricted territory before initiating a transaction. Returns the current geocompliance status for the account, including the block reason and matched geofence if applicable.

export FRAME_API_KEY='sk_sandbox_...'

The Geo Compliance object

Attributes
sonar_session_idnullable string

ID of the SonarSession used to evaluate compliance

decision_idnullable string

ID of the geo compliance decision record

evaluated_atnullable string

ISO 8601 timestamp of when compliance was evaluated

statusenum

Geo compliance status for the account One of clear, blocked, or unknown.

reasonenum

Reason for blocked or unknown status One of restricted_territory, vpn_detected, or no_location_data.

geofencedictionary

Geofence the account is blocked by (restricted_territory only)

THE GEO COMPLIANCE OBJECT
{
  "sonar_session_id": null,
  "decision_id": null,
  "evaluated_at": null,
  "status": "clear",
  "reason": "restricted_territory",
  "geofence": {
    "id": null,
    "name": null
  }
}

Get account geo compliance status

Evaluates the account's most recent Sonar session and returns the current geocompliance status. Use this endpoint to check whether an account holder is currently in a restricted territory before initiating a transaction. Returns the current geocompliance status for the account, including the block reason and matched geofence if applicable.

Path parameters
account_idstring

Account ID

Returns

Clear — location is not within any restricted territory

GET/v1/accounts/{account_id}/geo_compliance
curl --request GET \
  --url https://api.framepayments.com/v1/accounts/a70cd72f-e74a-40f2-96a2-3f60714aac4a/geo_compliance \
  --header 'Authorization: Bearer API_KEY'
RESPONSE
{
  "decision_id": "00000000-0000-4000-8000-000000000001",
  "sonar_session_id": "00000000-0000-4000-8000-000000000002",
  "evaluated_at": "2025-04-20T00:00:00Z",
  "status": "clear",
  "reason": "no_location_data"
}

List geofences

Returns all active geofences for your platform, including Frame's predefined platform-level geofences and any custom geofences configured for your account. Geofences define the geographic boundaries where restrictions apply. frameOS provides a set of predefined platform-level geofences for common regulatory use cases — including prohibited states for gaming and other regulated industries — which apply automatically to all accounts with the geo_compliance capability. Returns a 422 error if geocompliance is not enabled for your platform.

Parameters

No parameters.

Returns

A dictionary with a data property containing an array of geofence objects

GET/v1/geofences
curl --request GET \
  --url https://api.framepayments.com/v1/geofences \
  --header 'Authorization: Bearer API_KEY'
RESPONSE
{
  "data": [
    {
      "id": "00000000-0000-4000-8000-000000000001",
      "object": "geofence",
      "name": "California",
      "description": null,
      "geofence_type": "polygon",
      "active": true,
      "metadata": {},
      "locked": false,
      "geofence_rules": []
    }
  ]
}