Skip to main content

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent”></a> Interface ISelectionAgent

Namespace: SuperOffice.WebApi.Agents
Assembly: SuperOffice.WebApi.dll
Selections, entities, members and tasks

Implements

IAgentBase, IDisposable

Methods

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_AddContactSelectionMembersAsync_System_Int32_SuperOffice_WebApi_Data_ContactPersonId___SuperOffice_WebApi_RequestOptions_”></a> AddContactSelectionMembersAsync(int, ContactPersonId[], RequestOptions)

Adds the collection of ContactPersonId as members to the static selection

Parameters

selectionId int The id of the selection where to members will be added to. contactPersonIds ContactPersonId[] A collection of ContactPersonId to add to the selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_AddContactSelectionMembersFromSearchAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> AddContactSelectionMembersFromSearchAsync(int, string, RequestOptions)

Adds members to the selection from the search result.

Parameters

selectionId int The id of the selection to add members storageKey string Storage key to be interpreted by the restriction storage provider, when it fetches criteria for the search requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<int&gt; Number of members added

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_AddRemoveContactSelectionMemberInterestsAsync_System_Int32_System_Int32___System_Int32___System_Int32___System_Int32___SuperOffice_WebApi_RequestOptions_”></a> AddRemoveContactSelectionMemberInterestsAsync(int, int[], int[], int[], int[], RequestOptions)

Adds or removes interests on companies and persons in a selection.

Parameters

selectionId int The id of the selection to add or remove interests members from. addCompanyInterests int[] Array of int containing the id’s of the interests to add to the company. removeCompanyInterests int[] Array of int containing the id’s of the interests to remove from the company. addContactInterests int[] Array of int containing the id’s of the interests to add to the contact. removeContactInterests int[] Array of int containing the id’s of the interests to remove from the contact. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_AddSelectionMembersAsync_System_Int32_System_Int32___SuperOffice_WebApi_RequestOptions_”></a> AddSelectionMembersAsync(int, int[], RequestOptions)

Add selection members to a static selection of type others than contacts.

Parameters

selectionId int The selection id to add the members to. ids int[] Collection of ids to add to the selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<int&gt; Returns number of members added to the selection.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_AddSelectionMembersFromSearchAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> AddSelectionMembersFromSearchAsync(int, string, RequestOptions)

Adds members from the selection using the search result.

Parameters

selectionId int The id of the selection to add members storageKey string Storage key to be interpreted by the restriction storage provider, when it fetches criteria for the search requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<int&gt; Number of members added.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CopyContactSelectionMembersAsync_System_Int32_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> CopyContactSelectionMembersAsync(int, int, RequestOptions)

Copy contact selection members from selection into an existing selection.

Parameters

fromSelectionId int The id of the selection to copy members from. toSelectionId int The id of the selection to copy members to. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CopySelectionMembersAsync_System_Int32_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> CopySelectionMembersAsync(int, int, RequestOptions)

Copy selection members from selection into an existing selection.

Parameters

fromSelectionId int The id of the selection to copy members from. toSelectionId int The id of the selection to copy members to. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateContactSelectionFromSelectionAsync_System_Int32_System_String_SuperOffice_WebApi_Data_SelectionType_System_Boolean_SuperOffice_WebApi_RequestOptions_”></a> CreateContactSelectionFromSelectionAsync(int, string, SelectionType, bool, RequestOptions)

Creates a new selection based on selection members from an existing selection.

Parameters

selectionId int The id of the selection to copy members from. name string The name of the new selection. targetSelectionType SelectionType The type of ContactSelection to create. The type can be static or dynamic. If the original selection to copy from is static, the SelectionType can only be static. If the original selection is dynamic, both a static and dynamic selection can be created. copyMembers bool If true, the members from the original selection will be added to the newly created selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; Returns the newly created SelectionEntity.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateContactSelectionFromShadowSelectionAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> CreateContactSelectionFromShadowSelectionAsync(int, string, RequestOptions)

Creates a new contact selection based on contact selection members from an existing shadow sale, appointment, project or document selection. The new selection will always be static even if the original selection is dynamic.

Parameters

selectionId int The id of the selection to copy members from. name string The name of the new selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; Returns the newly created SelectionEntity.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateDefaultBoardViewSettingsFromEntityTypeAsync_SuperOffice_WebApi_Data_BoardViewEntityType_SuperOffice_WebApi_RequestOptions_”></a> CreateDefaultBoardViewSettingsFromEntityTypeAsync(BoardViewEntityType, RequestOptions)

