Language Profiles (Legacy): Get

Gets the requested Language Profile for a given Location

NOTE:

  • Responses will contain resolved values for embedded fields
  • If the fields parameter is unspecified, responses will contain the full entity profile for the requested language
path Parameters
accountId
required
string
locationId
required
string
languageCode
required
string

The language code corresponding to the language of the profiles that the user wishes to retrieve

query Parameters
fields
string

Comma-separated list of field names from the Location object. When present, only the fields listed will be returned. You can use dot notation to specify substructures (e.g., "logo.url"). To include a custom field, specify it as custom###, where "###" is the custom field's id.

v
required
string

A date in YYYYMMDD format.

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "response": {
    }
}

Language Profiles Schema (Legacy): Get

Gets the schema.org-compliant schema for the requested Language Profile of a given Location. Schema will vary depending on the primary category of the Location.

path Parameters
accountId
required
string
locationId
required
string
languageCode
required
string

The language code corresponding to the language of the profiles that the user wishes to retrieve

query Parameters
v
required
string

A date in YYYYMMDD format.

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "response": {
    }
}

Locations (Legacy): Get

Gets the primary profile for a single Location

NOTE: Responses will contain resolved values for embedded fields

path Parameters
accountId
required
string
locationId
required
string
query Parameters
fields
string

Comma-separated list of field names from the Location object. When present, only the fields listed will be returned. You can use dot notation to specify substructures (e.g., "logo.url"). To include a custom field, specify it as custom###, where "###" is the custom field's id.

v
required
string

A date in YYYYMMDD format.

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "response": {
    }
}

Locations (Legacy): List

Get multiple Locations (primary profile only). Filters are evaluated against all language profiles as well as the primary profile.

NOTE: Responses will contain resolved values for embedded fields

path Parameters
accountId
required
string
query Parameters
limit
integer <= 50
Default: 10

Number of results to return.

offset
integer [ 0 .. 9949 ]
Default: 0

Number of results to skip. Used to move through results

languages
string
Default: "false"

Comma-separated list of language codes. When present, the system will return Locations with one or more of the provided languages. For each Location, only the first available language from the provided list will be returned. The keyword "primary" can be used to refer to a Location’s primary profile without providing a specific language code.

fields
string

Comma-separated list of field names from the Location object. When present, only the fields listed will be returned. You can use dot notation to specify substructures (e.g., "logo.url"). To include a custom field, specify it as custom###, where "###" is the custom field's id.

filters
string

A set of filters that is applied to the set of locations that would otherwise be returned. Should be provided as a URL-encoded string containing a JSON array. The array should have one or more filter objects defined. All filter objects will apply as an intersection (i.e., AND). Field names reference Location fields, as well as custom fields using the format custom###, where "###" is the custom field’s id.

For example, to provide a filter that would match location names containing the word "gourmet", the filter parameter would be [{"name":{"contains":["gourmet"]}}], which URL-encoded would be %5B%7B%22name%22%3A%7B%22contains%22%3A%5B%22gourmet%22%5D%7D%7D%5D.

NOTE: "x", "xx", and "xxx" are reserved keywords that, when passed in a contains matcher for a Full or Text filter, will cause that filter to match on all locations.

The filter types are the following. Note there may be multiple available specifications for a given filter type:

Filter Type Syntax Description
Full fieldName: {contains: $search} $search is the search string
Text fieldName: {$type: [$search,...]} $type is one of [contains,doesNotContain,startsWith,equalTo], $search is an array of search strings, combined with OR
Text fieldName: $type $type is one of [empty,notEmpty]
Number fieldName: {$type: $value} $type is one of [eq,lt,gt,le,ge], $value is the numeric value
Number fieldName: {$type: [$value1, $value2]} $type is one of [between], $value1 and $value2 are numeric values
Date fieldName: {$type: $value} $type is one of [eq,lt,gt,le,ge], $value is a string of "YYYY-MM-DD" formatted date
Date fieldName: $type $type is one of [empty,notEmpty]
Date fieldName: {$type: [$value1, $value2]} $type is one of [between], $value1 and $value2 are strings of "YYYY-MM-DD" formatted date
Categories fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of numeric category IDs, combined with OR
Categories fieldName: $type $type is one of [none]
Assets fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of numeric category IDs, combined with OR
Assets fieldName: $type $type is one of [none]
Country fieldName: {$type: [$country,...]} $type is one of [includes,notIncludes], $country is an array of country code strings, combined with OR
PrimaryLanguage fieldName: {$type: [$language,...]} $type is one of [is,isNot], $language is an array of language code strings, combined with OR
AlternateLanguage fieldName: {$type: [$language,...]} $type is one of [includes, notIncludes], $language is an array of language code strings, combined with OR
StringSingle fieldName: {$type: [$string,...]} $type is one of [is,isNot], $string is an array of strings, combined with OR
StringList fieldName: {$type: [$string,...]} $type is one of [includes,notIncludes], $string is an array of strings, combined with OR
LocationType fieldName: {$type: [$id,...]} $type is one of [is,isNot], $id is an array of location type IDs, combined with OR
Bool fieldName: $type $type is one of [true,false]
Option fieldName: {$type: $id} $type is one of [is,isNot], $id is an option ID (For single option custom fields)
Option fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of option IDs, combined with OR (For multi option custom fields)
Folder fieldName: [$id,...] $id is a numeric folder ID
Folder fieldName: $id $id is a numeric folder ID
Folder fieldName: {$type: [$id,...]} $id is a numeric folder ID, $type is one of ['isIn', 'isNotIn']
Labels fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of label IDs, combined with OR

