Clanbite Points

clanbite_points_award( int $user_id, string $action_key, array $context = array() ): void

Award points for a registered action slug (subject: user ID).

Uses configured point types and rules; respects per-period caps and ledger history.

Namespace: Kernowdev\ClanbitePoints

Parameters

$user_id (int) Required

Recipient user ID.

$action_key (string) Required

Action slug (e.g. login, social_post_created).

$context (array<string,mixed>) Optional

Optional context for clanbite_points_awarded. Add points_ref (a short string such as sk_post:34) to let clanbite_points_revoke() take the points back later; the same reference only earns once while its award stands.

Default: array()

Returns

void

Defined in inc/functions.php

Changelog

VersionDescription
1.4.0Updated.