Creates a new carrier from the entity type given, with the right kind of properties, defaults set.

Parameters

entityType BoardViewEntityType Entity type to create settings for requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<BoardViewSettingsBase&gt;

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateDefaultSelectionEntityAsync_SuperOffice_WebApi_RequestOptions_”></a> CreateDefaultSelectionEntityAsync(RequestOptions)

Set default values into a new SelectionEntity. NetServer calculates default values on the entity, which is required when creating/storing a new instance

Parameters

requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; A blank SelectionEntity

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateNewEntryAsync_SuperOffice_WebApi_Data_DuplicateEntry_SuperOffice_WebApi_RequestOptions_”></a> CreateNewEntryAsync(DuplicateEntry, RequestOptions)

Creates a new selection based on external duplicate

Parameters

duplicate DuplicateEntry The duplicate to create a new entry based upon requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<int&gt; The database identity of the newly created entry

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateSelectionEntityAsync_System_String_SuperOffice_WebApi_RequestOptions_”></a> CreateSelectionEntityAsync(string, RequestOptions)

Create (but do not save) a new selection entity, for the current user and the given target table; other fields populated as by CreateDefaultSelectionEntity()

Parameters

targetTableName string The name of the target table, such as ‘contact’ or ‘appointment’; any table for which Selection functionality is enabled requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; The new SelectionEntity, which has not yet been saved

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateSelectionFromSelectionAsync_System_Int32_System_String_SuperOffice_WebApi_Data_SelectionType_System_Boolean_SuperOffice_WebApi_RequestOptions_”></a> CreateSelectionFromSelectionAsync(int, string, SelectionType, bool, RequestOptions)

Creates a new selection based on selection members from an existing selection.

Parameters

selectionId int The id of the selection to copy members from. name string The name of the new selection. targetSelectionType SelectionType The type of Selection to create. The type can be static or dynamic. If the original selection to copy from is static, the SelectionType can only be static. If the original selection is dynamic, both a static and dynamic selection can be created. copyMembers bool If true, the members from the original selection will be added to the newly created selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; Returns the newly created SelectionEntity.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateTemporaryContactSelectionAsync_SuperOffice_WebApi_RequestOptions_”></a> CreateTemporaryContactSelectionAsync(RequestOptions)

Creates a temporary selection.

Parameters

requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; Returns the newly created SelectionEntity.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateTemporaryContactSelectionFromContactPersonIdsAsync_SuperOffice_WebApi_Data_ContactPersonId___SuperOffice_WebApi_RequestOptions_”></a> CreateTemporaryContactSelectionFromContactPersonIdsAsync(ContactPersonId[], RequestOptions)

Creates a temporary selection with members from a collection of ContactPerson id’s.

Parameters

contactPersonIds ContactPersonId[] A collection of ContactPersonId to copy into the temporary contact selection as members. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; Returns the newly created SelectionEntity.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateTemporaryContactSelectionFromSelectionMemberIdsAsync_System_Int32_System_Int32___SuperOffice_WebApi_RequestOptions_”></a> CreateTemporaryContactSelectionFromSelectionMemberIdsAsync(int, int[], RequestOptions)

Creates a temporary selection with members from a collection of selectionmember id’s.

Parameters

selectionId int The selectionId the selectionmembers is a part of. selectionMemberIds int[] A collection of int ids to copy into the temporary contact selection as members. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; Returns the newly created SelectionEntity.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_CreateTemporarySelectionFromIdsAsync_System_Int32___System_Int32_SuperOffice_WebApi_RequestOptions_”></a> CreateTemporarySelectionFromIdsAsync(int[], int, RequestOptions)

Creates a temporary selection with members from a collection of entity id’s.

Parameters

ids int[] A collection of Ids to copy into the temporary selection as members. The ids are primary keys of entities defined by the targetTableNumber parameter. targetTableNumber int The type of selection to create. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; Returns the newly created SelectionEntity.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_DeleteBoardViewSettingsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> DeleteBoardViewSettingsAsync(int, RequestOptions)

Delete BoardViewSettings

Parameters

boardViewSettingsId int Primary key of BoardViewSettings requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task This method has no return value

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_DeleteContactsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> DeleteContactsAsync(int, RequestOptions)

