• Introduction
  • Web Service API
  • Callback service
Search Results for

    Show / Hide Table of Contents
    • Overview
    • Concepts
      • API functionality
      • Web Service technology
      • Security
      • Accessing the services
      • Error reporting
      • Synchronous and asynchronous API
      • Testing
      • Telemetry
    • Translation memory API
      • Overview
      • ITMService
      • Lookup, concordance
      • Import, export
      • API
        • ConcordanceRequest
        • GenericFault
        • HeavyResourceInfo
        • HeavyResourceUpdateInfo
        • ImportTMMetadataSchemeResultInfo
        • InlineTagStrictness
        • InvalidSessionIdFault
        • ITMService
        • LookupSegmentRequest
        • NoLicenseFault
        • RequestXmlFormatFault
        • ResourceInfo
        • ResourceListFilter
        • ResourceUpdateInfo
        • ResultInfo
        • TMEngineType
        • TMFault
        • TMInfo
        • TMListFilter
        • TMOptimizationPreference
        • TMUpdateInfo
        • TmxImportResult
        • TmxImportSettings
        • UnauthorizedAccessFault
        • UnexpectedFault
    • Term bases API
      • Overview
      • ITBService
      • Import, export
        • CSV
        • TBX
        • MultiTerm
      • API
        • CreateQTermTBFromTBXSettings
        • CreateQTermTBFromTBXTaskResult
        • CSVExportSettings
        • CSVExportTaskResult
        • CSVImportIntoExistingSettings
        • CSVImportIntoExistingTaskResult
        • CSVImportResult
        • CSVImportSettings
        • GenericFault
        • HeavyResourceInfo
        • HeavyResourceUpdateInfo
        • ITasksService
        • ITBService
        • QTermTBImportSettings
        • ResourceInfo
        • ResourceListFilter
        • ResourceUpdateInfo
        • ResultInfo
        • TaskDoesNotExistFault
        • TaskInfo
        • TaskNotFinishedFault
        • TaskResult
        • TaskStatus
        • TBCaseSensitivity
        • TBCloneInfo
        • TBFilter
        • TBFilterLangMode
        • TBInfo
        • TBMatching
        • TBNewTermDefaultForLanguage
        • TBUpdateInfo
        • TBXExportOptions
        • TBXExportTaskResult
        • TBXImportIntoExistingSettings
        • TBXImportResults
        • TBXImportSettings
        • TBXImportTaskResult
        • UnexpectedFault
    • LiveDocs API
      • Overview
      • ILiveDocsService
      • Alignment
      • API
        • AlignmentOptions
        • AlignmentResultInfo
        • CorpusIndexingOptions
        • CorpusIndexingSchedule
        • CorpusInfo
        • CorpusListFilter
        • CorpusUpdateInfo
        • DocumentForAlignment
        • GenericFault
        • HeavyResourceInfo
        • HeavyResourceUpdateInfo
        • ILiveDocsService
        • ImportBinaryFileIntoLiveDocsOptions
        • ImportFileIntoLiveDocsOptions
        • ImportFileIntoLiveDocsResultInfo
        • ImportLiveDocsXliffFileIntoLiveDocsOptions
        • ImportMonoOrBilingualFileIntoLiveDocsOptions
        • ResourceInfo
        • ResourceListFilter
        • ResourceUpdateInfo
        • ResultInfo
        • ResultStatus
        • UnexpectedFault
    • Light resources API
      • Overview
      • IResourceService
      • API
        • ExpectedFault
        • FilterConfigResourceInfo
        • FilterNames
        • GenericFault
        • IResourceService
        • LightResourceInfo
        • LightResourceInfoWithLang
        • LightResourceListFilter
        • PathRuleResourceInfo
        • PathRuleType
        • ProjectTemplateResourceInfo
        • ResourceInfo
        • ResourceType
        • ResourceUpdateInfo
        • UnexpectedFault
    • Server project API
      • Overview
      • User assignment
      • Omniscien Technologies services
      • IServerProjectService
      • API
        • AddProjectLanguageFault
        • AddProjectLanguageTBHandlingBehavior
        • AggregatedLqaStatistics
        • AnalysisAsCSVResult
        • AnalysisAsCSVResultForLang
        • AnalysisOptions
        • AnalysisReportCounts
        • AnalysisReportForDocument
        • AnalysisReportInfo
        • AnalysisReportItem
        • AnalysisResultForLang
        • AnalysisResultInfo
        • AsiaOnlineBeginTranslationResultInfo
        • AsiaOnlineDomainCombination
        • AsiaOnlineGetDomainCombinationsResultInfo
        • AsiaOnlineGetLanguagePairCodeResultInfo
        • AsiaOnlineGetProjectIdsResultInfo
        • AsiaOnlineTranslateOptions
        • AsiaOnlineTranslationResultInfo
        • AsiaOnlineTranslationStatus
        • AssignmentChangeHistoryItemInfo
        • AutomatedActionStartedHistoryItemInfo
        • AutomatedActionStartedHistoryItemInfo.AutomatedActionTypes
        • AutoSplitJoinSettings
        • BilingualDocFormat
        • CannotStartOperationFault
        • ConfirmAndUpdateDocError
        • ConfirmAndUpdateOptions
        • ConfirmAndUpdateResultInfo
        • ConfirmAndUpdateSegmentStatuses
        • ConfirmAndUpdateTaskResult
        • ConfirmAndUpdateTMBehaviors
        • ConfirmAndUpdateUserNameBehaviors
        • CorpusLanguagePair
        • CreateDeliveryResult
        • CreateStatisticsOnDocumentsRequest
        • CreateStatisticsOnProjectRequest
        • CreateStatisticsRequestBase
        • CsvSeparator
        • CustomPreTranslateParameter
        • DeadlineChangeHistoryItemInfo
        • DeliverDocumentFault
        • DeliverDocumentRequest
        • DistanceMeasurementMode
        • DocDeliveryResult
        • DocDeliveryResultInfo
        • DocumentAssignmentRoleId
        • DocumentBilingualImportHistoryItemInfo
        • DocumentDeliverHistoryItemInfo
        • DocumentExportOptions
        • DocumentHistoryItemInfo
        • DocumentHistoryItemType
        • DocumentHistoryRequest
        • DocumentImportHistoryItemInfo
        • DocumentLqaRejectedSegments
        • DocumentLqaStatistics
        • DocumentReturnHistoryItemInfo
        • DocumentRowsLockedHistoryItemInfo
        • DocumentRowsLockedHistoryItemInfo.LockModes
        • DocumentSlicingHistoryItemInfo
        • DocumentSnapshotCreatedHistoryItemInfo
        • DocumentStatus
        • DocumentXTranslationHistoryItemInfo
        • EditDistanceCsvResult
        • EditDistanceReportInfo
        • EditDistanceStatisticsOptions
        • ExpectedFinalStateAfterXTranslate
        • ExpectedSourceStateBeforeXTranslate
        • FileResultInfo
        • FirstAcceptAcceptHistoryItemInfo
        • FirstAcceptAssignHistoryItemInfo
        • FirstAcceptDeclineHistoryItemInfo
        • FirstAcceptFailedHistoryItemInfo
        • FirstAcceptStatus
        • FirstAcceptUserDecision
        • FragmentAssemblySettings
        • FuzzyEditDistanceReport
        • FuzzyEditDistanceResult
        • FuzzyEditDistanceResultForDocument
        • FuzzyEditDistanceResultForLang
        • FuzzyEditDistanceTaskResult
        • GenericFault
        • GroupSourcingAssignHistoryItemInfo
        • GroupSourcingDocumentDeliverHistoryItemInfo
        • ImportImageLocalizationPackResultInfo
        • ImportTranslationDocumentOptions
        • IServerProjectService
        • LevenshteinEditDistanceReport
        • LevenshteinEditDistanceResult
        • LevenshteinEditDistanceResultForDocument
        • LevenshteinEditDistanceResultForLang
        • LevenshteinEditDistanceTaskResult
        • ListServerProjectTranslationDocument2Options
        • ListServerProjectTranslationDocumentSliceOptions
        • ListTranslationDocumentAssignmentsOptions
        • LockUnlockSegmentsAction
        • LockUnlockSegmentsCondition
        • LockUnlockSegmentsOptions
        • LqaCorrection
        • LqaModelBaseInfo
        • LqaModelStatisticsSummary
        • LqaRejectedSegment
        • LqaRejectedSegmentsOptions
        • LqaRejectedSegmentsReport
        • LqaRejectedSegmentsTaskResult
        • LqaRejection
        • LqaRejectionType
        • LQAResult
        • LqaStatisticsExportFormat
        • LqaStatisticsGenerationOptions
        • LqaStatisticsReport
        • LqaStatisticsTaskResult
        • MatchCoverageType
        • NewRevisionScenarioOptions
        • NumberOfErrorsForSeverity
        • NumberOfErrorsPerSeveritiesForCategory
        • OptionsForAllRowsThatMatchACertainCondition
        • OptionsForRowsInDifferentLanguage
        • PackageContentDocument
        • PackageContentInfo
        • PackageCreationNotAllowedFault
        • PackageDeliveryOptions
        • PackageDeliveryResult
        • PackageDeliveryResultInfo
        • PackageImportOptions
        • PackageInfo
        • PackageType
        • PenaltyPointsForCategory
        • PostTransAnalysisReportForDocument
        • PostTransAnalysisReportForUser
        • PostTransAnalysisReportItem
        • PostTranslationAnalysisAsCSVResult
        • PostTranslationAnalysisAsCSVResultForLang
        • PostTranslationAnalysisOptions
        • PostTranslationAnalysisReportInfo
        • PostTranslationAnalysisResultInfo
        • PostTranslationAnalysisTaskResult
        • PostTranslationReportCounts
        • PostTranslationResultForLang
        • PreparePackageResultInfo
        • PreTransFilter
        • PretranslateCopySourceToTargetBehavior
        • PretranslateCopySourceToTargetConditions
        • PretranslateExpectedFinalTranslationState
        • PretranslateLookupBehavior
        • PretranslateOptions
        • PreTranslateProblem
        • PretranslateStateToConfirmAndLock
        • PreTranslateTaskResult
        • PreviewCreation
        • ProjectLaunchedHistoryItemInfo
        • ProjectLqaStatistics
        • QAReport
        • QAReportForDocument
        • QAReportTypes
        • ReconsolidateDocumentFault
        • ReimportDocumentOptions
        • RenameProjectFault
        • ResultInfo
        • ResultStatus
        • RtfBilingualExportOptions
        • RunQAGetReportOptions
        • RunQATaskResult
        • SegmentStatuses
        • ServerProjectAddLanguageInfo
        • ServerProjectCommunicationSettings
        • ServerProjectConfidentialitySettings
        • ServerProjectCorporaAssignments
        • ServerProjectCreateInfo
        • ServerProjectDesktopDocsCreateInfo
        • ServerProjectInfo
        • ServerProjectListFilter
        • ServerProjectNotificationSettings
        • ServerProjectPackageDetails
        • ServerProjectPackageResourceHandlingOptions
        • ServerProjectResourceAssignment
        • ServerProjectResourceAssignmentDetails
        • ServerProjectResourceAssignmentForResourceType
        • ServerProjectResourcesInPackages
        • ServerProjectRoles
        • ServerProjectStatus
        • ServerProjectTBAssignments
        • ServerProjectTBsForTargetLang
        • ServerProjectTMAssignmentDetails
        • ServerProjectTMAssignmentsForTargetLang
        • ServerProjectTranslationDocBasicInfo
        • ServerProjectTranslationDocInfo
        • ServerProjectTranslationDocInfo2
        • ServerProjectTranslationDocSliceInfo
        • ServerProjectTranslationDocumentsDifferentLanguageTranslations
        • ServerProjectTranslationDocumentsFromSameSourceFile
        • ServerProjectTranslationDocumentUserAssignments
        • ServerProjectTranslationDocumentWorkflowStatusChange
        • ServerProjectUpdateInfo
        • ServerProjectUserInfo
        • ServerProjectUserInfoHeader
        • SetDocumentWorkflowStatusFault
        • SetTranslationDocumentAssignmentsOptions
        • SliceDocumentFault
        • SliceDocumentRequest
        • SlicingMeasurementUnit
        • StatisticsAlgorithm
        • StatisticsOptions
        • StatisticsResultForLang
        • StatisticsResultFormat
        • StatisticsResultInfo
        • StatisticsTaskResult
        • SubvendorAssignDeadlineChangeHistoryItemInfo
        • SubvendorAssignHistoryItemInfo
        • TemplateBasedProjectCreateInfo
        • TemplateBasedProjectCreationFault
        • TemplateBasedProjectCreationInvalidMetaFault
        • TemplateBasedProjectCreationResultInfo
        • TMLanguagePair
        • TranslationDocExportResultInfo
        • TranslationDocImportResultInfo
        • TranslationDocumentAssigneeInfo
        • TranslationDocumentAssignmentFault
        • TranslationDocumentAssignmentInfo
        • TranslationDocumentAssignmentResultInfo
        • TranslationDocumentAssignments
        • TranslationDocumentAssignmentType
        • TranslationDocumentDetailedAssignmentInfo
        • TranslationDocumentDetailedAssignments
        • TranslationDocumentDetailedFirstAcceptAssignmentInfo
        • TranslationDocumentDetailedGroupSourcingAssignmentInfo
        • TranslationDocumentDetailedRoleAssignmentInfo
        • TranslationDocumentDetailedSingleUserAssignmentInfo
        • TranslationDocumentDetailedSubvendorAssignmentInfo
        • TranslationDocumentFirstAcceptAssignmentInfo
        • TranslationDocumentFirstAcceptUserInfo
        • TranslationDocumentGroupSourcingAssignmentInfo
        • TranslationDocumentGroupSourcingUserInfo
        • TranslationDocumentNoUserAssignmentInfo
        • TranslationDocumentRoleAssignmentInfo
        • TranslationDocumentRoleAssignmentResultInfo
        • TranslationDocumentSingleUserAssignmentInfo
        • TranslationDocumentSubvendorAssignmentInfo
        • TranslationDocumentUserRoleAssignment
        • TranslationDocumentUserRoleAssignmentDetails
        • TurnOffAutoPilotFault
        • TwoColumnRtfBilingualExportOptions
        • UnexpectedFault
        • UpdateWithTableRtfOptions
        • UserInfoHeader
        • WordCountMode
        • WorkflowStatus
        • WorkflowStatusChangeHistoryItemInfo
        • WorkingTMsDeletedHistoryItemInfo
        • WrapUpProjectFault
        • XliffBilingualExportOptions
        • XTranslateDocInfo
        • XTranslateDocumentResult
        • XTranslateOptions
        • XTranslateResultInfo
        • XTranslateScenario
        • XTranslateTaskResult
    • Security API
      • Overview
      • Users, groups, permissions
      • Session management
      • ISecurityService
      • API
        • GenericFault
        • GroupInfo
        • ISecurityService
        • ObjectPermission
        • UnexpectedFault
        • UserInfo
        • UserPackageWorkflowType
        • WeakPasswordFault
    • File upload/download API
      • Overview
      • IFileManagerService
      • API
        • GenericFault
        • IFileManagerService
        • UnexpectedFault
    • License (ELM) API
      • Overview
      • IELMService
      • API
        • ELMAssignment
        • ELMAssignmentType
        • ELMFault
        • ELMPermission
        • ELMPoolInfo
        • ELMProduct
        • ELMProjectPermission
        • GenericFault
        • IELMService
        • UnexpectedFault
    • Tasks API
      • Overview
      • ITasksService
      • API
        • GenericFault
        • ITasksService
        • TaskDoesNotExistFault
        • TaskInfo
        • TaskNotFinishedFault
        • TaskResult
        • TaskStatus
        • UnexpectedFault
    • ICR configuration API
      • Overview
      • IIcrConfigService
      • API
        • DefaultDisplayConfig
        • GenericFault
        • IcrConfig
        • IcrConfigCreate
        • IcrConfigMeta
        • IcrResources
        • IcrSettings
        • IIcrConfigService
        • NoLicenseFault
        • QACategoriesConfig
        • QAConfig
        • UnexpectedFault
    • Changelog

    Synchronous and asynchronous operations

    Certain operations may take longer to execute. Such operations are available in both synchronous and asynchronous form. The synchronous form requires the client (i.e. your application) to wait for the end of the action; the call into memoQ Server does not return before the completion. The asynchronous operation queues the requested task, and then returns immediately with a task identifier. The task identifier can be used to poll the status of the task (i.e. if it is ready) and fetch the results of the task (if any).

    Asynchronous operations are new in version 8.3. The operation names look like "Start...Task".

    Asynchronous operations, where available, are favorable to synchronous operations.

    Below is a code sample that demonstrates a typical asynchronous task lifecycle. After starting the operation the task shall be polled for status. Polling should not be too frequent (i.e. less frequent than once every few seconds), and it is recommended to batch multiple pending tasks to poll them together. (The code sample below does not show this batch polling.)

    void StatisticsAsyncTest()
    {
        // ... prepare project, add documents, etc
        IServerProjectService spService = getServerProjectService();
        // ... create options
        StatisticsOptions statOptions = new StatisticsOptions();
        // start async operation
        var statisticsTaskInfo = spService.StartStatisticsOnProjectTask(spGuid,
                                    null, statOptions, StatisticsResultFormat.Html);
        try
        {
            // register async task and poll for status
            var statisticsResult = waitForAsyncTaskToFinishAndGetResult(
                                statisticsTaskInfo.TaskId) as StatisticsTaskResult;
        }
        catch (Exception e) { ... }
    }
    
    private TaskResult waitForAsyncTaskToFinishAndGetResult(Guid TaskId)
    {
        ITasksService taskService = getTasksService();
        var taskStatus = taskService.GetTaskStatus(TaskId).Status;
        int i = 1;
        while (taskStatus != TasksService.TaskStatus.Cancelled
                    && taskStatus != TasksService.TaskStatus.Completed
                    && taskStatus != TasksService.TaskStatus.Failed
                    && taskStatus != TasksService.TaskStatus.InvalidTask)
        {
            if (i < 16)
                i = 2 * i;
            Thread.Sleep(i * 1000);
            taskStatus = taskService.GetTaskStatus(TaskId).Status;
        }
        if (taskStatus != TasksService.TaskStatus.Completed)
            thrownewException($"Task has status {taskStatus.ToString()}.");
        return taskService.GetTaskResult(TaskId);
    }
    
    In This Article
    Back to top WS API documentation