{"metadata":{"image":[],"title":"","description":""},"api":{"url":"/v1/campaigns?offset=1&limit=3&name=\"my campaign\"","auth":"required","examples":{"codes":[{"language":"curl","code":"curl --include --header \"X-Api-Key: YOUR_API_KEY\" https://api.pushapps.mobi/v1/campaigns?offset=0&limit=10"}]},"method":"get","params":[{"name":"offset","type":"int","default":"0","desc":"result offset, sorted by launch date in descending order","required":false,"in":"query","ref":"","_id":"56e7df1c5dc7db22001fcc22"},{"name":"limit","type":"int","default":"50","desc":"maximum amount of campaigns to return","required":false,"in":"query","ref":"","_id":"56e7df1c5dc7db22001fcc21"},{"name":"name","type":"string","default":"","desc":"search phrase for filtering name. simple \"contains\" search without regex. default value is all names","required":false,"in":"query","ref":"","_id":"56e7df1c5dc7db22001fcc20"}],"results":{"codes":[{"language":"json","status":200,"name":"","code":"{\n  \"campaigns\": [\n    {\n      \"id\": \"2Vl3Jhd5\",\n      \"name\": \"My cool campaign\",\n      \"is_default\": true,\n      \"created_at\": 1458132510000\n    },\n    {\n      \"id\": \"nQj6FzZb\",\n      \"name\": \"External content campaign\",\n      \"is_default\": false,\n      \"created_at\": 1458132374000\n    },\n    {\n      \"id\": \"6GREryTL\",\n      \"name\": \"Testing campaign\",\n      \"is_default\": false,\n      \"created_at\": 1458132316000\n    }\n  ]\n}"}]},"settings":""},"next":{"description":"","pages":[]},"title":"/campaigns - view campaigns","type":"endpoint","slug":"campaigns","excerpt":"View the details of the active campaigns of your application","body":"result is an array with the key `campaigns`:\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Field\",\n    \"h-1\": \"Type\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"**id**\",\n    \"0-1\": \"string\",\n    \"1-0\": \"**name**\",\n    \"2-0\": \"**status**\",\n    \"3-0\": \"**is_default**\",\n    \"4-0\": \"**created_at**\",\n    \"1-1\": \"string\",\n    \"2-1\": \"string\",\n    \"3-1\": \"boolean\",\n    \"4-1\": \"number\",\n    \"h-3\": \"\",\n    \"0-2\": \"the id of the campaign, you need to use this id in other endpoints that take campaign id\",\n    \"1-2\": \"display name of the campaign\",\n    \"2-2\": \"current status, possible values:\\n* `active`\\n* `disabled`\",\n    \"3-2\": \"if this is `true`, this is the default campaign. meaning that, when a mobile device will ask for enrichment with `campaign_id` = `default` . this campaign will be used\",\n    \"4-2\": \"the create date of the campaign in unix timestamp in [ms]\",\n    \"0-3\": \"\",\n    \"1-3\": \"\",\n    \"2-3\": \"\",\n    \"3-3\": \"\",\n    \"4-3\": \"\"\n  },\n  \"cols\": 3,\n  \"rows\": 5\n}\n[/block]","updates":[],"order":1,"isReference":false,"hidden":false,"sync_unique":"","link_url":"","link_external":false,"_id":"56e590fa3c29b117008dae50","user":"56cecbb2e50c9c1b008303eb","version":{"version":"1.0","version_clean":"1.0.0","codename":"","is_stable":true,"is_beta":false,"is_hidden":false,"is_deprecated":false,"categories":["56cecbdc44c5700b0095c03e","56d1d2c05ad7ad0b00b7e809","56d1d2fa5ad7ad0b00b7e80a","56d369331660770b00081159","56d3693d1660770b0008115a","56e5361e7990160e002e3fbc","56e5362775eb791700a9c4d2","57a9030947f2f419009188d4","57b4705ee9e4c60e00f6f4c3","5828f5b04774ab0f005179a2"],"_id":"56cecbdc44c5700b0095c03d","project":"56cecbdb44c5700b0095c03a","__v":10,"createdAt":"2016-02-25T09:39:40.121Z","releaseDate":"2016-02-25T09:39:40.121Z"},"category":{"sync":{"isSync":false,"url":""},"pages":["56e590ae69d7890e000ec286","56e590fa3c29b117008dae50","56e6f058d66be417007d2364","56e7eaa8f0fafd36008faf59","56ea8db9ed3ad20e004e5a02","56ea8f3e0252fb17008804ac"],"title":"Server API","slug":"remote-api","order":7,"from_sync":false,"reference":false,"_id":"56e5362775eb791700a9c4d2","__v":6,"createdAt":"2016-03-13T09:43:03.596Z","project":"56cecbdb44c5700b0095c03a","version":"56cecbdc44c5700b0095c03d"},"__v":11,"parentDoc":null,"githubsync":"","project":"56cecbdb44c5700b0095c03a","createdAt":"2016-03-13T16:10:34.353Z","editedParams":true,"editedParams2":true}

get/campaigns - view campaigns

View the details of the active campaigns of your application

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Query Params

offset:
integer0
result offset, sorted by launch date in descending order
limit:
integer50
maximum amount of campaigns to return
name:
string
search phrase for filtering name. simple "contains" search without regex. default value is all names

Examples


Result Format


Documentation

result is an array with the key `campaigns`: [block:parameters] { "data": { "h-0": "Field", "h-1": "Type", "h-2": "Description", "0-0": "**id**", "0-1": "string", "1-0": "**name**", "2-0": "**status**", "3-0": "**is_default**", "4-0": "**created_at**", "1-1": "string", "2-1": "string", "3-1": "boolean", "4-1": "number", "h-3": "", "0-2": "the id of the campaign, you need to use this id in other endpoints that take campaign id", "1-2": "display name of the campaign", "2-2": "current status, possible values:\n* `active`\n* `disabled`", "3-2": "if this is `true`, this is the default campaign. meaning that, when a mobile device will ask for enrichment with `campaign_id` = `default` . this campaign will be used", "4-2": "the create date of the campaign in unix timestamp in [ms]", "0-3": "", "1-3": "", "2-3": "", "3-3": "", "4-3": "" }, "cols": 3, "rows": 5 } [/block]