Getting quotes outside operating hours

I have a website that used the Stuart API to get prices for deliveries and displays them to the customer.

However the nature of the business means that evens when we are closed we could be taking orders for the following day.

In the location we are using stuart it runs up until 23:00… is it possible to get a quote after this time?

Hi @ayo.adesina,

You can request pricing and even create orders at any time, but the scheduled time of the order must be within our operational hours. This means that it you’re creating instant orders (which are the default where the driver should come to the pickup asap) then you can expect to receive an error if the time that this request is made is outside of our operational hours (e.g. 23:00 in this case).

If you are creating scheduled orders by providing the ‘pickup_at’ timestamp value, so long as the scheduled time is in our operational hours then the request will succeed (assuming the validity of the full request payload).

Ok so I can schedule a job, but how can I get a quote for a job, as soon as it turns 23:00 my code can no longer get prices.

Hi @ayo.adesina,

The pricing endpoint should validate jobs in the same way as the create a job endpoint, If you have any examples of these pricing failures that you think should have succeeded we’d be happy to look into them further.

Taking a quick look into your accounts pricing request failures in our logs it looks like the reason is usually “job_distance_not_allowed”