1. Documentation
  2. Rest API Extended
  3. Requirements Extended Controller

Requirements Extended Controller

Any endpoint of this controller requires an administrator logged in on rest API.
Check authentication chapter from WordPress rest API handbook for more information.

Award requirement

Award the desired requirement to the given user.

Arguments

user_id

User who requirement will be awarded.

requirement_id

Requirement that will be awarded.

Definition

POST /wp/v2/gamipress/award-requirement

Example Request

curl -X POST http://website.com/wp-json/wp/v2/gamipress/award-requirement -d "user_id=1&requirement_id=1"

Revoke requirement

Revoke the desired requirement to the given user.

Arguments

user_id

User who requirement will be revoked.

requirement_id

Requirement that will be revoked.

Definition

POST /wp/v2/gamipress/revoke-requirement

Example Request

curl -X POST http://website.com/wp-json/wp/v2/gamipress/revoke-requirement -d "user_id=1&requirement_id=1"

Was this article helpful to you? Yes No

How can we help?