The following fields can be specified in the request (Field name/Filter Type/Example(s)):

Field Name Filter Type Example(s)
location Full "location": {"contains": "Atlanta"}
name Text "name": {"startsWith": ["Guitar"]}, "name": {"contains": ["A","B"]}
address Text "address": {"startsWith": ["South"]}
address2 Text "address2": {"contains": ["Suite"]}
city Text "city": {"contains": ["Atlanta"]}
state Text "state": {"contains": ["AK","VA"]}
zip Text "zip": {"contains": ["M5K 7QB"]}
phones Text "phones": {"startsWith": ["703","571"]}
specialOffer Text "specialOffer": "notEmpty"
emails Text "emails": {"doesNotContain": ["@yext.com"]}
website Text "website": {"equalTo": ["https://www.yext.com/"]}
categories Categories "categories": {"includes": [23,755,34]}
closed Bool "closed": true
storeId Text "storeId": {"equalTo": ["MCD0001"]}
countryCode Country "countryCode": {"notIncludes": ["US"]}
products Text "products": {"startsWith": ["Burger","Fries"]}
services Text "services": {"contains": ["Manicures"]}
specialities Text "services": "notEmpty"
associations Text "associations": "empty"
brands Text "brands": {"equalTo": ["North Face"]}
languages Text "languages": {"equalTo": ["English","Spanish"]}
keywords Text "keywords": {"startsWith": ["Franchise"]}
menuIds IdList "menuIds": {"includes": ["m-23","755","menu34"]}
productListIds IdList "productListIds": {"notIncludes": ["pl-2"]}
calendarIds IdList "calendarIds": {"notIncludes": ["cal34"]}
bioIds IdList "bioIds": {"includes": ["b23","34"]}
custom### Text (for Multiline Text, URL, Text List, and Text Custom Fields), Number, Date, Bool, or Option "custom123": {"equalTo": ["asdf"]}
folder Folder "folder": 123, "folder": [123,456]
primary_language PrimaryLanguage "primary_language": {"is": "fr_CA"}
alternateProfileLanguage AlternateLanguage "alternateProfileLanguage": {"includes": ["en", "fr"]}
npi StringSingle "npi": {"is": ["1234567890", "1111111111"]}
conditionsTreated Text "conditionsTreated": {"startsWith": ["Influenza"]}, "conditionsTreated": {"contains": ["A","B"]}
lastUpdated Date "lastUpdated": {"eq": "2018-01-01"}, "lastUpdated": {"between": ["2017-01-01", "2018-01-01"]}
fieldsWithData Fields "fieldsWithData": ["email", "hours"]
fieldsWithoutData Fields "fieldsWithoutData": ["logo", "video"]
reviewCount Number "review_count": {"gt": 1}, "review_count ": {"lt": 10}
averageRating Number "averageRating": {"lt": 3}
locationType LocationType "locationType": {"is": [1]}, "locationType": {"isNot": [123]}
gender StringSingle "gender": {"is": ["FEMALE"]}, "gender": {"isNot": ["MALE"]}
degrees StringList "degrees": {"includes": ["MD"]}, "degrees": {"notIncludes": ["PHD"]}
experiences StringList "experiences": {"includes": ["FELLOWSHIP"]}, "experiences": {"notIncludes":["INTERNSHIP"]}
yearCompleted Number "yearCompleted": {"gt": 2000}, "yearCompleted": {"lt": 2015}
acceptingNewPatients Bool "acceptingNewPatients": true
firstName Text "firstName": {"startsWith": ["David"]}, "firstName": {"contains": ["A","B"]}
middleName Text "middleName": {"startsWith": ["P"]}, "middleName": {"contains": ["N","E"]}
lastName Text "lastName": {"startsWith": ["Sm"]}, "lastName": {"contains": ["Y","Z"]}
officeName Text "officeName": {"startsWith": ["Chiropractic"]}, "officeName": {"contains":["Center","P"]}
certifications Text "certifications": {"contains": ["Radiation Oncology"]}
institutionName Text "institutionName": {"startsWith": ["New York"]}
insuranceAccepted Text "insuranceAccepted": {"startsWith": ["United"]}, "insuranceAccepted":{"contains": ["C","Health"]}
admittingHospitals Text "admittingHospitals": {"startsWith": ["Children's"]}, "admittingHospitals":{"contains": ["Medical","University"]}
subscriptions IdList "subscriptions": {"notIncludes": ["123"]}
facebookAccounts IdList "facebookAccounts": {"notIncludes": ["1111"]}
foursquareAccounts IdList "foursquareAccounts": {"notIncludes": ["1111"]}
googleplusAccounts IdList "googleplusAccounts": {"notIncludes": ["1111"]}
labels Labels "labels": {"includes": [1, 100]}
v
required
string

