AmbireTech/adex-market

/units-for-slot: return basic issues

Opened this issue · 0 comments

Return issues from the /units-for-slot route, as they're specified in #101

  • if campaignsActive.length is 0, do a .count() on campaigns with the same query but w/o depositAsset, and depending on that return NO_ACTIVE_CAMPAIGNS or NO_DEPOSITASSET_CAMPAIGNS
  • if all of the campaigns don't have units with the proper type, add NO_UNITS_FOR_SIZE
  • if the slot has no acceptedReferrers.length, add SLOT_NOT_VERIFIED

Tagging this with ux because using that, we'd be able to inform publishers why they don't get any ads.