Deletes all contacts from a selection. If a contact does not have delete rights, it will be skipped.

Parameters

selectionId int Id of the selection the delete operation will be performed. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_DeleteEntitiesAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> DeleteEntitiesAsync(int, RequestOptions)

Deletes all entities from a selection. If an entity does not have delete rights, it will be skipped.

Parameters

selectionId int Id of the selection the delete operation will be performed. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_DeletePersonsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> DeletePersonsAsync(int, RequestOptions)

Deletes all persons from a selection. If a person does not have delete rights, it will be skipped.

Parameters

selectionId int Id of the selection the delete operation will be performed. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_DeleteSelectionEntityAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> DeleteSelectionEntityAsync(int, RequestOptions)

Deletes the SelectionEntity

Parameters

selectionEntityId int The identity of the SelectionEntity requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task This method has no return value

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_EditContactSelectionMemberDetailsAsync_System_Int32_SuperOffice_WebApi_Data_SelectionMemberEditValues_SuperOffice_WebApi_RequestOptions_”></a> EditContactSelectionMemberDetailsAsync(int, SelectionMemberEditValues, RequestOptions)

Edit company and contact details in a selection based on contents in selectionMemberEditValues.

Parameters

selectionId int The id of the selection to edit members from. selectionMemberEditValues SelectionMemberEditValues An object of <see cref=“SelectionMemberEditValues”/> describing what should be changed for companys and contacts. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_ExportSelectionMembersAsync_System_Int32_System_String_System_Boolean_SuperOffice_WebApi_RequestOptions_”></a> ExportSelectionMembersAsync(int, string, bool, RequestOptions)

ExportSelectionMembers will generate a string that is the result of substituting the template variables with values from selectionmembers.

Parameters

selectionId int The id of the selection to generate the exported file. templateName string The templateName parameter is the relative path of a .sxf file template. The .sxf files can be found in \template or in the user folder of the so archive. useContacts bool If the selection contains other members than contacts, setting this to true will export the contact archive of the selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<byte[]&gt; Returns a unicode byte array with the file to export to the user.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_ExportSelectionMembersWithOrderByAsync_System_Int32_System_String_System_Boolean_System_String_SuperOffice_WebApi_RequestOptions_”></a> ExportSelectionMembersWithOrderByAsync(int, string, bool, string, RequestOptions)

ExportSelectionMembers will generate a string that is the result of substituting the template variables with values from selectionmembers.

Parameters

selectionId int The id of the selection to generate the exported file. templateName string The templateName parameter is the relative path of a .sxf file template. The .sxf files can be found in \template or in the user folder of the so archive. useContacts bool If the selection contains other members than contacts, setting this to true will export the contact archive of the selection. orderBy string OrderBy. <Column,OrderBySortType> requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<byte[]&gt; Returns a unicode byte array with the file to export to the user.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GenerateFollowUpsAsync_System_Int32_SuperOffice_WebApi_Data_AppointmentEntity_System_Int32_System_Boolean_System_Boolean_SuperOffice_WebApi_RequestOptions_”></a> GenerateFollowUpsAsync(int, AppointmentEntity, int, bool, bool, RequestOptions)

Generate follow-ups for members in the selection.

Parameters

selectionId int The id of the selection to generate the follow-ups for. appointmentEntity AppointmentEntity The AppointmentEntity with information about the appointment. associateId int The associate to save the appointments on. If saveOnContactOwner is true, this id will be ignored. Appointments wil be saved on current user if associateId = 0. saveOnContactOwner bool If true, the appointments will be saved on contact owner (Our contact). This parameter will override associateId if true. uniqueContact bool If true, only one appointment will be created for each contact. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetBoardViewSettingsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetBoardViewSettingsAsync(int, RequestOptions)

Get BoardViewSettings by ID

Parameters

boardViewSettingsId int Primary key of BoardViewSettings requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<BoardViewSettingsBase&gt; The settings, of appropriate sub type

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetBoardViewSettingsForSelectionAsync_System_Int32_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetBoardViewSettingsForSelectionAsync(int, int, RequestOptions)

Get BoardViewSettings by associate id and selection id

Parameters

associateId int Id of associate selectionId int Id of selection requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<BoardViewSettingsBase&gt; The settings, of appropriate sub type

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetDuplicateRulesAsync_SuperOffice_WebApi_RequestOptions_”></a> GetDuplicateRulesAsync(RequestOptions)

