vGrubs
API Docs
vgrubs.com

Sync Schedule

You call vGrubs
POSThttps://sandbox.vgrubs.com/partner/sync-schedule/{webhookPath}
{webhookPath} Your webhook path segment - the partner identifier provisioned during onboarding.

Asks vGrubs to send a store's current working hours and closing days to your integration again.

Use it after connecting a store, once the store is saved on your side, or any time you need a fresh copy of the schedule - for example a previous webhook failed, or the store was re-created on your side.

The endpoint is asynchronous. vGrubs responds right away and sends the schedule webhooks to your base URL right after the response.

Authenticate with the x-api-key header, or with Authorization: Bearer <your API key>. Send one of the two.
success: true means the request was accepted and the sync has started. It does not confirm that your endpoints received the webhooks.
The menu is not included. Use Publish Menu (POST /partner/publish-menu/{webhookPath}) for the menu.
The production URL is provided by vGrubs once the integration is fully tested and ready to go live.

Request body

merchant_idstringrequired

Store ID, the same value used when connecting.

Responses

200OK
errorboolean

false when the request was handled successfully.

dataobject

Result of the sync request.

messagestring / null

null on success; the error message otherwise.

400Bad Request

Invalid body, schedule sync disabled for your integration, or no store matching merchant_id. See the error messages below.

401Unauthorized

Missing or invalid API key, or wrong webhook path.

Webhooks you will receive

After responding, vGrubs calls your integration with your x-api-key. The payloads are identical to the ones vGrubs already sends when a store's schedule changes.

WebhookSent when
POST {your_base_url}/merchants/working-hoursWorking hours sync is enabled for your integration and the store has working hours set. Contains the full business_hours and delivery_hours.
POST {your_base_url}/merchants/closing-daysClosing days sync is enabled for your integration and the store has upcoming closing days (today or later, in the store's time zone). Sent with action: add.

If there is nothing to send (no working hours, no upcoming closing days), no webhook is sent and the response is still 200.

Error messages

All errors use the same shape: { "error": true, "message": "..." }.

StatusMessageCause
401UnauthorizedMissing or invalid API key, or wrong webhook path
400merchant_id should not be emptymerchant_id is missing or empty
400merchant_id must be a stringmerchant_id is not a string
400Schedule sync is not enabled for this provider.Neither working hours sync nor closing days sync is enabled for your integration
400Provided is not connected with storeId: {merchant_id}.No store is connected with this merchant_id
400Store with ID {merchant_id} is missing brand mapping.The connection exists but is not linked to a store