Skip to main content
PUT
Update Rule
Updates a Customer Value rule. Two things differ from most Everflow update endpoints:
  • The ID goes in the body, not the path. Send network_usm_rule_id inside the JSON object; the path is the same /networks/usm/rules you POST to.
  • It is a full replace, not a merge. Any field you leave out is reset, and the goals array you send replaces the existing goals entirely — they are re-created, so they come back with new network_usm_rule_goal_id values. Fetch the rule first, change what you need, and send the whole object back.
All the rule combinations listed under Create Rule apply here too — including the requirement that network_offer_payout_revenue_id be 0 once network_offer_ids holds more than one offer. To pause a rule, send it back with status set to inactive rather than deleting it.

Authorizations

X-Eflow-Api-Key
string
header
required

The Everflow API key generated from the Control Center > Security.

Body

application/json
network_usm_rule_id
integer
required

The rule to update.

name
string
required

The rule name shown in the Everflow UI.

Example:

"High-LTV bonus"

status
enum<string>
required

Whether the rule is evaluated against incoming conversions.

Available options:
active,
inactive
aggregation_level
enum<string>
required

How customer activity is grouped before goals are evaluated. user aggregates all of a customer's activity across the network; the compound levels keep a separate total per partner, offer or advertiser.

Available options:
user,
user_offer,
user_affiliate,
user_advertiser,
user_affiliate_offer,
user_affiliate_advertiser
period
enum<string>
required

The window the aggregation resets on. global and since_user_sign_up never reset, and are the only periods allowed with a one_time trigger.

Available options:
daily,
weekly,
monthly,
quarterly,
global,
since_user_sign_up
trigger_type
enum<string>
required

Whether the rule fires once per customer (one_time) or every time the goals are met (recurring). one_time requires a non-resetting period, and forces payout_action exact with payout_type cpa.

Available options:
one_time,
recurring
time_window_duration
integer
required

How many days of customer history the rule looks back over. Must be greater than 0.

Example:

30

goals
object[]
required

The conditions a customer must meet. All goals must match. Replaced wholesale on every update.

start_date
string

Date the rule starts applying (format: YYYY-MM-DD).

Example:

"2026-09-01"

end_date
string

Date the rule stops applying (format: YYYY-MM-DD).

Example:

"2026-12-31"

network_offer_ids
integer[] | null

Offers the rule applies to. Leave empty to apply to all offers.

network_advertiser_ids
integer[] | null

Advertisers the rule applies to. Leave empty to apply to all advertisers.

network_affiliate_ids
integer[] | null

Partners the rule applies to. Leave empty to apply to all partners.

network_offer_payout_revenue_id
integer

Restrict the rule to one specific offer payout/revenue entry (event). Send 0 to apply to every event on the selected offers. Cannot be set when network_offer_ids holds more than one offer.

is_payout_enabled
boolean

Whether the rule adjusts partner payout.

payout_action
enum<string>

How payout is adjusted. exact sets the payout outright, flat_increase and flat_decrease add or subtract payout_value, and increase and decrease apply payout_percentage. Send unknown when is_payout_enabled is false.

Available options:
exact,
increase,
decrease,
flat_increase,
flat_decrease,
unknown
payout_value
number<double>

The flat amount used by exact, flat_increase and flat_decrease.

payout_type
enum<string>

The payout model the adjusted payout is written as. Rules support these six models; the SKU variants available on an offer (cpa_sku, cps_sku, …) are not supported here.

Required with payout_action: exact (blank is rejected there with Must define a payout type if payout action is 'exact'), and must be cpa for one_time rules. The flat actions apply payout_value directly and ignore it — send blank.

Available options:
cpa,
cpc,
cpm,
cps,
cpa_cps,
prv,
blank
payout_percentage
number<double>

The percentage used by the increase and decrease actions.

is_revenue_enabled
boolean

Whether the rule adjusts advertiser revenue.

revenue_action
enum<string>

How revenue is adjusted, mirroring payout_action. Send unknown when is_revenue_enabled is false.

Available options:
exact,
increase,
decrease,
flat_increase,
flat_decrease,
unknown
revenue_value
number<double>

The flat amount used by exact, flat_increase and flat_decrease.

revenue_type
enum<string>