A date in YYYYMMDD format.

sortBy
string

Specifies the fields and direction by which the output should be sorted. Should be provided as a URL-encoded string containing a JSON array of sortDefinition objects. A sortDefinition object consists of a sortField and a sortDirection field. The sortField is the name of the field you are sorting by (e.g., firstName or custom### for a custom field, where "###" is the custom field’s id). The sortDirection indicates whether the sort is ascending (ASCENDING) or descending (DESCENDING).

For example, to sort by last name ascending and first name descending, this parameter would be [{"sortField":"lastName","sortDirection":"ASCENDING"},{"sortField":"firstName", "sortDirection":"DESCENDING"}], which, when URL-encoded, would be %5B%7B%22sortField%22%3A%22lastName%22%2C%22sortDirection%22%3A%22ASCENDING%22%7D%2C%7B%22sortField%22%3A%22firstName%22%2C%22sortDirection%22%3A%22DESCENDING%22%7D%5D.

NOTE: Currently, we support sorting by firstName, lastName, and text custom fields.

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "response": {
    }
}

Locations Schema (Legacy): Get

Gets the schema.org-compliant schema for the primary profile of a single Location. Schema will vary depending on the primary category of the Location.

path Parameters
accountId
required
string
locationId
required
string
query Parameters
v
required
string

A date in YYYYMMDD format.

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "response": {
    }
}

Locations (Legacy): GeoSearch

Gets multiple Locations (primary profile only) near a given location, ordered by proximity to the location (if no other sort criteria are given) and restricted to a radius. Searches through all language profiles, including the primary profile.

NOTE: Responses will contain resolved values for embedded fields

path Parameters
accountId
required
string
query Parameters
limit
integer <= 50
Default: 10

Number of results to return.

offset
integer [ 0 .. 9949 ]
Default: 0

Number of results to skip. Used to move through results

location
required
string

Only entities near this position will be returned. The values can be specified in one of two ways:

  1. Latitude and Longitude: The latitude and longitude of the point, separated by a comma (e.g."40.740957,-73.987565"),

  2. Address: A free-form address to geocode into a latitude and longitude (e.g., "1 Madison Ave, New York, NY 10010" or "New York, NY").

Note that providing an address that resolves to an area, like a city or a postal code, does not restrict the search to exactly that area; it simply centers the search circle on a point in that area.

radius
number [ 0.1 .. 500 ]
Default: 10

Indicates the search radius around the provided location in miles

geocoderBias
string

The latitude, longitude, and approximate radius in miles, separated by commas, where the geocoder should be biased.

countryBias
string

The two-character ISO 3166-1 code of the country where the geocoder should be biased.

The value of the countryBias parameter influences the search results, but it does not guarantee that the geocoded location will be in the country provided.

If both countryBias and geocoderBias are provided, geocoderBias is given priority, but both values are considered in the search.

languages
string
Default: "false"

Comma-separated list of language codes. When present, the system will return Locations with one or more of the provided languages. For each Location, only the first available language from the provided list will be returned. The keyword "primary" can be used to refer to a Location’s primary profile without providing a specific language code.

fields
string

Comma-separated list of field names from the Location object. When present, only the fields listed will be returned. You can use dot notation to specify substructures (e.g., "logo.url"). To include a custom field, specify it as custom###, where "###" is the custom field's id.

