adtec-inventory-comb

1.6.0 • Public • Published

adtec-inventory-comb

Normalize publisher inventory values. This is initially intended to be done for the adition ad server.

Usage

import createInventoryMapping from '@sevenonemedia/adtec-formatdehyd';
 
const mappings = await fetch('https://ad.71.de/config/inventory-mapping.json');
 
const {
    mapFormat,
    mapCategory,
    mapSite,
    mapBrand,
    mapInventory 
  } = createInventoryMapping(mappings);
 
// map a format
const newFormat = mapFormat('k-11-kommissare-im-einsatz')
 
// or why not the whole inventory object
const { newSite, newBrand, newCategory, newFormat } = mapInventory({
  site: 'pro7',
  brand: 'sat1',
  category: 'serien',
  format: 'die-wunderbare-welt-der-tierbabies'
});

/adtec-inventory-comb/

    Package Sidebar

    Install

    npm i adtec-inventory-comb

    Weekly Downloads

    1

    Version

    1.6.0

    License

    ISC

    Unpacked Size

    611 kB

    Total Files

    19

    Last publish

    Collaborators

    • sevenonemedia