The revenue model the adjusted revenue is written as. Rules support these five models. Required with revenue_action: exact (blank is rejected there with Must define a revenue type if revenue action is 'exact'); the flat actions ignore it.

Available options:
rpa,
rpc,
rpm,
rps,
rpa_rps,
blank
revenue_percentage
number<double>

The percentage used by the increase and decrease actions.

Response

The updated rule.

name
string
required

The rule name shown in the Everflow UI.

Example:

"High-LTV bonus"

status
enum<string>
required

Whether the rule is evaluated against incoming conversions.

Available options:
active,
inactive
aggregation_level
enum<string>
required

How customer activity is grouped before goals are evaluated. user aggregates all of a customer's activity across the network; the compound levels keep a separate total per partner, offer or advertiser.

Available options:
user,
user_offer,
user_affiliate,
user_advertiser,
user_affiliate_offer,
user_affiliate_advertiser
period
enum<string>
required

The window the aggregation resets on. global and since_user_sign_up never reset, and are the only periods allowed with a one_time trigger.

Available options:
daily,
weekly,
monthly,
quarterly,
global,
since_user_sign_up
trigger_type
enum<string>
required

Whether the rule fires once per customer (one_time) or every time the goals are met (recurring). one_time requires a non-resetting period, and forces payout_action exact with payout_type cpa.

Available options:
one_time,
recurring
time_window_duration
integer
required

How many days of customer history the rule looks back over. Must be greater than 0.

Example:

30

goals
object[]
required

The conditions a customer must meet. All goals must match. Replaced wholesale on every update.

network_usm_rule_id
integer

Unique rule ID.

Example:

3

network_id
integer

Network ID.

Example:

1

start_date
string

Date the rule starts applying (format: YYYY-MM-DD).

Example:

"2026-09-01"

end_date
string

Date the rule stops applying (format: YYYY-MM-DD).

Example:

"2026-12-31"

network_offer_ids
integer[] | null

Offers the rule applies to. Leave empty to apply to all offers.

network_advertiser_ids
integer[] | null

Advertisers the rule applies to. Leave empty to apply to all advertisers.

network_affiliate_ids
integer[] | null

Partners the rule applies to. Leave empty to apply to all partners.

network_offer_payout_revenue_id
integer

Restrict the rule to one specific offer payout/revenue entry (event). Send 0 to apply to every event on the selected offers. Cannot be set when network_offer_ids holds more than one offer.

is_payout_enabled
boolean

Whether the rule adjusts partner payout.

payout_action
enum<string>

How payout is adjusted. exact sets the payout outright, flat_increase and flat_decrease add or subtract payout_value, and increase and decrease apply payout_percentage. Send unknown when is_payout_enabled is false.

Available options:
exact,
increase,
decrease,
flat_increase,
flat_decrease,
unknown
payout_value
number<double>

The flat amount used by exact, flat_increase and flat_decrease.

payout_type
enum<string>

The payout model the adjusted payout is written as. Rules support these six models; the SKU variants available on an offer (cpa_sku, cps_sku, …) are not supported here.

Required with payout_action: exact (blank is rejected there with Must define a payout type if payout action is 'exact'), and must be cpa for one_time rules. The flat actions apply payout_value directly and ignore it — send blank.

Available options:
cpa,
cpc,
cpm,
cps,
cpa_cps,
prv,
blank
payout_percentage
number<double>

The percentage used by the increase and decrease actions.

is_revenue_enabled
boolean

Whether the rule adjusts advertiser revenue.

revenue_action
enum<string>

How revenue is adjusted, mirroring payout_action. Send unknown when is_revenue_enabled is false.

Available options:
exact,
increase,
decrease,
flat_increase,
flat_decrease,
unknown
revenue_value
number<double>

The flat amount used by exact, flat_increase and flat_decrease.

revenue_type
enum<string>

The revenue model the adjusted revenue is written as. Rules support these five models. Required with revenue_action: exact (blank is rejected there with Must define a revenue type if revenue action is 'exact'); the flat actions ignore it.

Available options:
rpa,
rpc,
rpm,
rps,
rpa_rps,
blank
revenue_percentage
number<double>

The percentage used by the increase and decrease actions.

time_created
integer

Unix timestamp of creation.

Example:

1788398644

time_saved
integer

Unix timestamp of last update.

Example:

1788398704

relationship
object

Related objects for the rule.