---
schema_version: "1"
id: 7126ac6cae59a622040a1cb863b9764b9edafcaa395f1956fdf70ad45d48f858
title: cgcloud__Visit_Template__c
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/retail_api/sforce_api_objects_cgcloud__visit_template__c.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/sforce_api_objects_cgcloud__visit_template__c.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: a131e5d113f562e6b1a25f44010df6681585509c887cc831819b9b635e618c68
description: Template that describes the basic call behavior. This object is available in API version 54.0 and later.
---
# cgcloud\_\_Visit\_Template\_\_c

Template that describes the basic call behavior. This object is available in API version 54.0 and later.

## Supported Calls

create(), delete(), describeLayout(), describeSObjects(), getDeleted(), getUpdated(), query(), retrieve(), search(), undelete(), update(), upsert()

## Fields

### LastReferencedDate

- **Type**: dateTime
- **Properties**: Filter, Nillable, Sort
- **Description**: Most recent date on which a user referenced this record.

### LastViewedDate

- **Type**: dateTime
- **Properties**: Filter, Nillable, Sort
- **Description**: Most recent date on which a user viewed this record.

### Name

- **Type**: string
- **Properties**: Create, Defaulted on create, Filter, Group, idLookup, Nillable, Sort, Update
- **Description**: Unique identification of the record.

### OwnerId

- **Type**: reference
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: ID of the record owner.
    
    This is a polymorphic relationship field.
- **Relationship Name**: Owner
- **Relationship Type**: Lookup
- **Refers To**: Group, User

### cgcloud\_\_Active\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Active flag.
- **Default value**: true

### cgcloud\_\_Add\_Job\_Policy\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether tasks and survey questions can be manually added to visits.
- **Default value**: false

### cgcloud\_\_Auto\_Status\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Visit status set when call will be planned automatically.
- **Default value**: Planned
- **Possible values**:
    - Abandoned
    - Completed
    - Planned

### cgcloud\_\_Cancel\_Reason\_Required\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether the user must provide a reason for visit cancellation.
- **Default value**: false

### cgcloud\_\_Capture\_Proceeding\_Time\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Captures the start and end time of a visit.
- **Default value**: false

### cgcloud\_\_Check\_Overlap\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether to check for overlaps while creating calls. If this option is selected, the system checks if a current visit overlaps with any other visits. Only visits in Planned state are considered.
- **Default value**: false

### cgcloud\_\_Cmpl\_Vst\_Geolc\_Validation\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Specifies the validation type when a user completes a visit, based on the comparison between their GPS location and the geolocation of the store.
- **Default value**: None
- **Possible values**:
    - Error
    - None
    - Warning

### cgcloud\_\_Company\_Required\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Required company details.
- **Default value**: Not required
- **Possible values**:
    - Mandatory
    - Not required

### cgcloud\_\_Consider\_POS\_Check\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: If its value is true, then the Call considers POS in its questions.
- **Default value**: true

### cgcloud\_\_Creation\_Platform\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Creation platform.
- **Default value**: Both
- **Possible values**:
    - Both
    - Laptop
    - Mobility

### cgcloud\_\_Default\_Duration\_\_c

- **Type**: double
- **Properties**: Create, Defaulted on create, Filter, Sort, Update
- **Description**: Visit default duration in minutes.

### cgcloud\_\_Delete\_Allowed\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether a visit can be deleted using a mobile device.
- **Default value**: false

### cgcloud\_\_Description\_Language\_1\_\_c

- **Type**: string
- **Properties**: Create, Filter, Group, Nillable, Sort, Update
- **Description**: Stores the description of language 1.

### cgcloud\_\_Description\_Language\_2\_\_c

- **Type**: string
- **Properties**: Create, Filter, Group, Nillable, Sort, Update
- **Description**: Stores the description of language 2.

### cgcloud\_\_Description\_Language\_3\_\_c

- **Type**: string
- **Properties**: Create, Filter, Group, Nillable, Sort, Update
- **Description**: Stores the description of language 3.

### cgcloud\_\_Description\_Language\_4\_\_c

- **Type**: string
- **Properties**: Create, Filter, Group, Nillable, Sort, Update
- **Description**: Stores the description of language 4.

### cgcloud\_\_Description\_\_c

- **Type**: string
- **Properties**: Filter, Nillable, Sort
- **Description**: Reference to the description based on the user-specified language.
    
    This is a calculated field.
