src/Leevel/Http/ApiResponse.php
public function methodNotAllowed(?string $message = null, ?string $text = null): IResponse
    {
        return $this->error($message, static::HTTP_METHOD_NOT_ALLOWED, $text);
    }
public function methodNotAllowed(?string $message = null, ?string $text = null): IResponse
    {
        return $this->error($message, static::HTTP_METHOD_NOT_ALLOWED, $text);
    }
方法禁用
禁用请求中指定的方法: 405.

@param string $message
@param string $text

@return $this