node package manager
Loosely couple your services. Use Orgs to version and reuse your code. Create a free org »

@tremorvideo/blink-cli

@tremorvideo/blink-cli

definition of manifest.json

There should be only one MediaFile. However IAB VAST Standard does not prevent multiple MediaFile.

{
  "mediaFiles": [
    {
      "id": "CU-12345",
      "delivery": "progressive",
      "type": "application/javascript",
      "bitrate": 466,
      "width": 640,
      "height": 480,
      "maintainAspectRatio": true,
      "scalable": true,
      "apiFramework": "VPAID",
      "uri": "https://s.tremorvideodsp.com/SGAI12345/vpaid.js"
    }
  ],
  "videos": {
    "video-1": {
      "url": "https://s.tremorvideodsp.com/1.mp4",
      "type": "video/mp4",
      "duration": "15000"
    },
    "video-2": {
      "url": "https://s.tremorvideodsp.com/2.mp4",
      "type": "video/mp4",
      "duration": "15000"
    }
  },
  "mainVideo": "video-1",
  "tvCustomEvents": [
    {
      "name": "Click_Walgreens",
      "uri": true,
      "thirdPartyPixels": true
    },
    {
      "name": "Click_Video_Close",
      "uri": false,
      "thirdPartyPixels": true
    },
    {
      "name": "Slate_Opened",
      "uri": false,
      "thirdPartyPixels": true
    }
  ]
}

Output

<VAST xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="vast2.xsd" version="2.0.0">
  <Ad id="BC0">
    <InLine>
      <AdSystem>Tremor Video</AdSystem>
      <AdTitle>Tremor Video</AdTitle>
      <Impression>
        <![CDATA[https://s.tremorvideodsp.com/?e=impression]]>
      </Impression>
      <Creatives>
        <Creative>
          <Linear>
            <Duration>00:00:15</Duration>
            <AdParameters>
              <![CDATA[
                {
                  "geoInfo": {
                    "dma": "501",
                    "city": "new york",
                    "areaCode": "212",
                    "latitude": "40.75891",
                    "longitude": "73.97902",
                    "continent": "north america",
                    "countryCode": "us",
                    "stateCode": "95",
                    "postalCode": "10020"
                  },
                  "tvCustomEvents: [
                    {
                      "name": "Click_Walgreens",
                      "uri": "https://s.tremorvideodsp.com/1x1.png?r=wg",
                      "thirdPartyPixels": [
                        "https://s.tremorvideodsp.com/1x1.png?e=click_wg1",
                        "https://s.tremorvideodsp.com/1x1.png?e=click_wg2"
                      ]
                    },
                    {
                      "name": "Slate_Opened",
                      "thirdPartyPixels": [
                        "https://s.tremorvideodsp.com/1x1.png?e=open1"
                      ]
                    }
                  ]
                }
              ]]>
            </AdParameters>
            <TrackingEvents>
              <Tracking event="start">
                <![CDATA[https://s.tremorvideodsp.com/1x1.png?e=start]]>
              </Tracking>
              <Tracking event="midpoint">
                <![CDATA[https://s.tremorvideodsp.com/1x1.png?e=midpoint]]>
              </Tracking>
              <Tracking event="acceptInvitation">
                <![CDATA[https://s.tremorvideodsp.com/1x1.png?e=acceptInvitation]]>
              </Tracking>
            </TrackingEvents>
            <VideoClicks>
              <ClickThrough>
                <![CDATA[https://example.com]]>
              </ClickThrough>
              <ClickTracking>
                <![CDATA[https://s.tremorvideodsp.com/1x1.png?e=clicked]]>
              </ClickTracking>
            </VideoClicks>
            <MediaFiles>
              <MediaFile id="CU-12345" delivery="progressive" bitrate="466" width="640" height="480" type="application/javascript" maintainAspectRatio="true" scalable="true" apiFramework="VPAID">
                <![CDATA[https://s.tremorvideodsp.com/SGAI12345/vpaid.js]]>
              </MediaFile>
            <MediaFiles>
          </Linear>
        </Creative>
      </Creatives>
    </InLine>
  </Ad>
</VAST>

commands

  • blink init spr downloads an spr
  • blink manifest generates a .manifest file
  • blink stats gives you statistics of the current working directory
  • blink doctor recommends how to fix
  • blink up upload and transcode video files, then update manifest.json
  • blink serve runs http server and open window