- **Formula**:
    
    CASE($User.cgcloud\_\_Language\_Postfix\_\_c,
          "Language1", cgcloud\_\_Description\_Language\_1\_\_c,
          "Language2", BLANKVALUE(cgcloud\_\_Description\_Language\_2\_\_c,cgcloud\_\_Description\_Language\_1\_\_c),
          "Language3", BLANKVALUE(cgcloud\_\_Description\_Language\_3\_\_c,cgcloud\_\_Description\_Language\_1\_\_c),
          "Language4", BLANKVALUE(cgcloud\_\_Description\_Language\_4\_\_c,cgcloud\_\_Description\_Language\_1\_\_c),
          cgcloud\_\_Description\_Language\_1\_\_c)

### cgcloud\_\_Display\_Promotions\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether valid promotions for the customer selected for a visit creation are shown in the Promotions tab of the Visit Detail page.
- **Default value**: false

### cgcloud\_\_Does\_Show\_Read\_Only\_Visit\_Info\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Determines whether the users sees an information message that indicates that the visit hasn’t started and is in read-only mode.
- **Default value**: false

### cgcloud\_\_Historical\_Products\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Determines whether and how historical products are considered when determining the list of products to be surveyed in a visit.
- **Default value**: No
- **Possible values**:
    - All
    - No
    - SameMeta—Same Template

### cgcloud\_\_Is\_Start\_Visit\_Rqr\_To\_Check\_In\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Determines whether a user needs to start a visit before visit execution.
- **Default value**: false

### cgcloud\_\_KPI\_Relevant\_\_c

- **Type**: multipicklist
- **Properties**: Create, Filter, Nillable, Restricted picklist, Update
- **Description**: Defines whether a call is relevant for KPI calculation for the selected KPIs.
- **Possible values**:
    - All—All KPIs

### cgcloud\_\_Limit\_To\_One\_Visit\_In\_Progress\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Prevent users from executing multiple visits at the same time.
- **Default value**: false

### cgcloud\_Location\_Capture\_at\_Start\_\_C

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates if a user’s GPS location is captured at the start of a visit. This field applies only to Direct Store Delivery and Van Sales processes.
- **Default value**: false

### cgcloud\_\_Loc\_Capture\_During\_Cancel\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether the user's GPS location is recorded during visit cancellation.
- **Default value**: false

### cgcloud\_\_Loc\_Capture\_During\_Complete\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether the GPS location of the user is captured at visit completion.
- **Default value**: false

### cgcloud\_\_Max\_Pictures\_\_c

- **Type**: double
- **Properties**: Create, Filter, Nillable, Sort, Update
- **Description**: Maximum number of pictures.

### cgcloud\_\_Meta\_Type\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Defines another level of abstraction - categorizes templates into template templates. For example, is it a template for a Call, a Delivery Visit, a Van Sales, a Merchandising, a Service, or a Phone.
- **Default value**: Call
- **Possible values**:
    - Call
    - DeliveryVisit—Delivery Visit
    - Merchandising
    - Phone
    - Service
    - VanSales—Van Sales

### cgcloud\_\_Mobility\_Color\_\_c

- **Type**: picklist
- **Properties**: Create, Filter, Group, Nillable, Sort, Update
- **Description**: Field that defines the color of call on a mobility device.
- **Possible values**:
    - 003344—ink blue
    - 008899—sea green 2
    - 20B2AA—light sea green
    - 467596—grey blue
    - 551155—red violet
    - 6495ED—corn flower blue
    - 6688BB—periwinkle blue
    - 77AA99—sage green
    - 87CEEB—sky blue
    - 87CEFA—light sky blue
    - 8FBC8F—dark seagreen
    - AA1133—cranberry red
    - ADD8E6—light blue
    - B0C4DE—light steel blue
    - BBBB00—lime green 2
    - BC8F8F—rosy brown
    - D1DDEC—sky blue 2
    - DAA520—golden rod
    - DD4411—dark orange
    - DDECD1—turquoise 2
    - E9967A—dark salmon
    - EE9B38—yellow orange
    - EED2E0—plum
    - F08080—light coral
    - F4A460—sandy brown
    - F7EBD9—khaki 2
    - FA8072—salmon
    - FF7F50—coral
    - FFA07A—light salmon
    - FFD700—gold

### cgcloud\_\_Mobility\_Relevant\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether a visit created can be executed using mobile devices.
- **Default value**: false

### cgcloud\_\_Mobility\_User\_Guidance\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Process navigation (user guidance) that is used on mobility devices.
- **Default value**: Sales
- **Possible values**:
    - Delivery
    - Merchandizing
    - NonCustomer
    - Sales

### cgcloud\_\_Promotion\_Finding\_Lead\_Time\_\_c

