advertiser-api-guides | Custom API Guide

This document provides information on how to publish a custom event to InMobi.

Note: This document is intended for advertisers who are directly sharing custom events with InMobi. Custom events include registrations and surveys, among others.

Custom Endpoint

Advertisers can provide custom events information at the custom endpoint.

Parameters

The following parameters are required:

Parameter

Required (Yes/No)

propertyId

Yes

trackingPartner

Yes

eventName

Yes

ida

No

gpId

No

impId

No

isLastClick

No

isViewThrough

No

isReengagement

No

deviceIp

No

useragent

No

attributed

No

appId

No

country

No

appVersion

No

dnt

No

deviceName

No

requestId

No

eventTime

No

eventWeight

No

ltvValue

No

ltvCurrency

No

purchaseTime

No

purchaseCurrency

No

purchaseValue

No

purchaseWeight

No

providerSegmentIds

No

confidenceScore

No

matchType

No

eventItems

No

eventLat

No

eventLong

No

eventLevel

No

eventRating

No

eventTime

No

eventSearchString

No

eventTime

No

firstevent

No

siteId

No

subSiteId

No

ctawindow

No

inactivewindow

No

lastTimeSpent

No

network

No

organic

No

reattrrwindow

No

vtawindow

No

clickTime

No

isFraud

No

rejectReason

No

action

No

Format for Sending Requests

GET method

URL Format:

propertyId=propertyId&trackingPartner=trackingPartner&eventName=eventName&ida=ida&gpId=gpId&impId=impId&isLastClick=isLastClick&isViewThrough=isViewThrough&isReengagement=isReengagement&deviceIp=deviceIp&useragent=useragent&attributed=attributed&appId=appId&country=country&appVersion=appVersion&dnt=dnt&deviceName=deviceName&requestId=requestId&eventTime=eventTime&eventWeight=eventWeight<vValue=ltvValue<vCurrency=ltvCurrency&purchaseTime=purchaseTime&purchaseCurrency=purchaseCurrency&purchaseValue=purchaseValue&purchaseWeight=purchaseWeight&providerSegmentIds=providerSegmentIds&confidenceScore=confidenceScore&matchType=matchType&eventItems=eventItems&eventLat=eventLat&eventLong=eventLong&eventLevel=eventLevel&eventRating=eventRating&eventSearchString=eventSearchString&firstevent=firstevent&siteId=siteId&subSiteId=subSiteId&ctawindow=ctawindow&inactivewindow=inactivewindow&lastTimeSpent=lastTimeSpent&network=network&organic=organic&reattrwindow=reattrwindow&vtawindow=vtawindow&clickTime=clickTime&isFraud=isFraud&rejectReason=rejectReason&action=action

JSON Response for Success

{
"status":"OK",
"message":"success",
"code":"200"
}
				

JSON Response for Failure

{
"status":”BAD_REQUEST”,
"message":"error_message",
"code":"error_code"
}
				

POST method

Note: The .CSV file needs to have at least one of the following headings based on the device ID type:

ida, gpId
		

Example:

gpId

bd1e2264-382d-4980-9e50-ff5bcc954d50

URL Format

http://advertiser-content.inmobiapis.com/tpce/v1/upload/events/custom?propertyId=propertyId&trackingPartner=trackingPartner

Response Content Headers

  • Content Type: multipart/form-data
  • Accept-Encoding: gzip
  • Content-Disposition: attachment; filename="xyzfilename"
  • Content-Type: text/csv
  • Content-Transfer-Encoding: binary

JSON Response for Success

{
 "status":"OK",
"message":"success_message xxxxxxx",
"code":"200",
"jobUrl":"job url to check status of request"
}
				

Note: The JobUrl will give a JSON response indicating whether the job has succeeded, failed, or is in progress.

JSON Response for Failure

{
"status": "BAD_REQUEST",
"message": "Invalid file Content found : Internal errors encountered..java.util.NoSuchElementException: No value present",
"code":"1004"
}
				

Device ID Guidelines

iOS

Parameter Name

Parameter Type

Description

ida

String

Identifier for advertiser without hashing. For iOS 6 and above, only. For more information, click here.

Android

Parameter Name

Parameter Type

Description

gpId

String

Google Play advertiser ID without hashing. Please see here for more information.