Chapter 5. Entry Point
- 5.1. Accessing the API Entry Point
- 5.2. Product Information
- 5.3. Link Elements
- 5.4. Special Object Elements
- 5.5. Summary Element
- 5.6. RESTful Service Description Language (RSDL)
- 5.7. Backup-Restore API Overview
- 5.8. Full Virtual Machine Backups
- 5.9. Full Virtual Machine Restore
- 5.10. Red Hat Enterprise Virtualization Windows Guest VSS Support
- 5.11. QEMU Guest Agent Overview
- 5.12. VSS Transaction Flow
5.1. Accessing the API Entry Point
A user begins interacting with the API through a
GET request on the entry point URI consisting of a host and base.
Example 5.1. Accessing the API Entry Point
If the host is
www.example.com and the base is /api, the entry point appears with the following request:
GET /api HTTP/1.1
Accept: application/xml
Host: www.example.com
Authorization: [base64 encoded credentials]
HTTP/1.1 200 OK
Content-Type: application/xml
<api>
<link rel="hosts" href="/api/hosts"/>
<link rel="vms" href="/api/vms"/>
...
<product_info>
<name>Red Hat Enterprise Virtualization</name>
<vendor>Red Hat</vendor>
<version revision="0" build="0" minor="1" major="3"/>
</product_info>
<special_objects>
<link rel="templates/blank" href="..."/>
<link rel="tags/root" href="..."/>
</special_objects>
<summary>
<vms>
<total>10</total>
<active>3</active>
</vms>
<hosts>
<total>2</total>
<active>2</active>
</hosts>
<users>
<total>8</total>
<active>2</active>
</users>
<storage_domains>
<total>2</total>
<active>2</active>
</storage_domains>
</summary>
</api>
Note
For simplicity, all other examples omit the
Host: and Authorization: request headers and assume the base is the default /api path. This base path differs depending on your implementation.