LLMS_REST_API_Keys_Controller::get_object( int $id, bool $hydrate = true )
Retrieve An API Key object by ID.
Parameters Parameters
- $id
-
(int) (Required) API Key ID.
- $hydrate
-
(bool) (Optional) If true, pulls all key data from the database on instantiation.
Default value: true
Return Return
(WP_Error|LLMS_REST_API_Key)
Source Source
File: libraries/lifterlms-rest/includes/server/class-llms-rest-api-keys-controller.php
protected function get_object( $id, $hydrate = true ) { $key = LLMS_REST_API()->keys()->get( $id, $hydrate ); return $key ? $key : llms_rest_not_found_error(); }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
1.0.0-beta.1 | Introduced. |