Retrieving optimization results

API reference for retrieving optimization results

This section contains API references for the GetOptimizationResults endpoint that retrieves optimization results.

Get optimization results with applied rules

To retrieve optimization results along with all the rules that were applied during the optimization process, use the following endpoint:

postapi.skrym.com/optimization.GetOptimizationResults

This endpoint is useful when you need to understand which optimization and package selection rules influenced the final package recommendations for an order. It traces back through the entire optimization chain, collecting all rules that were applied at each step.

What you get

For each optimization result, you'll receive:

  • Result details: The recommended package, dimensions, weights, and other optimization metadata
  • Applied rules: A complete list of all rules (both optimization rules and package rules) that were applied to produce this result, including:
    • Rule ID and name
    • Rule type (optimization or package)
    • Optional reference information for additional context

Example

You can retrieve results by providing the order reference that was used when the optimization was performed:

{
"externalOrderReference": "ORDER-12345"
}

The response will include all optimization results for that order, each with its complete rule chain.