- **Type**: double
- **Properties**: Create, Filter, Nillable, Sort, Update
- **Description**: Number of days that specifies future time range for finding of planned promotions.

### cgcloud\_\_Sales\_Org\_\_c

- **Type**: picklist
- **Properties**: Create, Filter, Group, Nillable, Restricted picklist, Sort, Update
- **Description**: Defines the Sales Organization in which the template can be used.
- **Possible values**:
    - 0000
    - 0001
    - 0002
    - 0003

### cgcloud\_\_Sort\_\_c

- **Type**: double
- **Properties**: Create, Filter, Nillable, Sort, Update
- **Description**: On Selection of visit template (For example, when creating a new visit): Defines the order of the templates.

### cgcloud\_\_Start\_Vst\_Geolc\_Validation\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Specifies the validation type when a user starts a visit, based on the comparison between their GPS location and the geolocation of the store.
- **Default value**: None
- **Possible values**:
    - Error
    - None
    - Warning

### cgcloud\_\_Sync\_Options\_\_c

- **Type**: picklist
- **Properties**: Create, Defaulted on create, Filter, Group, Nillable, Sort, Update
- **Description**: Defines when a visit based on this template will be synced automatically:
- **Default value**: No
- **Possible values**:
    - CancelCall
    - CompleteCall
    - CompleteCancelCall
    - No

### cgcloud\_\_Tag\_Media\_Date\_Time\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether date and time of media captured during visit execution on mobile devices is stored.
- **Default value**: false

### cgcloud\_\_Tag\_Media\_Geo\_Location\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates whether GPS coordinates of media captured during visit execution on mobile devices is stored.
- **Default value**: false

### cgcloud\_\_Update\_Planned\_Times\_\_c

- **Type**: boolean
- **Properties**: Create, Defaulted on create, Filter, Group, Sort, Update
- **Description**: Indicates if the Start or End datetimes and duration of the visit should be set
- **Default value**: false

### cgcloud\_\_User\_Roles\_\_c

- **Type**: multipicklist
- **Properties**: Create, Filter, Nillable, Update
- **Description**: User roles that are assigned to the Order Template. **Note**: Ensure that the master picklist values exactly match the technical name of the permission sets. Select the user value in translation. For example, if CGCloud\_Master\_Data\_Admin is the master picklist value, then Master Data Admin is the translated value.
- **Possible values**:
    - CGCloud\_KAM—KAM
    - CGCloud\_Master\_Data\_Admin—Master Data Admin
    - CGCloud\_Retail\_Admin—Retail Admin
    - CGCloud\_Sales\_User—Sales User
    - CGCloud\_Security\_Admin—Security Admin
    - CGCloud\_Supervisor—Supervisor
    - CGCloud\_Tour\_User

## Associated Objects

### Associated Objects

This object contains these associated objects. If the API version isn’t specified, they are available in the same API versions as this object. Otherwise, they are available in the specified API version and later.

- **[cgcloud\_\_Visit\_Template\_\_cChangeEvent](https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/sforce_api_associated_objects_change_event.htm "A ChangeEvent object is available for each object that supports Change Data Capture. You can subscribe to a stream of change events using Change Data Capture to receive data tied to record changes in Salesforce. Changes include record creation, updates to an existing record, deletion of a record, and undeletion of a record. A change event isn’t a Salesforce object—it doesn’t support CRUD operations or queries. It’s included in the object reference so you can discover which Salesforce objects support change events.")**: Change events are available for the object.
- **[cgcloud\_\_Visit\_Template\_\_cFeed](https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/sforce_api_associated_objects_feed.htm "StandardObjectNameFeed is the model for all feed objects associated with standard objects. These objects represent the posts and feed-tracked changes of a standard object.")**: Feed tracking is available for the object.
- **[cgcloud\_\_Visit\_Template\_\_cHistory](https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/sforce_api_associated_objects_history.htm "StandardObjectNameHistory is the model for all history objects associated with standard objects. These objects represent the history of changes to the values in the fields of a standard object.")**: History is available for the tracked fields of the object.
- **[cgcloud\_\_Visit\_Template\_\_cOwnerSharingRule](https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/sforce_api_associated_objects_ownersharingrule.htm "StandardObjectNameOwnerSharingRule is the model for all owner sharing rule objects associated with standard objects. These objects represent a rule for sharing a standard object with users other than the owner.")**: Sharing rules are available for the object.
- **[cgcloud\_\_Visit\_Template\_\_cShare](https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/sforce_api_associated_objects_share.htm "StandardObjectNameShare is the model for all share objects associated with standard objects. These objects represent a sharing entry on the standard object.")**: Sharing is available for the object.