Retrieve all available duplicate rules for selection

Parameters

requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DuplicateRule[]&gt; All available duplicate rules

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetDuplicatesAsync_System_String_SuperOffice_WebApi_RequestOptions_”></a> GetDuplicatesAsync(string, RequestOptions)

Get duplicates(exact or similar in the database) based on the name

Parameters

name string Name used for lookup requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<DuplicateEntry[]&gt; Any records matching the specified name

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetDynamicSelectionCriteriaAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetDynamicSelectionCriteriaAsync(int, RequestOptions)

Get the criteria for this dynamic selection.

Parameters

selectionId int The id of the selection to add members requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveRestrictionInfo[]&gt; Criteria defining the selection result. NULL if selection does not exist, or if this is not a dynamic selection.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetDynamicSelectionCriteriaGroupsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetDynamicSelectionCriteriaGroupsAsync(int, RequestOptions)

Get the criteria for this dynamic selection. This call supports multiple criteria groups.

Parameters

selectionId int The id of the selection to add members requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveRestrictionGroup[]&gt; Criteria groups defining the selection result. NULL if selection does not exist, or if this is not a dynamic selection.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetParentCombinedSelectionsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetParentCombinedSelectionsAsync(int, RequestOptions)

Get a list of all selection ids where the given selection is used to create a combined selection.

Parameters

selectionId int The selectionId to query for. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<int[]&gt; Array of selectionIds.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetRecipientStatisticsAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetRecipientStatisticsAsync(int, RequestOptions)

Returns a RecipientStatistics object with a count of addresses, emailaddresses and emailaddresses.

Parameters

selectionId int The id of the selection to get the statistics for. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<RecipientStatistics&gt; Returns a RecipientStatistics object.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetRecipientStatisticsFromContactPersonIdsAsync_SuperOffice_WebApi_Data_ContactPersonId___SuperOffice_WebApi_RequestOptions_”></a> GetRecipientStatisticsFromContactPersonIdsAsync(ContactPersonId[], RequestOptions)

Returns a RecipientStatistics object with a count of addresses, emailaddresses and emailaddresses based on contact and persons in a collection of ContactPersonId.

Parameters

contactPersonIds ContactPersonId[] A collection of ContactPersonId to get the statistics for. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<RecipientStatistics&gt; Returns a RecipientStatistics object.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetRecipientStatisticsFromProjectMembersAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetRecipientStatisticsFromProjectMembersAsync(int, RequestOptions)

Returns a RecipientStatistics object with a count of addresses, emailaddresses and emailaddresses based on members in a project.

Parameters

projectId int The id of the project to get the member statistics for. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<RecipientStatistics&gt; Returns a RecipientStatistics object.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetSelectionEntityAsync_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetSelectionEntityAsync(int, RequestOptions)

Gets a specific SelectionEntity object.

Parameters

selectionEntityId int The identifier of the SelectionEntity object requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; SelectionEntity

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetSelectionForFindAsync_System_String_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> GetSelectionForFindAsync(string, int, RequestOptions)

Obtain a selection for the given entity, for the current user, of type WorkingSetForFind. Optionally populate criteria from the TypicalSearches system

Parameters

entityName string The name of the entity to make a selection for; examples ‘sale’, ‘project’, ‘y_equipment’ typicalSearchId int If 0, keep existing criteria; if -1, reset to entity default; > 0 get criteria from given TypicalSearch requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionForFind&gt; Target selection id and provider name

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetSelectionMembersArchiveRowsAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> GetSelectionMembersArchiveRowsAsync(int, string, RequestOptions)

Get the list of members in this selection. The type of members depends on the target table of the selection.

Parameters

selectionId int The selectionId we want selection members for. select string (optional) Comma separated Column names to include in result. List of columns varies depending on the selection’s TargetTable. e.g. ‘name’, ‘firstname’, ‘startTime’ requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveListItem[]&gt; Array of archive rows, where each item represents one row of data (row level data + the requested columns). NULL if selection does not exist.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetSelectionShadowMembersArchiveRowsAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> GetSelectionShadowMembersArchiveRowsAsync(int, string, RequestOptions)

Get the list of members in this selection’s shadow (i.e. the list of contacts + persons referenced in the main selection).

Parameters

