Skip to content

Unable to create Audio VAST redirect Creatives #803

Description

@gchicoye

Hi,

I'm struggling creating Audio VAST redirect creative.

The function creating a Google\AdsApi\AdManager\v202411\VastRedirectCreative is as follows

$size = new Size();
  $size->setWidth($width);
  $size->setHeight($height);
  $size->setIsAspectRatio(false);
  
  $creative = new VastRedirectCreative();

// $creative->setName($name . ' - Audio ' .$width . 'X' . $height) 
  $creative->setName('Audio Creative - Audio 1x1 - TEST')
->setAdvertiserId($this->order->getAdvertiserId())
->setVastXmlUrl($snippet)
->setDuration(1000)
->setSize($size)
      ->setIsAudio(true)
      ->setVastRedirectType(VastRedirectType::LINEAR);
  return $creative;

This creates the following object, sent through API

object(Google\AdsApi\AdManager\v202411\VastRedirectCreative)#72 (20) {
  ["advertiserId":protected]=>
  int(5759434305)
  ["id":protected]=>
  NULL
  ["name":protected]=>
  string(33) "Audio Creative - Audio 1x1 - TEST"
  ["size":protected]=>
  object(Google\AdsApi\AdManager\v202411\Size)#84 (3) {
    ["width":protected]=>
    int(1)
    ["height":protected]=>
    int(1)
    ["isAspectRatio":protected]=>
    bool(false)
  }
  ["previewUrl":protected]=>
  NULL
  ["policyLabels":protected]=>
  NULL
  ["appliedLabels":protected]=>
  NULL
  ["lastModifiedDateTime":protected]=>
  NULL
  ["customFieldValues":protected]=>
  NULL
  ["thirdPartyDataDeclaration":protected]=>
  NULL
  ["adBadgingEnabled":protected]=>
  NULL
  ["vastXmlUrl":protected]=>
  string(48) "https://cypher-deezer.doubleclick.net/deal-audio"
  ["vastRedirectType":protected]=>
  string(6) "LINEAR"
  ["duration":protected]=>
  int(1000)
  ["companionCreativeIds":protected]=>
  NULL
  ["trackingUrls":protected]=>
  NULL
  ["vastPreviewUrl":protected]=>
  NULL
  ["sslScanResult":protected]=>
  NULL
  ["sslManualOverride":protected]=>
  NULL
  ["isAudio":protected]=>
  bool(true)
}

However, the API returns me


object(Google\AdsApi\AdManager\v202411\VastRedirectCreative)#98 (20) {
  ["advertiserId":protected]=>
  int(5759434305)
  ["id":protected]=>
  int(138507646241)
  ["name":protected]=>
  string(26) "Audio Creative - Audio 1x1"
  ["size":protected]=>
  object(Google\AdsApi\AdManager\v202411\Size)#133 (3) {
    ["width":protected]=>
    int(1)
    ["height":protected]=>
    int(1)
    ["isAspectRatio":protected]=>
    bool(false)
  }
  ["previewUrl":protected]=>
  NULL
  ["policyLabels":protected]=>
  NULL
  ["appliedLabels":protected]=>
  NULL
  ["lastModifiedDateTime":protected]=>
  object(Google\AdsApi\AdManager\v202411\DateTime)#86 (5) {
    ["date":protected]=>
    object(Google\AdsApi\AdManager\v202411\Date)#95 (3) {
      ["year":protected]=>
      int(2025)
      ["month":protected]=>
      int(2)
      ["day":protected]=>
      int(17)
    }
    ["hour":protected]=>
    int(9)
    ["minute":protected]=>
    int(29)
    ["second":protected]=>
    int(49)
    ["timeZoneId":protected]=>
    string(19) "America/Los_Angeles"
  }
  ["customFieldValues":protected]=>
  NULL
  ["thirdPartyDataDeclaration":protected]=>
  NULL
  ["adBadgingEnabled":protected]=>
  bool(false)
  ["vastXmlUrl":protected]=>
  string(48) "https://cypher-deezer.doubleclick.net/deal-audio"
  ["vastRedirectType":protected]=>
  string(6) "LINEAR"
  ["duration":protected]=>
  int(1000)
  ["companionCreativeIds":protected]=>
  NULL
  ["trackingUrls":protected]=>
  NULL
  ["vastPreviewUrl":protected]=>
  string(268) "http://partner.googleadservices.com/gampad/ads?gct=_amSq-f3wg8KYIoYXSpWCAUQJEoAUjBodHRwczovL2N5cGhlci1kZWV6ZXIuZG91YmxlY2xpY2submV0L2RlYWwtYXVkaW-4AaHqy_2DBPACAfgCAZADAfADAuoEAjABmggCEgDKAQJAARja5829BigAMNqDg8UGOABYAXCN5M29Bg&iu=22331957889&gdfp_req=1&output=xml_vast2"
  ["sslScanResult":protected]=>
  string(9) "UNSCANNED"
  ["sslManualOverride":protected]=>
  string(11) "NO_OVERRIDE"
  ["isAudio":protected]=>
  bool(false)
}

Any idea?

Thanks!

Gabriel

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions