Use the
CAM REST API
Discovery Tool to get a list of computers. Learn how to filter, shape, and sort
the list of computers returned from the
CAM
database.
- Get an API key. See
Create an API Key.
- Open the
CAM REST API
Discovery Tool using this URL:
https://{API host name}/cam/docs/index.html.
- Generate an access token. See
Access Tokens for the
CAM REST API.
- Use the access token to authorize
CAM REST API
use. See
Use Tokens to Authorize Access to the
CAM REST API
Discovery Tool.
- Scroll to the
Computer section.
- Select
Get for the
/cam/api/v1/hardware/computers
operation.
- Select
Try it out, and then select
Execute.
A list of 10 computers is returned by default.
- Optionally, use query parameters to refine the list:
page |
Specify the page number of
the result set to return per page. For example, if 105 computers are returned
and the page size is 10, page=1 returns items 1-10, page=5 returns items 41-50,
etc. |
pageSize |
Specify the number of line items to return. The default
setting is 10. |
sort |
Sort the list by field name
and order. Example:
- Name desc sorts the list by name in
descending order.
|
filter |
Limit the returned list
based on items that meet specific criteria. Examples:
- Name like "john*" returns only
computers with names that start with "john."
- not IsCamAgentInstalled returns
computers on which the CAM Agent has not been installed.
|
fields |
Include only data you care
about by adding fields. Examples:
- Name, DomainName, IsCamAgentInstalled,
OSPlatformName includes data for these fields and omits data for
all other fields.
|
- Optionally, combine parameters to fully refine your list.
- Select
Execute, and then compare the request URL to
the query parameters you provided.
This example is returned for these query parameters:
- page: 2
- pageSize: 15
- sort: Name desc
- filter: not IsCamAgentInstalled
- fields: Name, DomainName, OSPlatformName
https://{API host
name}/cam/api/v1/hardware/computers?page=2&pageSize=15&sort=Name%20desc&filter=not%20IsCamAgentInstalled&fields=Name%2C%20DomainName%2C%20OSPlatformName