Any endpoint of this controller requires an administrator logged in on rest API.
Check authentication chapter from WordPress rest API handbook for more information.
Table of contents
Schema
The schema defines all the fields that exist for a user earning object.
integer | Unique identifier for the object. Context: |
object | Meta fields. Context: |
string | The title for the object. Context: |
integer | The ID for the user of the object. Context: |
integer | The ID for the post of the object. Context: |
string | The type for the post of the object. Context: |
integer | The points amount of the object. Context: |
string | The type for the points amount of the object. Context: |
string | The date the object was created, in the site's timezone. Context: |
List User Earnings
Arguments
| Scope under which the request is made; determines fields present in response. Default: One of: |
| Current page of the collection. Default: |
| Maximum number of items to be returned in result set. Default: |
| Limit results to those matching a string. |
| Offset the result set by a specific number of items. |
| Order sort attribute ascending or descending. Default: One of: |
| Sort collection by object attribute. Default: One of: |
| Limit result set to earnings assigned to specific users. |
| Limit result set to earnings assigned to specific posts. |
| Limit result set to earnings assigned to specific post types. |
| Limit result set to earnings assigned to specific points types. |
| Setting it to true will force to limit results of the same post_type and points_type. |
| Ensure result set excludes specific IDs. |
| Limit result set to specific IDs. |
| Limit response to user earnings after a given ISO8601 compliant date. |
| Limit response to user earnings before a given ISO8601 compliant date. |
Create a User Earning
Arguments
Meta fields. | |
The title for the object. | |
The ID for the user of the object. | |
The ID for the post of the object. | |
The type for the post of the object. | |
The points amount of the object. | |
The type for the points amount of the object. | |
The date the object was created, in the site's timezone. |
Update a User Earning
Arguments
Unique identifier for the object. | |
Meta fields. | |
The title for the object. | |
The ID for the user of the object. | |
The ID for the post of the object. | |
The type for the post of the object. | |
The points amount of the object. | |
The type for the points amount of the object. | |
The date the object was created, in the site's timezone. |