filters
string

A set of filters that is applied to the set of locations that would otherwise be returned. Should be provided as a URL-encoded string containing a JSON array. The array should have one or more filter objects defined. All filter objects will apply as an intersection (i.e., AND). Field names reference Location fields, as well as custom fields using the format custom###, where "###" is the custom field’s id.

For example, to provide a filter that would match location names containing the word "gourmet", the filter parameter would be [{"name":{"contains":["gourmet"]}}], which URL-encoded would be %5B%7B%22name%22%3A%7B%22contains%22%3A%5B%22gourmet%22%5D%7D%7D%5D.

NOTE: "x", "xx", and "xxx" are reserved keywords that, when passed in a contains matcher for a Full or Text filter, will cause that filter to match on all locations.

The filter types are the following. Note there may be multiple available specifications for a given filter type:

Filter Type Syntax Description
Full fieldName: {contains: $search} $search is the search string
Text fieldName: {$type: [$search,...]} $type is one of [contains,doesNotContain,startsWith,equalTo], $search is an array of search strings, combined with OR
Text fieldName: $type $type is one of [empty,notEmpty]
Number fieldName: {$type: $value} $type is one of [eq,lt,gt,le,ge], $value is the numeric value
Number fieldName: {$type: [$value1, $value2]} $type is one of [between], $value1 and $value2 are numeric values
Date fieldName: {$type: $value} $type is one of [eq,lt,gt,le,ge], $value is a string of "YYYY-MM-DD" formatted date
Date fieldName: $type $type is one of [empty,notEmpty]
Date fieldName: {$type: [$value1, $value2]} $type is one of [between], $value1 and $value2 are strings of "YYYY-MM-DD" formatted date
Categories fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of numeric category IDs, combined with OR
Categories fieldName: $type $type is one of [none]
Assets fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of numeric category IDs, combined with OR
Assets fieldName: $type $type is one of [none]
Country fieldName: {$type: [$country,...]} $type is one of [includes,notIncludes], $country is an array of country code strings, combined with OR
PrimaryLanguage fieldName: {$type: [$language,...]} $type is one of [is,isNot], $language is an array of language code strings, combined with OR
AlternateLanguage fieldName: {$type: [$language,...]} $type is one of [includes, notIncludes], $language is an array of language code strings, combined with OR
StringSingle fieldName: {$type: [$string,...]} $type is one of [is,isNot], $string is an array of strings, combined with OR
StringList fieldName: {$type: [$string,...]} $type is one of [includes,notIncludes], $string is an array of strings, combined with OR
LocationType fieldName: {$type: [$id,...]} $type is one of [is,isNot], $id is an array of location type IDs, combined with OR
Bool fieldName: $type $type is one of [true,false]
Option fieldName: {$type: $id} $type is one of [is,isNot], $id is an option ID (For single option custom fields)
Option fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of option IDs, combined with OR (For multi option custom fields)
Folder fieldName: [$id,...] $id is a numeric folder ID
Folder fieldName: $id $id is a numeric folder ID
Folder fieldName: {$type: [$id,...]} $id is a numeric folder ID, $type is one of ['isIn', 'isNotIn']
Labels fieldName: {$type: [$id,...]} $type is one of [includes,notIncludes], $id is an array of label IDs, combined with OR

The following fields can be specified in the request (Field name/Filter Type/Example(s)):

