WC_Webhook::get_api_version( string $context = 'view' )
API version.
Description Description
Parameters Parameters
- $context
-
(Optional) What the value is for. Valid values are 'view' and 'edit'.
Default value: 'view'
Return Return
(string)
Source Source
File: includes/class-wc-webhook.php
public function get_api_version( $context = 'view' ) {
$version = $this->get_prop( 'api_version', $context );
return 0 < $version ? 'wp_api_v' . $version : 'legacy_v3';
}
Changelog Changelog
| Version | Description |
|---|---|
| 3.0.0 | Introduced. |