Skrym LogoPre- vs Post-payment

Pre- vs Post-payment

Pre- and Post-Payment Optimization API reference

Here you can find information about the pre- or post-payment endpoints.

Pre-payment

The pre-payment endpoint always checks and validates that the provided product data is correct and usable before continuing. Incase the validation fails, the endpoint returns a 400 for failing product validation or a 500 for any internal error that may have occurred.

Using the product data Skrym optimizes the packing of the products and splits the products into multiple packages if needed.

postapi.skrym.com/core.OptimizePrePayment

Post-payment

Basic

The post-payment endpoint always checks and validates that the provided order and product data is correct and usable before continuing. Incase the validation fails, the endpoint returns a 400 for failing product validation or a 500 for any internal error that may have occurred.

Using the product data Skrym optimizes the packing of the products and splits the products into multiple packages if needed.

Warning

You can re-trigger the optimization by using the same ID. This will override the old result which will affect some statistics and analytics.

Advanced

Skrym fetches the available transport methods and matches them to the chosen transport method for the calling retailer. Skrym then calculates a route between the given sender and receiver using the transport terminals available, resulting in a route and a transportation distance. If the call fails at this point Skrym replies with a partially successful result containing just the package recommendation.

The transport distance, optimized package(s) and vehicle selection data are used to calculate the emissions of the given route for each package(s) in the order.

Using the transport agreement, package information and the chosen transport method, shipping cost including additional fees and penalty fees are calculated. The transport method is validated to ensure that delivery is possible through the chosen means.

postapi.skrym.com/core.OptimizePostPayment