Skip to main content

Articles

Add

Once the campaign is created, you must add the list of the articles to which it applies.

POST /me/campaigns/:campaignId/articles HTTP/1.1
Accept: application/vnd.aplazame.v1+json
Authorization: Bearer api_private_key
Host: api.aplazame.com
[
{
"id": "89793238462643383279",
"name": "Reloj en oro blanco de 18 quilates y diamantes",
"description": "Movimiento de cuarzo de alta precisión",
"url": "http://www.chanel.com/fragrance-beauty/Fragrance-N05-88145/sku/138083",
"image_url": "http://www.chanel.com/fragrance-beauty/Fragrance-N05-88145/sku/138083/product_01.jpg"
},
{
"id": "59825349042875546873",
"name": "Nº5 eau premiere spray",
"description": "A decidedly lighter, fresher...",
"url": "http://www.chanel.com/fragrance-beauty/Fragrance-N05-88145/sku/138083",
"image_url": "http://www.chanel.com/fragrance-beauty/Fragrance-N05-88145/sku/138083/product_01.jpg"
}
]
ParameterTypeRequiredDescription
idstringYesArticle id.
namestringYesArticle name.
descriptionstringNoArticle description.
urlURLYesArticle absolute URL.
image_urlURLNoArticle image absolute URL.

Response

HTTP/1.1 204 NO CONTENT
Content-Type: application/vnd.aplazame.v1+json

Delete

Individual deletion of an article included in a campaign.

DELETE /me/campaigns/:campaignId/articles/:articleId HTTP/1.1
Accept: application/vnd.aplazame.v1+json
Authorization: Bearer api_private_key
Host: api.aplazame.com

Response

HTTP/1.1 204 NO CONTENT
Content-Type: application/vnd.aplazame.v1+json

Delete all

if you do not include the article id in the URL, all campaign articles are referenced.

DELETE /me/campaigns/:campaignId/articles HTTP/1.1
Accept: application/vnd.aplazame.v1+json
Authorization: Bearer api_private_key
Host: api.aplazame.com

Response

HTTP/1.1 204 NO CONTENT
Content-Type: application/vnd.aplazame.v1+json

List

GET /me/campaigns/:campaignId/articles?page=2 HTTP/1.1
Accept: application/vnd.aplazame.v1+json
Authorization: Bearer api_private_key
Host: api.aplazame.com

Response

HTTP/1.1 200 OK
Content-Type: application/json
{
"cursor": {
"after": 3,
"before": 1
},
"paging": {
"count": 314,
"next": "https://api.aplazame.com/me/campaigns/:campaignId/articles?page=3",
"previous": "https://api.aplazame.com/me/campaigns/:campaignId/articles?page=1"
},
"results": [
]
}
ParameterTypeDescription
cursorobjectPagination cursor object
pagingobjectPagination status
resultscollectionList of campaigns