RTB API

Using merchenta.io for real-time bidding

Campaign lookup 

List all campaign codes 

/v3/campaigns

List all campaign codes.

  • Curl
  • Copy
    curl -i \ -X GET \ -H 'Authorization: Bearer {YOUR_TOKEN_HERE}' \ https://sandbox.rtbapi.io/v3/campaigns
  • Response  200
  • Headers
    Content-Type: application/json
    Example body
    {
            "status": "success",
            "data": {
                "campaignCodes": [
                    "MERCHENTA-simple",
                    "MERCHENTA-contextual-targeting",
                    "MERCHENTA-geo-targeting",
                    "MERCHENTA-retargeting"
                ]
            }
        }

Get campaign by code 

/v3/campaigns/{campaignCode}

Retrieves campaign by code.

  • Parameters
  • campaignCode
    string (required) Example: MERCHENTA-test

    The campaign code.

  • Curl
  • Copy
    curl -i \ -X GET \ -H 'Authorization: Bearer {YOUR_TOKEN_HERE}' \ https://sandbox.rtbapi.io/v3/campaigns/MERCHENTA-test
  • Response  200
  • Headers
    Content-Type: application/json
    Example body
    {
            "status": "success",
            "data": {
                "campaign": {
                    "code": "MERCHENTA-test",
                    "creatives": [
                        {
                            "code": "MERCHENTA-test-1-1",
                            "status": "PENDING",
                            "type": "IMAGE",
                            "dimensions": {
                                "width": 160,
                                "height": 600
                            },
                            "creativeId": "MERCHENTA-fa1a576f2b68bb5b6a8601ae1a669e32e99ab14a.png",
                            "clickthroughUrl": "https://merchenta.io"
                        }
                    ],
                    "advertiserDomain": "http://wp.pl",
                    "biddingSettings": {
                        "biddingStrategy": {
                            "strategy": "CPMCappedBiddingStrategy",
                            "maxBid": 2
                        },
                        "pacingType": "ACCELERATED",
                        "budget": {
                            "daily": 10,
                            "currency": "USD"
                        }
                    },
                    "timeSettings": {},
                    "targetingSettings": {
                        "geoSettings": {},
                        "contextualSettings": {
                            "iabCategories": []
                        },
                        "retargetingSettings": {},
                        "deviceTargetingSettings": {
                            "devices": [
                                "DESKTOP",
                                "SLATE",
                                "MOBILE",
                                "CONSOLE",
                                "WEARABLE",
                                "TV"
                            ]
                        }
                    },
                    "inventorySettings": {
                        "placementType": [
                            "ATF"
                        ],
                        "inventoryType": "TRANSPARENT",
                        "publisherWhiteList": [
                            "wp.pl",
                            "onet.pl"
                        ]
                    },
                    "optimisationSettings": {
                        "optimisationStrategy": "ROUND_ROBIN",
                        "commenceOptimisationAfter": 50000
                    },
                    "productSettings": {},
                    "lastModificationTime": "2014-10-02T12:57:29.000"
                }
            }
        }
  • Response  404

Get creative by code 

/v3/campaigns/{campaignCode}/{creativeCode}

Retrieves campaign by code.

  • Parameters
  • campaignCode
    string (required) Example: MERCHENTA-test

    The campaign code.

    creativeCode
    string (required) Example: MERCHENTA-test-1

    The creative code.

  • Curl
  • Copy
    curl -i \ -X GET \ -H 'Authorization: Bearer {YOUR_TOKEN_HERE}' \ https://sandbox.rtbapi.io/v3/campaigns/MERCHENTA-test/MERCHENTA-test-1
  • Response  200
  • Headers
    Content-Type: application/json
    Example body
    {
            "status": "success",
            "data": {
                    "creative": {
                            "code": "MERCHENTA-test-1-1",
                            "status": "PENDING",
                            "type": "IMAGE",
                            "dimensions": {
                                "width": 160,
                                "height": 600
                            },
                            "creativeId": "MERCHENTA-fa1a576f2b68bb5b6a8601ae1a669e32e99ab14a.png",
                            "clickthroughUrl": "https://merchenta.io"
                        }
                    }
        }
  • Response  404
Next page  Previous page