Save Product in Campaign - celdotro/marketplace GitHub Wiki

About

  • Allows a product to be added to a campaign with a custom promotional price that doesn't keep into account the campaign's discount

Class

celmarket\Campaigns\CampaignsEdit

Method

saveProduct

API

  • method: campaign
  • action: saveProduct

Parameters

  • numecampanie = campaign's name
  • model = product's model
  • promo = promotional price

Response

An object with the following attributes

  • message = Produsul a fost adaugat -> successfully added, Produsul nu a fost adaugat -> failed to add the product

Example - PHP

https://github.com/celdotro/marketplace_examples/blob/master/Campaigns/5.saveProduct.php

Example - JSON

{
  "request": {
   "numecampanie": "X",
   "model": "X",
   "promo": 1 
  },
  
  "response": {
    "message": "Produsul a fost adaugat"
  }
}
⚠️ **GitHub.com Fallback** ⚠️