Presence
Get diffusion errors for a business
Get diffusion errors for a given business.
This endpoint returns diffusion errors grouped by publisher. Diffusion errors are classified into two types:
- Pre-check errors: errors detected before sending data to partners, based on the current business data.
- Post-check errors: errors detected after sending data to partners, based on partner responses.
Behavior
- If no input parameters are provided:
- Returns the existing pre-check and post-check errors stored in the database.
- If input parameters are provided:
- Applies the provided fields as an in-memory update on the business (without persisting).
- Recalculates pre-check errors based on these changes.
- Post-check errors are not recalculated in this case.
Example Use Case
Use this endpoint during a business edit form to validate which publishers would be affected by a change, without saving it yet.
post/diffusion_errors/{business_id}
Path parameters
business_idstring required
Business id.
It may be replaced by c-{code} where code is the store code, which should be unique per organization. This can be used only for ORG_ADMIN, GROUP_MANAGER and BUSINESS_MANAGER users.
Request body
Example request
{
"name": "Corner shop",
"org_id": 42,
"country": "FR",
"zipcode": "75019",
"city": "Paris",
"region": "Ile-de-France",
"categories": [
"gcid:restaurant",
"gcid:fast_food_restaurant",
"gcid:hamburger_restaurant"
],
"code": "CS-75019",
"status": "open",
"address_full": "12 bis rue du coquelicot",
"manual_lat": -3.585993,
"manual_long": 47.870341,
"lat": -3.585993,
"long": 47.870341,
"website_url": "https://www.corner-shop.co/",
"facebook_url": "https://www.facebook.com/the-corner-shop",
"twitter_url": "https://www.twitter.com/the-corner-shop",
"description_short": "lorem ipsum",
"description_long": "lorem ipsum dolor sit amet",
"open_hours": {
"monday": [
"10:00-14:00"
],
"tuesday": [
"10:00-14:00"
],
"wednesday": [
"10:00-14:00"
],
"thursday": [
"10:00-14:00"
],
"friday": [
"10:00-14:00"
],
"saturday": [
"10:00-14:00"
],
"sunday": [
"10:00-14:00"
]
},
"specific_hours": {
"open": [
{
"starts_at": "2020-01-20",
"ends_at": "2020-01-20",
"open_hours": [
"10:00-14:00"
]
}
],
"close": [
{
"starts_at": "2020-01-20",
"ends_at": "2020-01-22"
}
]
},
"contacts": [
{
"name": "Hubert Bonisseur de la Bath",
"email": "hubert@oss117.fr",
"phone_numbers": [
"+33302060628"
],
"fax": "+33302060629"
}
]
}Response
OK