Services Estimator API Developer Reference

ffscpq.CreateScopingSessionService

global with sharing class CreateScopingSessionService

A service that provides functionality related to creating scoping sessions.

Methods

createScopingSession

global static ffscpq.CreateScopingSessionService.CreateScopingSessionResponse createScopingSession(ffscpq.CreateScopingSessionService.CreateScopingSessionRequest request)

A method that creates a scoping session.

Input Parameters

Name Type Description
request ffscpq.CreateScopingSessionService.CreateScopingSessionRequest CreateScopingSessionRequest.

Return Value

This service returns a CreateScopingSessionResponse.

Sample Code

//Note: This sample code is for demonstration purposes only. It is not intended for
//use in a production environment, is not guaranteed against defects or errors, and
//is in no way optimized or streamlined.

// Add opportunity ID to populate lookup on the created scoping session.
Id opportunityId = '006DR00000KhTNYYA3';

// Build request
CreateScopingSessionService.CreateScopingSessionRequest request = new CreateScopingSessionService.CreateScopingSessionRequest(
    opportunityId
);

// Optionally add a list of estimate product IDs to add to the created scoping session.
request.EstimateProductIds = new List<Id>{ 'a5FDR000001Qpxt2AC' };

// Optionally add a name to the created scoping session.
request.Name = 'Scoping Session created using global service';

// Call the global service with the previously created request list.
CreateScopingSessionService.CreateScopingSessionResponse response = CreateScopingSessionService.createScopingSession(
    request
);

// Extract the response data.
System.debug('Created Scoping session ID: ' + response.ScopingSession);
System.debug(
    'Created Scoping Session Estimate Product IDs: ' + response.ScopingSessionEstimateProductIds
);

ffscpq.CreateScopingSessionService.CreateScopingSessionRequest

global with sharing class CreateScopingSessionRequest

The request structure for creating a scoping session.

Properties

Name Type Description
OpportunityId Id An opportunity ID associated with the created scoping session.
EstimateProductIds List<Id> [Optional] The estimate products to add to the created scoping session.
Name String [Optional] The name of the created scoping session.

Methods

CreateScopingSessionRequest

global CreateScopingSessionRequest(Id opportunityId)

ffscpq.CreateScopingSessionService.CreateScopingSessionResponse

global with sharing class CreateScopingSessionResponse

The response structure for creating a scoping session.

Properties

Name Type Description
ScopingSession Id The ID of the newly created scoping session.
ScopingSessionEstimateProductIds List<Id> The IDs of the estimate products added to the created scoping session.

Methods

CreateScopingSessionResponse

global CreateScopingSessionResponse(Id scopingSessionId, List<Id> ScopingSessionEstimateProductIds)

© Copyright 2009–2025 Certinia Inc. All rights reserved. Various trademarks held by their respective owners.