S2S API Integration – II
IncrementX API Integration(S2S) Guide (continued)
3. VAST:
Add Vast App:
Add Vast App helps you to add new Vast ad with different VAST versions.
Method: POST
URL: https://api.incrementx.com/ip/addwebsitenapp
For request there are two objects wrapped one is Website and the other is ad unit.
Request Fields
Parameters | Is Required | Description | Type |
Website Name |
Yes |
Includes all the parameters which helps to add the VAST app details. |
object |
Category |
No |
Consists list of categories. |
String |
VAST |
Yes |
Contains the VAST details. |
String |
Following table describes the parameters wrapped by the Website object:
Parameters | Is Required | Description | Type |
siteName | Yes | Allows to enter the name of the Website for example, testweb.com. | String |
iabCategoriseId | Yes | Sends the integer master ID of category for example, 1 or 2 etc. | int |
mobileApp | Yes | Accepts a boolean value, if the value is true, it will create a mobile ad. | boolean |
pagead | Yes | Accepts a boolean value, if the value is true then it will create a page ad. | boolean |
productId | Yes | Displays the product ID of the selected products. | int |
footerad | Yes | Accepts a boolean value, if the value is true, then it will create a footer ad. | boolean |
marginad | Yes | Accepts a boolean value, if the value is true, then it will create a margin ad. | boolean |
Following table describes the parameters wrapped by the Ad unit object:
Parameters | Is Required | Description | Type |
sizeMaster |
Yes |
Includes the complete list of JSON object which contains the size ID and ad type ID(for example, paged). |
List Object |
Following table describes the parameters wrapped by the Ad unit – sizeMaster object:
Parameters | Is Required | Description | Type |
entry_id |
Yes |
Includes the complete list of JSON objects which contains the size ID and ad type ID (for example, paged). |
int |
adType |
Yes |
Holds the ad type ID for example, “adType”:{“entry_id”: 1} |
Object |
Example:
1. Request API:
Method: POST
URL: https://api.incrementx.com/ip/addwebsitenapp
https://api.incrementx.com/ip/addwebsitenapp
Method: POST
REQ: {
“website”: {
“userId”: 0,
“templateId”: 0,
“status”: 0,
“siteDemandPartnerStatus”: [],
“siteName”: “VastSite.com”,
“hostName”: “VastSite.com”,
“rtbCategories”: “IAB1,IAB2,IAB3”,
“pagead”: false,
“productId”: 5,
“footerad”: false,
“marginad”: false
},
“adUnit”: {
“sizeMaster”: [{
“entry_id”: 55,
“adType”: {
“entry_id”: 11
}
}]
}
}
RESP: {
“message”: “Vast added successfully. Your account manager will contact you soon shortly.”,
“data”: {
“id”: 12399,
“name”: “VastSite.com”
},
“statusCode”: 200
}
*Ad Unit Creation API*
1. Website:
Method: POST
URL: https://api.incrementx.com/ip/addunit
The add unit is nothing but adding sizes in selected Website.
Following table describes the parameters that contains the requested JSON body:
Request Fields
Parameters | Is Required | Description | Type |
entry_id |
Yes |
Represents the sizeMaster object that includes the complete list of JSON object which contains the size ID. |
int |
adType |
Yes |
Holds the ad type ID for example, “adType”:{“entry_id”: 1} |
object |
Following table describes the parameters wrapped by the adUnit – sizeMaster object:
Parameters | Is Required | Description | Type |
website | Yes | Contains the ID of the Website. For example,”website”: {“entry_id”: 1805 }This is site entry ID or site ID. | object |
productId | Yes | Displays the product ID of the selected products. | int |
sizeMaster | Yes | Contains the list of the sizeMaster JSON object. | object |
Response Parameters
Parameters | Type | Description |
message |
String |
Displays the success or error message for the operation performed by the users. |
statusCode |
int |
Displays the status code for the operation performed by the users. For example, it will display 200 for success and 406 for error. |
data |
object |
Stores the ID or entry ID of the size unit if the data object contains JSON. This ID can be used for unit updation of json: {“ids”: 6657, “name”:”www.testincrementx1123.com_160_600“} |
Example:
1. Request API:
https://api.incrementx.com/ip/addunit
Method: POST
REQ: {
“sizeMaster”: [{
“entry_id”: 16,
“adType”: {
“entry_id”: 1
}
}],
“website”: {
“entry_id”: 12398
},
“productId”: 1
}
RESP:
{
“message”: ” 300 x 600 Unit is added successfully for selected Website”,
“data”:
{
“id”: 0,
“name”: “[ClientSite.com_300_600_0]”,
“ids”:
[
45172
]
},
“statusCode”: 200
}
2. App:
Method: POST
URL: https://api.incrementx.com/ip/addunit
The add unit App is nothing but adding sizes in selected Mobile App.
Following table describes the parameters that contains the requested JSON body:
Request Fields
Parameters | Is Required | Description | Type |
website | Yes | Contains the ID of the Website. For example,”website”: {“entry_id”: 1805 }This is site entry ID or site ID. | object |
productId | Yes | Displays the product ID of the selected products. | int |
sizeMaster | Yes | Contains the list of the sizeMaster JSON object. | object |
Following table describes the parameters wrapped by the adUnit – sizeMaster object:
Parameters | Is Required | Description | Type |
entry_id |
Yes |
Represents the sizeMaster object that includes the complete list of JSON object which contains the size ID. |
int |
adType |
Yes |
Holds the ad type ID for example, “adType”:{“entry_id”: 1} |
object |
Response Parameters
Parameters | Type | Description |
message |
String |
Displays the success or error message for the operation performed by the users. |
statusCode |
int |
Displays the status code for the operation performed by the users. For example, it will display 200 for success and 406 for error. |
data |
object |
Stores the ID or entry ID of the size unit if the data object contains JSON. This ID can be used for unit updation of json: {“id”: 6657,
“name”:”www.testincrementx1123.com_160_600 “} |
Example:
1. Request API:
https://api.incrementx.com/ip/addunit
Method: POST
REQ: {
“sizeMaster”: [{
“entry_id”: 21,
“adType”: {
“entry_id”: 6
}
}, {
“entry_id”: 44,
“adType”: {
“entry_id”: 6
}
}
}],
“website”: {
“entry_id”: 12400
},
“productId”: 3,
“commentsHistory”: []
}
RESP: {
“message”: ” 300 x 50, 300 x 50 Units are added successfully for selected Mobile App”,
“data”: {
“id”: 0,
“name”: “[MobileSite.com_300_50_0, MobileSite.com_300_50_0]”,
“ids”: [45176, 45177]
},
“statusCode”: 200
}
3. VAST:
Method: POST
URL: https://api.incrementx.com/ip/addunit
The add unit App is nothing but adding sizes in selected VAST.
Following table describes the parameters that contains the requested JSON body:
Request Fields
Parameters | Is Required | Description | Type |
website | Yes | Contains the ID of the Website. For example,”website”: {“entry_id”: 1805 }This is site entry ID or site ID. | object |
productId | Yes | Displays the product ID of the selected products. | int |
sizeMaster | Yes | Contains the list of the sizeMaster JSON object. | object |
Following table describes the parameters wrapped by the adUnit – sizeMaster object:
Parameters | Is Required | Description | Type |
entry_id |
Yes |
Represents the sizeMaster object that includes the complete list of JSON object which contains the size ID. |
int |
adType |
Yes |
Holds the ad type ID for example, “adType”:{“entry_id”: 1} |
object |
Response Parameters
Parameters | Type | Description |
message |
String |
Displays the success or error message for the operation performed by the users. |
statusCode |
int |
Displays the status code for the operation performed by the users. For example, it will display 200 for success and 406 for error. |
data |
object |
Stores the ID or entry ID of the size unit if the data object contains JSON. This ID can be used for unit updation of json: {“id”: 6657, “name”:”www.testincrementx1123.com_160_600“} |
Example:
1. Request API:
https://api.incrementx.com/ip/addunit
Method: POST
REQ: {
“sizeMaster”: [{
“entry_id”: 0,
“adType”: {
“entry_id”: 11
}
}, {
“entry_id”: 56,
“adType”: {
“entry_id”: 11
}
}],
“website”: {
“entry_id”: 12399
},
“productId”: 5,
}
RESP:
{
“message”: ” VAST 3.0 Unit is added successfully for selected Vast”,
“data”:
{
“id”: 0,
“name”: “[VastSite.com_VAST3.0_0]”,
“ids”:
[
45174
]
},
“statusCode”: 200
}
To continue, click here S2S API Integration – III