SlotConfigurationCampaignAssignmentSearch resource (Data API 23.2)

Summary

Http Method Resource Description
POST /sites/{site_id}/slot_configuration_campaign_assignment_search

Searches for slotconfiguration campaign assignments.

The SlotConfigCampaignAssignment Search document contains a search object that allows filtering on various attributes.

The query attribute specifies a complex query that can be used to narrow down the search. Attributes are grouped into different buckets. These are the list of searchable attributes with their corresponding buckets:

Main:

  • rank - Integer
  • start_date - Date
  • end_date - Date

Campaign:

  • campaign_id - String
  • enabled - Boolean

Slot configuration:

  • slot_configuration_id - String
  • description - String

Only attributes in the same bucket can be joined using a disjunction (OR). For instance, when joining rank and description above, only a conjunction is allowed (AND), whereas slot_configuration_id and description can be joined using a disjunction because they are in the same bucket. If an attribute is used in a disjunction (OR) that violates this rule, an exception will be thrown.

Expands that can be applied for the search request

  • campaign
  • slotConfiguration

Note that only searchable attributes (excluding the ones marked with above with an asterisk) can be used in sorting.

Search SlotConfiguration Campaign Assignments

Searches for slotconfiguration campaign assignments.

The SlotConfigCampaignAssignment Search document contains a search object that allows filtering on various attributes.

The query attribute specifies a complex query that can be used to narrow down the search. Attributes are grouped into different buckets. These are the list of searchable attributes with their corresponding buckets:

Main:

  • rank - Integer
  • start_date - Date
  • end_date - Date

Campaign:

  • campaign_id - String
  • enabled - Boolean

Slot configuration:

  • slot_configuration_id - String
  • description - String

Only attributes in the same bucket can be joined using a disjunction (OR). For instance, when joining rank and description above, only a conjunction is allowed (AND), whereas slot_configuration_id and description can be joined using a disjunction because they are in the same bucket. If an attribute is used in a disjunction (OR) that violates this rule, an exception will be thrown.

Expands that can be applied for the search request

  • campaign
  • slotConfiguration

Note that only searchable attributes (excluding the ones marked with above with an asterisk) can be used in sorting.

Url

POST https://hostname:port/dw/data/v23_2/sites/{site_id}/slot_configuration_campaign_assignment_search

Formats

json, xml

Authentication

Name Description
OAuth Authentication via OAuth token.

Request Document

SearchRequest

Response Document

SlotConfigurationCampaignAssignmentSearchResult

Path Parameters

Parameter Type Description Constraints
site_id String The site context.  

In case of a failure Fault Document is returned.

Faults

Status Type Arguments Description
400 MalformedSearchParameterException   Thrown if the query is ill-formed.

Sample

REQUEST:
POST /s/-/dw/data/v23_2/sites/SiteGenesis/slot_configuration_campaign_assignment_search HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Accept: application/json

{
   "query" : 
   {
      "term_query" : 
      {
         "_type" : "term_query",
         "fields" : 
         [
            "campaign_id"
         ],
         "operator" : "is",
         "values" : 
         [
            "campaign-registered"
         ]
      }
   },
   "expand": ["slotConfiguration"],
   "select" : "(**)",
}

RESPONSE:
HTTP/1.1 200 OK
Content-Type: application/json; charset=UTF-8

{
   "_v" : "23.2",
   "_type" : "slot_configuration_campaign_assignment_search_result",
   "count" : 1,
   "expand" : 
   [
      "slotConfiguration"
   ],
   "hits" : 
   [
      
      {
         "_type" : "slot_configuration_campaign_assignment",
         "campaign_id" : "campaign-registered",
         "context" : "global",
         "enabled" : true,
         "description" : "Free Microsoft Zune With Purchase Of $500 Or More In Electronics",
         "link" : "https://example.com/s/-/dw/data/v23_2/sites/SiteGenesis/slot_configuration_campaign_assignments/campaign-registered",
         "schedule" : 
         {
            "_type" : "schedule"
         },
         "slot_configuration_id" : "Promo Zune",
         "slot_configuration_uuid" : "bdL6MiWcbpakEaaadkHwIhZj1N",
         "slot_id" : "404-promo"
         "slot_configuration" :
         {
         	"_type" : "slot_configuration",
         	"assignment_information" :
         	{
         		"_type" : "slot_configuration_assignment_information",
               "active" : true,
               "active_campaign_assignments" :
               {
               		"_type" : "slot_configuration_campaign_assignment",
                     "campaign_id" : "campaign-registered",
                     "context" : "global",
                     "enabled" : true,
                     "rank" : 40
               }
         	}
         }
      }
   ],
   "query" : 
   {
      "term_query" : 
      {
         "_type" : "term_query",
         "fields" : 
         [
            "campaign_id"
         ],
         "operator" : "is",
         "values" : 
         [
            "campaign-registered"
         ]
      }
   },
   "select" : "(**)",
   "start" : 0,
   "total" : 1
}
X OCAPI versions 15.x and 16.x will be retired on March 31, 2021. For dates and more information, see the OCAPI versioning and deprecation policy and this Knowledge Article.