Optimizer Version Activation - Documentation
The Optimizer Version Activation API function can be used as a SOAP web service by using Salesforce Standard functionality.
1. SOAP web service
The needed licenses for this are:
API_USAGE
BILLING_AND_ACCOUNTING
1.1. URL
https://<my-domain-name>.my.salesforce.com/services/Soap/package/ADvendio/OptimizerVersionActivation
1.2. Method
POST
1.3. Header Params
Content-Type: text/xml; charset=UTF-8
SOAPAction: ""
Accept: text/xml
1.4. Body Params
The soap xml envelope with the attribute access-token and the action, containing the ID of the relevant Optimizing Version.
Example:
<se:Envelope xmlns:se="http://schemas.xmlsoap.org/soap/envelope/">
<se:Header xmlns:sfns="http://soap.sforce.com/schemas/package/ADvendio/OptimizerVersionActivation">
<sfns:SessionHeader>
<sessionId>{{access-token}}</sessionId>
</sfns:SessionHeader>
</se:Header>
<se:Body>
<activateOptimizerVersion xmlns="http://soap.sforce.com/schemas/package/ADvendio/OptimizerVersionActivation">
<optimizingVersionId>a1p3E000004RXFHQA4</optimizingVersionId>
</activateOptimizerVersion>
</se:Body>
</se:Envelope>
1.5. Success Response
Code: 200
Content: The response can be seen below. In case of an error, the error messages are part of the response as well.
The Optimizer Version Activation API function can be used as a SOAP web service by using Salesforce Standard functionality.
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns="http://soap.sforce.com/schemas/package/ADvendio/OptimizerVersionActivation" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body>
<activateOptimizerVersionResponse>
<result xsi:nil="true"/>
</activateOptimizerVersionResponse>
</soapenv:Body>
</soapenv:Envelope>
Usage in APEX:
String errorString = ADvendio.OptimizerVersionActivation.activateOptimizerVersion(Id optimizingVersionId)