InfoApi
PHP SDK: the Info operations, 1 method, each with its parameters, result and a complete example.
PHP SDK · BIMworks\Api · class · 1 method
General information about the instance
Construct it with the client of the connect step: new InfoApi(config: $client). Each method is one operation of the API part, where it runs on its page.
| Method | Operation | Description |
|---|---|---|
getApplicationVersion | GetApplicationVersion | The BIM.works version of the instance |
getApplicationVersion#
PHP#
public function getApplicationVersion(): GetApplicationVersion200ResponseThe BIM.works version of the instance. The version of BIM.works the instance runs, to check compatibility. No credential needed.
| Operation | GetApplicationVersion · POST /openapi/info/GetApplicationVersion |
|---|---|
| Scope | none: callable before logging in |
Parameters#
None: the operation takes no request.
Returns#
GetApplicationVersion200Response — The version
Example#
PHP#
<?php
require __DIR__ . '/vendor/autoload.php';
use BIMworks\Api\InfoApi;
use BIMworks\Configuration;
// 1. Connect to BIM.works (GetApplicationVersion needs no login)
$client = (new Configuration())->setHost('https://bim.works/openapi');
// 2. The request
// (GetApplicationVersion takes no request)
// 3. The call
$result = (new InfoApi(config: $client))->getApplicationVersion();
// 4. The result
echo json_encode($result, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES), PHP_EOL;