Crate cwmanage[][src]

crate for working with Connectwise Manage API

In the connectwise api https://developer.connectwise.com/Products/Manage some results are returned as a single ‘object’ and most are returned as a list. Normally you will be getting a list of results (even a list of one) so you would use get. In some cases, (/system/info for example) it does not return a list, in this case use get_single. Consult the api documentation (above) for more details.

Query examples

See the connectwise api for further details

  • No query - [("", "")]
  • Only get the id field [("fields", "id")]
  • Also apply some conditions [("fields", "id"), ("conditions", "name LIKE '%foo%'")]

Structs

Credentials

authentication credentials for the connectwise api

Functions

get

GETs a path from the connectwise api. get will return all results so make sure you set your query with the appropriate conditions. This follows the api pagination so, again, all results will be returned For example /service/tickets will return every ticket in the system. The result is a vec of serde_json::value::Value

get_single

GETs a path from the connectwise api. get_single is only used on certain api endpoints. It is expecting the response from the connectwise api to be a single “object” and not a list like it normally returns