Field Name Filter Type Example(s)
location Full "location": {"contains": "Atlanta"}
name Text "name": {"startsWith": ["Guitar"]}, "name": {"contains": ["A","B"]}
address Text "address": {"startsWith": ["South"]}
address2 Text "address2": {"contains": ["Suite"]}
city Text "city": {"contains": ["Atlanta"]}
state Text "state": {"contains": ["AK","VA"]}
zip Text "zip": {"contains": ["M5K 7QB"]}
phones Text "phones": {"startsWith": ["703","571"]}
specialOffer Text "specialOffer": "notEmpty"
emails Text "emails": {"doesNotContain": ["@yext.com"]}
website Text "website": {"equalTo": ["https://www.yext.com/"]}
categories Categories "categories": {"includes": [23,755,34]}
closed Bool "closed": true
storeId Text "storeId": {"equalTo": ["MCD0001"]}
countryCode Country "countryCode": {"notIncludes": ["US"]}
products Text "products": {"startsWith": ["Burger","Fries"]}
services Text "services": {"contains": ["Manicures"]}
specialities Text "services": "notEmpty"
associations Text "associations": "empty"
brands Text "brands": {"equalTo": ["North Face"]}
languages Text "languages": {"equalTo": ["English","Spanish"]}
keywords Text "keywords": {"startsWith": ["Franchise"]}
menuIds IdList "menuIds": {"includes": ["m-23","755","menu34"]}
productListIds IdList "productListIds": {"notIncludes": ["pl-2"]}
calendarIds IdList "calendarIds": {"notIncludes": ["cal34"]}
bioIds IdList "bioIds": {"includes": ["b23","34"]}
custom### Text (for Multiline Text, URL, Text List, and Text Custom Fields), Number, Date, Bool, or Option "custom123": {"equalTo": ["asdf"]}
folder Folder "folder": 123, "folder": [123,456]
primary_language PrimaryLanguage "primary_language": {"is": "fr_CA"}
alternateProfileLanguage AlternateLanguage "alternateProfileLanguage": {"includes": ["en", "fr"]}
npi StringSingle "npi": {"is": ["1234567890", "1111111111"]}
conditionsTreated Text "conditionsTreated": {"startsWith": ["Influenza"]}, "conditionsTreated": {"contains": ["A","B"]}
lastUpdated Date "lastUpdated": {"eq": "2018-01-01"}, "lastUpdated": {"between": ["2017-01-01", "2018-01-01"]}
fieldsWithData Fields "fieldsWithData": ["email", "hours"]
fieldsWithoutData Fields "fieldsWithoutData": ["logo", "video"]
reviewCount Number "review_count": {"gt": 1}, "review_count ": {"lt": 10}
averageRating Number "averageRating": {"lt": 3}
locationType LocationType "locationType": {"is": [1]}, "locationType": {"isNot": [123]}
gender StringSingle "gender": {"is": ["FEMALE"]}, "gender": {"isNot": ["MALE"]}
degrees StringList "degrees": {"includes": ["MD"]}, "degrees": {"notIncludes": ["PHD"]}
experiences StringList "experiences": {"includes": ["FELLOWSHIP"]}, "experiences": {"notIncludes":["INTERNSHIP"]}
yearCompleted Number "yearCompleted": {"gt": 2000}, "yearCompleted": {"lt": 2015}
acceptingNewPatients Bool "acceptingNewPatients": true
firstName Text "firstName": {"startsWith": ["David"]}, "firstName": {"contains": ["A","B"]}
middleName Text "middleName": {"startsWith": ["P"]}, "middleName": {"contains": ["N","E"]}
lastName Text "lastName": {"startsWith": ["Sm"]}, "lastName": {"contains": ["Y","Z"]}
officeName Text "officeName": {"startsWith": ["Chiropractic"]}, "officeName": {"contains":["Center","P"]}
certifications Text "certifications": {"contains": ["Radiation Oncology"]}
institutionName Text "institutionName": {"startsWith": ["New York"]}
insuranceAccepted Text "insuranceAccepted": {"startsWith": ["United"]}, "insuranceAccepted":{"contains": ["C","Health"]}
admittingHospitals Text "admittingHospitals": {"startsWith": ["Children's"]}, "admittingHospitals":{"contains": ["Medical","University"]}
subscriptions IdList "subscriptions": {"notIncludes": ["123"]}
facebookAccounts IdList "facebookAccounts": {"notIncludes": ["1111"]}
foursquareAccounts IdList "foursquareAccounts": {"notIncludes": ["1111"]}
googleplusAccounts IdList "googleplusAccounts": {"notIncludes": ["1111"]}
labels Labels "labels": {"includes": [1, 100]}
v
required
string

A date in YYYYMMDD format.

sortBy
string

Specifies the fields and direction by which the output should be sorted. Should be provided as a URL-encoded string containing a JSON array of sortDefinition objects. A sortDefinition object consists of a sortField and a sortDirection field. The sortField is the name of the field you are sorting by (e.g., firstName or custom### for a custom field, where "###" is the custom field’s id). The sortDirection indicates whether the sort is ascending (ASCENDING) or descending (DESCENDING).

For example, to sort by last name ascending and first name descending, this parameter would be [{"sortField":"lastName","sortDirection":"ASCENDING"},{"sortField":"firstName", "sortDirection":"DESCENDING"}], which, when URL-encoded, would be %5B%7B%22sortField%22%3A%22lastName%22%2C%22sortDirection%22%3A%22ASCENDING%22%7D%2C%7B%22sortField%22%3A%22firstName%22%2C%22sortDirection%22%3A%22DESCENDING%22%7D%5D.

NOTE: Currently, we support sorting by firstName, lastName, and text custom fields.

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "response": {
    }
}
Feedback