WordPress\AiClient\Providers\Http\DTO
Response::isSuccessful
Checks if the response indicates success.
Method of the class: Response{}
No Hooks.
Returns
true|false. True if status code is 2xx, false otherwise.
Usage
$Response = new Response(); $Response->isSuccessful(): bool;
Changelog
| Since 0.1.0 | Introduced. |
Response::isSuccessful() Response::isSuccessful code WP 7.0.4
public function isSuccessful(): bool
{
return $this->statusCode >= 200 && $this->statusCode < 300;
}