Create placement capping
Creates a new capping rule for the specified placement, controlling how frequently events (impressions, clicks, or actions) occur within a time window.
https://YOUR-NETWORK-DOMAIN/rest-api/placement/capping/{placementId}.do Creates a new capping rule for the specified placement, controlling how frequently events (impressions, clicks, or actions) occur within a time window. The capping type determines which event category is capped (e.g. PLACEMENT_FREQUENCY for impressions, PLACEMENT_CLICKS for clicks). The response JSON carries the new record, with its assigned id, under capping. Requires UPDATE permission on the placement's site, MANAGE_INVENTORY_CAPPING enabled, and the permission of the capping type and subject.
Path Params
placementId integer required
Numeric ID of the placement to add the capping rule to
3001 Form Params
type string required
Type of the capping to create. Only placement types are accepted: PLACEMENT_REQUEST, PLACEMENT_FREQUENCY, PLACEMENT_CLICKS, PLACEMENT_ACTIONS; any other value of the shared enum is rejected with 'Capping type is incompatible with entity'
PLACEMENT_FREQUENCY amount integer required
Maximum number of events allowed within the specified period
1000 period integer required
Length of the capping time window, expressed in units defined by periodType
24 periodType string required
Unit of the capping period. Allowed values: SECOND, MINUTE, HOUR, DAY, WEEK, MONTH, YEAR
HOUR flat boolean required
When true, events are distributed evenly (flat) across the period instead of being served/counted as fast as possible
true subject string
Entity used to identify unique users for capping. Optional; allowed values: USER_COOKIE, USER_SERVER_SIDE, USER_MIXED, IP, LES_IP
USER_COOKIE Responses
200
Capping created: {success, capping:{id, type, amount, period, periodType, flat, subject, ...}}
400
Bad request — invalid or missing parameters
401
Authentication error
403
Forbidden — insufficient permissions
404
Not found — resource does not exist