---
updatedAt: 2026-11-10T17:49:36.000Z
agentTools:
  projectIndex: https://developers.activecampaign.com/llms.txt
---

# Retrieve a contact's data

The contact's data record: one row of extra information the application keeps about the contact, mostly where the contact appears to be located. The location fields (geoIp4, geoCountry2, geo_country, geoState, geoCity, geoZip, geoLat, geoLon, geoTz, geoTzOffset, geoTstamp) are filled by a MaxMind GeoIP lookup of an IP address recorded for the contact, for example when the contact subscribes, opens or clicks a tracked email, or is added through the v1 API with an ip4 value; contact enrichment can also fill the city, state, country, country code and zip when they are blank, and sets geoTstamp when it does. The ga_campaign_*, ga_first_visit, ga_times_visited, fb_id, fb_name and tw_id fields are legacy columns that the application no longer writes. A contact has at most one data record, so the response is a single contactDatum object, not a list: limit, offset, filters and orders are ignored on this path. The record is created on demand (for example the first time a location is stored, or when the contact is personalized for a send), so a contact that has none yet returns an empty object ({}) with status 200. Values come back as strings; tstamp, geoTstamp and ga_first_visit are ISO 8601 dates or null. Returns 404 if the contact does not exist.

```json GET /contacts/:id/contactData (Example RESPONSE)
{
    "contactDatum": {
        "contact": "4",
        "tstamp": "2021-06-09T14:35:10-05:00",
        "geoTstamp": null,
        "geoIp4": "0",
        "geoCountry2": "",
        "geo_country": "",
        "geoState": "",
        "geoCity": "",
        "geoZip": "",
        "geoArea": "0",
        "geoLat": "0.000000",
        "geoLon": "0.000000",
        "geoTz": "",
        "geoTzOffset": "0.00",
        "ga_campaign_source": "",
        "ga_campaign_name": "",
        "ga_campaign_medium": "",
        "ga_campaign_term": "",
        "ga_campaign_content": "",
        "ga_campaign_customsegment": "",
        "ga_first_visit": null,
        "ga_times_visited": "0",
        "fb_id": "0",
        "fb_name": "",
        "tw_id": "0",
        "created_timestamp": "0000-00-00 00:00:00",
        "updated_timestamp": "0000-00-00 00:00:00",
        "created_by": "0",
        "updated_by": "0",
        "links": [],
        "id": "12"
    }
}
```

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "v3",
    "version": "3"
  },
  "servers": [
    {
      "url": "https://{youraccountname}.api-us1.com/api/3",
      "variables": {
        "youraccountname": {
          "default": "youraccountname"
        }
      }
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "name": "Api-Token",
        "in": "header",
        "x-default": ""
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/contacts/{id}/contactData": {
      "get": {
        "summary": "Retrieve a contact's data",
        "description": "The contact's data record: one row of extra information the application keeps about the contact, mostly where the contact appears to be located. The location fields (geoIp4, geoCountry2, geo_country, geoState, geoCity, geoZip, geoLat, geoLon, geoTz, geoTzOffset, geoTstamp) are filled by a MaxMind GeoIP lookup of an IP address recorded for the contact, for example when the contact subscribes, opens or clicks a tracked email, or is added through the v1 API with an ip4 value; contact enrichment can also fill the city, state, country, country code and zip when they are blank, and sets geoTstamp when it does. The ga_campaign_*, ga_first_visit, ga_times_visited, fb_id, fb_name and tw_id fields are legacy columns that the application no longer writes. A contact has at most one data record, so the response is a single contactDatum object, not a list: limit, offset, filters and orders are ignored on this path. The record is created on demand (for example the first time a location is stored, or when the contact is personalized for a send), so a contact that has none yet returns an empty object ({}) with status 200. Values come back as strings; tstamp, geoTstamp and ga_first_visit are ISO 8601 dates or null. Returns 404 if the contact does not exist.",
        "operationId": "retrieve-contact-data",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "ID of the contact",
            "schema": {
              "type": "integer",
              "format": "int32"
            },
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "The contact's data record under contactDatum, or an empty object ({}) when the contact has none yet.",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"contactDatum\": {\n        \"contact\": \"4\",\n        \"tstamp\": \"2021-06-09T14:35:10-05:00\",\n        \"geoTstamp\": null,\n        \"geoIp4\": \"0\",\n        \"geoCountry2\": \"\",\n        \"geo_country\": \"\",\n        \"geoState\": \"\",\n        \"geoCity\": \"\",\n        \"geoZip\": \"\",\n        \"geoArea\": \"0\",\n        \"geoLat\": \"0.000000\",\n        \"geoLon\": \"0.000000\",\n        \"geoTz\": \"\",\n        \"geoTzOffset\": \"0.00\",\n        \"ga_campaign_source\": \"\",\n        \"ga_campaign_name\": \"\",\n        \"ga_campaign_medium\": \"\",\n        \"ga_campaign_term\": \"\",\n        \"ga_campaign_content\": \"\",\n        \"ga_campaign_customsegment\": \"\",\n        \"ga_first_visit\": null,\n        \"ga_times_visited\": \"0\",\n        \"fb_id\": \"0\",\n        \"fb_name\": \"\",\n        \"tw_id\": \"0\",\n        \"created_timestamp\": \"0000-00-00 00:00:00\",\n        \"updated_timestamp\": \"0000-00-00 00:00:00\",\n        \"created_by\": \"0\",\n        \"updated_by\": \"0\",\n        \"links\": [],\n        \"id\": \"12\"\n    }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "contactDatum": {
                      "type": "object",
                      "properties": {
                        "contact": {
                          "type": "string",
                          "example": "4",
                          "description": "Id of the contact this record belongs to."
                        },
                        "tstamp": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "example": "2021-06-09T14:35:10-05:00",
                          "description": "When this record was first created. ISO 8601 with a UTC offset, or null."
                        },
                        "geoTstamp": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "When the location fields were last updated. ISO 8601 with a UTC offset. Null if no location has been stored."
                        },
                        "geoIp4": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "example": "0",
                          "description": "The IP address the location was worked out from, stored as a single number rather than dotted form. 0 or null when there is none."
                        },
                        "geoCountry2": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "example": "",
                          "description": "Two-letter ISO country code from the location lookup. Empty or null when unknown."
                        },
                        "geo_country": {
                          "type": "string",
                          "example": "",
                          "description": "Country name from the location lookup. Empty when unknown. This field keeps its snake_case name; there is no geoCountry."
                        },
                        "geoState": {
                          "type": "string",
                          "example": "",
                          "description": "State, province or region name from the location lookup. Empty when unknown."
                        },
                        "geoCity": {
                          "type": "string",
                          "example": "",
                          "description": "City name from the location lookup. Empty when unknown."
                        },
                        "geoZip": {
                          "type": "string",
                          "example": "",
                          "description": "Postal code from the location lookup. Empty when unknown."
                        },
                        "geoArea": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "example": "0",
                          "description": "Telephone area code. 0 or null; the location lookup no longer supplies one."
                        },
                        "geoLat": {
                          "type": "string",
                          "example": "0.000000",
                          "description": "Latitude from the location lookup, to six decimal places. 0.000000 when unknown."
                        },
                        "geoLon": {
                          "type": "string",
                          "example": "0.000000",
                          "description": "Longitude from the location lookup, to six decimal places. 0.000000 when unknown."
                        },
                        "geoTz": {
                          "type": "string",
                          "example": "",
                          "description": "Time zone name for the location, such as America/Chicago. Used to run automation waits in the contact's local time. Empty when unknown."
                        },
                        "geoTzOffset": {
                          "type": "string",
                          "example": "0.00",
                          "description": "Difference in hours between geoTz and the time zone the database server runs in. Normally 0.00 when geoTz is empty."
                        },
                        "ga_campaign_source": {
                          "type": "string",
                          "example": "",
                          "description": "Legacy field. Nothing writes it today; expect an empty string."
                        },
                        "ga_campaign_name": {
                          "type": "string",
                          "example": "",
                          "description": "Legacy field. Nothing writes it today; expect an empty string."
                        },
                        "ga_campaign_medium": {
                          "type": "string",
                          "example": "",
                          "description": "Legacy field. Nothing writes it today; expect an empty string."
                        },
                        "ga_campaign_term": {
                          "type": "string",
                          "example": "",
                          "description": "Legacy field. Nothing writes it today; expect an empty string."
                        },
                        "ga_campaign_content": {
                          "type": "string",
                          "example": "",
                          "description": "Legacy field. Nothing writes it today; expect an empty string."
                        },
                        "ga_campaign_customsegment": {
                          "type": "string",
                          "example": "",
                          "description": "Legacy field. Nothing writes it today; expect an empty string."
                        },
                        "ga_first_visit": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "Legacy field. Nothing writes it today; expect null."
                        },
                        "ga_times_visited": {
                          "type": "string",
                          "example": "0",
                          "description": "Legacy field. Nothing writes it today; expect 0."
                        },
                        "fb_id": {
                          "type": "string",
                          "example": "0",
                          "description": "Legacy field. Nothing writes it today; expect 0."
                        },
                        "fb_name": {
                          "type": "string",
                          "example": "",
                          "description": "Legacy field. Nothing writes it today; expect an empty string."
                        },
                        "tw_id": {
                          "type": "string",
                          "example": "0",
                          "description": "Legacy field. Nothing writes it today; expect 0."
                        },
                        "created_timestamp": {
                          "type": "string",
                          "example": "0000-00-00 00:00:00",
                          "description": "When the database row was created, as a plain date-time string (not ISO 8601). May be 0000-00-00 00:00:00 on older rows."
                        },
                        "updated_timestamp": {
                          "type": "string",
                          "example": "0000-00-00 00:00:00",
                          "description": "When the database row was last changed, as a plain date-time string (not ISO 8601). May be 0000-00-00 00:00:00 on older rows."
                        },
                        "created_by": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "example": "0",
                          "description": "Id of the account user who created the row, when one was recorded. Usually 0 or null."
                        },
                        "updated_by": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "example": "0",
                          "description": "Id of the account user who last changed the row, when one was recorded. Usually 0 or null."
                        },
                        "links": {
                          "type": "array",
                          "description": "Always an empty list. This record has no related resources of its own."
                        },
                        "id": {
                          "type": "string",
                          "example": "12",
                          "description": "Id of this data record. Not the contact id; use contact for that."
                        }
                      },
                      "description": "The contact's data record. Absent, and the whole body an empty object, when the contact has none yet."
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "No contact has this id. Body: message, \"No Result found for Subscriber with id\" followed by the id.",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"message\": \"No Result found for Subscriber with id 121\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "No Result found for Subscriber with id 121",
                      "description": "Says which record was not found and its id."
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": false,
    "proxy-enabled": false
  },
  "x-readme-fauxas": true
}
```