If I need to restrict my customers to a specific delivery area, let’s say by 1.5 miles or 2.5 miles, how can I identify this area in advance in order to filter them and have a predictable price. Is there any way to get the polygon area from you?
Unfortunately we can’t explicitly provide the distance before an order is placed, but depending on your use case, we have some initial suggestions - though do let us know if the case you had in mind wouldn’t cover this.
The Stuart API has a feature that will give you a pricing quote based on the parameters of the job you create. By calling the get pricing endpoint you will be able to receive a quote that will be the maximum possible price of the job, based on delivery distance, package size and transport type; We have a guide here that should explain in more detail how the pricing operates.
Hopefully this will help with identifying pricing for your customers!
Here is a link to our FAQ page that also outlines this.
In terms of restricting the area for your customers specifically, this is something we would recommend you try and integrate using a third-party service such as the google directions API.
For an easier method, some clients also use straight line distances with a radius slightly smaller than the intended distance to give a “good enough” accuracy
If you have any further questions please let us know!
Thanks Henry for you reply.
Our use case is a marketplace and we need to show the list om merchants only if the user is inside the minimum fee, as you can imagine making an PI request for every merchant while the users browse is not an option.
We’ve already implemented the delivery polygon using the Google APIs and we have it, the only thing is that the area changes according to the transportation way (driving, cycling, walking). Which one should we use in order to be confident that it doesn’t exceed the minimum fee?
The get pricing endpoint will always return the maximum possible price for any given job, this also assumes the most expensive transportation type in this estimation. As detailed in this post here, smaller transportation types may result in a price that is less than the quote.
Whilst you are able to specify transportation type, with it being a required field in France, we do not usually recommend specifying it in the UK and Spanish regions where package type is specified, as this may restrict how many couriers are available for your jobs, depending on your area.
May I ask which countries you plan to operate in? As this may also affect which transport types would also be available.
You can have full confidence that the price will not exceed the quoted price from the get pricing endpoint however.
Given that you operate in the UK we suggest only specifying package type and not transportation type as this could restrict your pool of couriers and impact your overall experience.
Regarding package sizes you can see this post on package and transport type mappings, as this will detail package dimensions and their associated size categories.