selectionId int The selectionId we want selection members for. select string (optional) Comma separated Column names to include in result. List of columns varies depending on the selection’s TargetTable. e.g. ‘name’, ‘firstname,name’, ‘startTime,firstname,name’ requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveListItem[]&gt; Array of archive rows, where each item represents one row of data (row level data + the requested columns). NULL if selection does not exist.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_GetSelectionSummariesAsync_System_Int32___SuperOffice_WebApi_RequestOptions_”></a> GetSelectionSummariesAsync(int[], RequestOptions)

Get an array of summaryitem for the given selections

Parameters

selectionIds int[] The selections to fetch summaries for requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionSummaryItem[]&gt; Summary items for the given id’s, in no particular order

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_RemoveContactSelectionMembersAsync_System_Int32_SuperOffice_WebApi_Data_ContactPersonId___SuperOffice_WebApi_RequestOptions_”></a> RemoveContactSelectionMembersAsync(int, ContactPersonId[], RequestOptions)

Removes members from the selection as specified in the collection of ContactPersonId.

Parameters

selectionId int The id of the selection where to members will be removed. contactPersonIds ContactPersonId[] A collection of ContactPersonId to remove from the static selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_RemoveContactSelectionMembersFromIdsAsync_System_Int32_System_Int32___SuperOffice_WebApi_RequestOptions_”></a> RemoveContactSelectionMembersFromIdsAsync(int, int[], RequestOptions)

Removes members from the selection using a collection a selectionmember id’s. Members can only be removed from single selection.

Parameters

selectionId int The id of the selection where to members will be removed. selectionMembersIds int[] An array of selectionmember id’s to remove from the selection. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_RemoveContactSelectionMembersFromSearchAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> RemoveContactSelectionMembersFromSearchAsync(int, string, RequestOptions)

Removes members from the selection using the search result.

Parameters

selectionId int The id of the selection to remove members. storageKey string Storage key to be interpreted by the restriction storage provider, when it fetches criteria for the search. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<int&gt; Number of members removed

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_RemoveSelectionMembersAsync_System_Int32_System_Int32___SuperOffice_WebApi_RequestOptions_”></a> RemoveSelectionMembersAsync(int, int[], RequestOptions)

Removes members from the selection as specified in the collection of entity ids. The ids are selection member ids (selection member primary key)

Parameters

selectionId int The id of the selection where to members will be removed. selectionMemberIds int[] Selection member primary keys requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_RemoveSelectionMembersByIdAsync_System_Int32_System_Int32___SuperOffice_WebApi_RequestOptions_”></a> RemoveSelectionMembersByIdAsync(int, int[], RequestOptions)

Removes members from the selection as specified in the collection of entity ids. The ids can be a collection of sale ids, or other supported types.

Parameters

selectionId int The id of the selection where to members will be removed. ids int[] A collection of sale/project/contact ids to remove from the selection. The ids can be a collection of sale ids, or other supported types. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_RemoveSelectionMembersFromSearchAsync_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> RemoveSelectionMembersFromSearchAsync(int, string, RequestOptions)

Removes members from the selection using the search result.

Parameters

selectionId int The id of the selection to remove members. storageKey string Storage key to be interpreted by the restriction storage provider, when it fetches criteria for the search. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<int&gt; Number of members removed

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SaveBoardViewSettingsAsync_SuperOffice_WebApi_Data_BoardViewSettingsBase_SuperOffice_WebApi_RequestOptions_”></a> SaveBoardViewSettingsAsync(BoardViewSettingsBase, RequestOptions)

Save BoardViewSettings

Parameters

boardViewSettings BoardViewSettingsBase Typed BoardViewSettings carrier object requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<BoardViewSettingsBase&gt; The settings, of appropriate sub type

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SaveBoardViewSettingsForSelectionAndAssociateAsync_SuperOffice_WebApi_Data_BoardViewSettingsBase_System_Int32_System_Int32_SuperOffice_WebApi_RequestOptions_”></a> SaveBoardViewSettingsForSelectionAndAssociateAsync(BoardViewSettingsBase, int, int, RequestOptions)

Save BoardViewSettings on the given selection/associate

Parameters

