Step 2: Custom Account Configuration

To create an account with customized properties, you may supply your own configuration file.

As an example, run the following command like so:

    yext accounts create test-account-config.toml

Example Config File:

    name = "Test Account"
    accountType = "DIAGNOSTIC"
    country = "US"
    language = "en"
    defaultLocationType = "LOCATION"
    parentBusinessId = "69878"
    productFeatures = ["FACEBOOK_EXPORT", "PHOTO_DETAILS_FIELD", "PHOTO_CROPPING", "ZUORA_ACCOUNT"]
    
    [users.OWNER]
    firstName = "Test"
    lastName = "User"
    emailPrefix = "testUser"
    password = "<PASSWORD>"
    
    [[acl.OWNER]]
    roles = ["FULL_CONTROL"]
    
    [users.someUser]
    firstName = "Other"
    lastName = "User"
    emailPrefix = "otherUser"
    password = "<PASSWORD>"
    
    [[acl.someUser]]
    roles = ["LOCATION_VIEWER"]
    
    [templateLocations.LOC_]
    count = "2"
    template = "test_basic_location"
    
    [categories]
    ALL = ["1113"]
    
    [subscriptionFeatures]
    LOC_0 = ["DIGITAL_ASSET_MANAGEMENT", "YELP", "FOURSQUARE_POWERLISTINGS"]
    ALL = ["LIVE_API"]

The configuration files must be in TOML format, and the following fields are supported. Note: Subscription and Product Features are ignored in the production environment.

Supported Fields

Field Name Field Type
name String
accountType String
country String
language String
defaultLocationType String
parentBusinessId String
productFeatures List<String>
productFeaturesToExclude List<String>
users Map User >
acl Map Acl >>
approvalsGroups Map>
entitySuggestedEdits List< EntitySuggestedEdit >
entities List< Entity >
templateLocations Map TemplateLocation >
locations Map Location >
folders List<Folder>
labels List<String>
categories Map>
subscriptionFeatures Map>
social Social
reviews List< Review >
questions List< Question >
approvalsSettings ApprovalSettings

Entity

Field Name Field Type
key String
type String
country String
locale String
folderKey String
fields Map

TemplateLocation

Field Name Field Type
count String
template String

Location

Field Name Field Type
name String
address String
address2 String
city String
state String
postalCode String
country String
locale String
emails List<String>
description String
specialOffer SpecialOffer
urls List< Url >
phones List< Phone >

Special Offer

Field Name Field Type
description String
url String
isDefault String

Url

Field Name Field Type
url String
displayUrl String
type String
preferDisplayUrl String

Phone

Field Name Field Type
number String
type String
isTracked String

Folder

Field Name Field Type
key String
name String
children List< Folder >

User

Field Name Field Type
firstName String
lastName String
emailPrefix String
password String
usernamePrefix String

Acl

Field Name Field Type
roles List<String>
location String
entity String

Social

Field Name Field Type
posts List< SocialPost >

SocialPost

Field Name Field Type
message String
locations List<String>

Review

Field Name Field Type
numReviews int
publisherId int
quarantined boolean

Question

Field Name Field Type
numQuestions int
publisherId int

ApprovalsSettings

Field Name Field Type
enabled String
replyToAddress String
notifySubmitters String
notifyGroups String
lockingEnabled String
attachmentsEnabled String
versioningEnabled String

EntitySuggestedEdit

Field Name Field Type
fieldId String
entityKey String
submitterUserKey String
sourcePublisherId String
suggestedFields Map