Ad Entity Routes

These routes use 'revenue' rather than 'ads' to avoid being block by ads blockers

Get all ads of type by publication

GET

/api/revenue/{type}/{publication}

Passthrough to Drupal API:

/api/ads/{type}/{publication}

type must match Drupal bundle type for the flowz_ad entity
available types used by CMS:\

  • ad_config
  • premium_ad
  • premium_letter

Get ad by id

GET

/api/revenue/{id}

Passthrough to Drupal API:

/flowz_ad/ads/{id}?_format=json

Create new Ad

POST

/api/revenue

Passthrough to Drupal API:

/entity/flowz_ad?_format=json

Update Ad by id

PATCH

/api/revenue/{id}

Passthrough to Drupal API:

/flowz_ad/ads/{id}?_format=json

Delete Ad by id

PATCH

/api/revenue/{type}/{id}

Passthrough to Drupal API:

/flowz_ad/ads/{id}?_format=json

type is included here for potential future callbacks that may require this information.