boardViewSettings BoardViewSettingsBase Typed BoardViewSettings carrier object associateId int Id of associate selectionId int Id of selection requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<BoardViewSettingsBase&gt; The settings, of appropriate sub type

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SaveSelectionEntityAsync_SuperOffice_WebApi_Data_SelectionEntity_SuperOffice_WebApi_RequestOptions_”></a> SaveSelectionEntityAsync(SelectionEntity, RequestOptions)

Updates the existing SelectionEntity or creates a new SelectionEntity if the id parameter is 0.

Parameters

selectionEntity SelectionEntity The SelectionEntity that is saved. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<SelectionEntity&gt; New or updated SelectionEntity

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SetDuplicateRulesStatusAsync_SuperOffice_WebApi_Data_DuplicateRule___SuperOffice_WebApi_RequestOptions_”></a> SetDuplicateRulesStatusAsync(DuplicateRule[], RequestOptions)

Set which duplicate rules should be active or not

Parameters

rules DuplicateRule[] Duplicate rules to update active status for requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SetDynamicSelectionCriteria2Async_System_Int32_System_String_SuperOffice_WebApi_RequestOptions_”></a> SetDynamicSelectionCriteria2Async(int, string, RequestOptions)

Update the criteria for this dynamic selection using string. Criteria are parsed from the OData filter form: ”name startswith ‘foo’ and category in (1,2,3)”

Parameters

selectionId int The id of the selection to add members filter string Criteria defining the selection result in OData filter form: category in (1,2,3) and name = 'foo' requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveRestrictionInfo[]&gt; Criteria defining the selection result. NULL if this is not a dynamic selection.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SetDynamicSelectionCriteria3Async_System_Int32_SuperOffice_WebApi_Data_ArchiveRestrictionInfo___System_String_SuperOffice_WebApi_RequestOptions_”></a> SetDynamicSelectionCriteria3Async(int, ArchiveRestrictionInfo[], string, RequestOptions)

Update the criteria for this dynamic selection. Use criteria as either restriction objects or OData string format. Criteria are parsed from the OData filter form: ”name startswith ‘foo’ and category in (1,2,3)”

Parameters

selectionId int The id of the selection to add members criteria ArchiveRestrictionInfo[] Criteria defining the selection result. Pass NULL if using the filter string instead. filter string Criteria defining the selection result in OData filter form: category in (1,2,3) and name = 'foo'. Pass NULL or empty string ” if using the criteria objects. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveRestrictionInfo[]&gt; Criteria defining the selection result. NULL if this is not a dynamic selection.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SetDynamicSelectionCriteriaAsync_System_Int32_SuperOffice_WebApi_Data_ArchiveRestrictionInfo___SuperOffice_WebApi_RequestOptions_”></a> SetDynamicSelectionCriteriaAsync(int, ArchiveRestrictionInfo[], RequestOptions)

Update the criteria for this dynamic selection. Replaces existing criteria with the new values.

Parameters

selectionId int The id of the selection to add members criteria ArchiveRestrictionInfo[] Criteria defining the selection result. requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveRestrictionInfo[]&gt; Criteria defining the selection result. NULL if this is not a dynamic selection.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_SetDynamicSelectionCriteriaGroupsAsync_System_Int32_SuperOffice_WebApi_Data_ArchiveRestrictionGroup___SuperOffice_WebApi_RequestOptions_”></a> SetDynamicSelectionCriteriaGroupsAsync(int, ArchiveRestrictionGroup[], RequestOptions)

Update the criteria for this dynamic selection. Replaces existing criteria with the new values. This call supports multiple criteria groups.

Parameters

selectionId int The id of the selection to add members criteria ArchiveRestrictionGroup[] Criteria groups defining the selection result. Empty array is legal, simply means no criteria have been set requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<ArchiveRestrictionGroup[]&gt; Criteria groups defining the selection result. NULL if this is not a dynamic selection.

<a id=“SuperOffice_WebApi_Agents_ISelectionAgent_UpdateTypicalSearchAsync_SuperOffice_WebApi_Data_TypicalSearches_SuperOffice_WebApi_RequestOptions_”></a> UpdateTypicalSearchAsync(TypicalSearches, RequestOptions)

Update (import) TypicalSearch information in the database

Parameters

searches TypicalSearches TypicalSearch structures to import. If null, then the fileset is scanned for *TypicalSearch.json files and those are imported instead requestOptions RequestOptions Override language/culture codes on this request.

Returns

Task<string&gt; Message that can be shown to the user, summarizing what has been done, if anything.