[comment]: # ({34f25b55-34f25b55})
# apiinfo.version

[comment]: # ({/34f25b55-34f25b55})

[comment]: # ({d6c96270-d6c96270})
### Description

`string apiinfo.version(array)`

This method allows to retrieve the version of the Zabbix API.

[comment]: # ({/d6c96270-d6c96270})

[comment]: # ({b0128b89-b0128b89})
### Parameters

::: noteimportant
This method is available to unauthenticated users
and must be called without the `auth` parameter in the JSON-RPC
request.
:::

`(array)` The method accepts an empty array.

[comment]: # ({/b0128b89-b0128b89})

[comment]: # ({53521d11-53521d11})
### Return values

`(string)` Returns the version of the Zabbix API.

::: notetip
Starting from Zabbix 2.0.4 the version of the API
matches the version of Zabbix.
:::

[comment]: # ({/53521d11-53521d11})

[comment]: # ({b41637d2-b41637d2})
### Examples

[comment]: # ({/b41637d2-b41637d2})

[comment]: # ({6ba4bdd0-6ba4bdd0})
#### Retrieving the version of the API

Retrieve the version of the Zabbix API.

Request:

``` {.java}
{
    "jsonrpc": "2.0",
    "method": "apiinfo.version",
    "params": [],
    "id": 1
}
```

Response:

``` {.java}
{
    "jsonrpc": "2.0",
    "result": "4.0.0",
    "id": 1
}
```

[comment]: # ({/6ba4bdd0-6ba4bdd0})

[comment]: # ({06263e42-06263e42})
### Source

CAPIInfo::version() in
*frontends/php/include/classes/api/services/CAPIInfo.php*.

[comment]: # ({/06263e42-06263e42})
