Spinen's PHP ConnectWise Client for Sales API generated by Swagger Code Generator.
All URIs are relative to https://api-na.myconnectwise.net/v4_6_release/apis/3.0
Method | HTTP request | Description |
---|---|---|
salesRolesCountGet | GET /sales/roles/count | |
salesRolesGet | GET /sales/roles | |
salesRolesIdDelete | DELETE /sales/roles/{id} | |
salesRolesIdGet | GET /sales/roles/{id} | |
salesRolesIdPatch | PATCH /sales/roles/{id} | |
salesRolesIdPut | PUT /sales/roles/{id} | |
salesRolesPost | POST /sales/roles |
\Spinen\ConnectWise\Clients\Sales\Model\Count salesRolesCountGet($conditions)
Get Role Count
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: BasicAuth
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Spinen\ConnectWise\Clients\Sales\Api\RolesApi();
$conditions = "conditions_example"; // string |
try {
$result = $api_instance->salesRolesCountGet($conditions);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling RolesApi->salesRolesCountGet: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
conditions | string | [optional] |
\Spinen\ConnectWise\Clients\Sales\Model\Count
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Spinen\ConnectWise\Clients\Sales\Model\Role[] salesRolesGet($conditions, $order_by, $childconditions, $customfieldconditions, $page, $page_size)
Get Role
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: BasicAuth
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Spinen\ConnectWise\Clients\Sales\Api\RolesApi();
$conditions = "conditions_example"; // string |
$order_by = "order_by_example"; // string |
$childconditions = "childconditions_example"; // string |
$customfieldconditions = "customfieldconditions_example"; // string |
$page = 56; // int |
$page_size = 56; // int |
try {
$result = $api_instance->salesRolesGet($conditions, $order_by, $childconditions, $customfieldconditions, $page, $page_size);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling RolesApi->salesRolesGet: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
conditions | string | [optional] | |
order_by | string | [optional] | |
childconditions | string | [optional] | |
customfieldconditions | string | [optional] | |
page | int | [optional] | |
page_size | int | [optional] |
\Spinen\ConnectWise\Clients\Sales\Model\Role[]
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
salesRolesIdDelete($id)
Delete Role By Id
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: BasicAuth
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Spinen\ConnectWise\Clients\Sales\Api\RolesApi();
$id = 56; // int |
try {
$api_instance->salesRolesIdDelete($id);
} catch (Exception $e) {
echo 'Exception when calling RolesApi->salesRolesIdDelete: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
id | int |
void (empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Spinen\ConnectWise\Clients\Sales\Model\Role salesRolesIdGet($id)
Get Role By Id
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: BasicAuth
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Spinen\ConnectWise\Clients\Sales\Api\RolesApi();
$id = 56; // int |
try {
$result = $api_instance->salesRolesIdGet($id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling RolesApi->salesRolesIdGet: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
id | int |
\Spinen\ConnectWise\Clients\Sales\Model\Role
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Spinen\ConnectWise\Clients\Sales\Model\Role salesRolesIdPatch($id, $operations)
Update Role
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: BasicAuth
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Spinen\ConnectWise\Clients\Sales\Api\RolesApi();
$id = 56; // int |
$operations = array(new PatchOperation()); // \Spinen\ConnectWise\Clients\Sales\Model\PatchOperation[] |
try {
$result = $api_instance->salesRolesIdPatch($id, $operations);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling RolesApi->salesRolesIdPatch: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
id | int | ||
operations | \Spinen\ConnectWise\Clients\Sales\Model\PatchOperation[] |
\Spinen\ConnectWise\Clients\Sales\Model\Role
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Spinen\ConnectWise\Clients\Sales\Model\Role salesRolesIdPut($id, $role)
Replace Role
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: BasicAuth
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Spinen\ConnectWise\Clients\Sales\Api\RolesApi();
$id = 56; // int |
$role = new \Spinen\ConnectWise\Clients\Sales\Model\Role(); // \Spinen\ConnectWise\Clients\Sales\Model\Role |
try {
$result = $api_instance->salesRolesIdPut($id, $role);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling RolesApi->salesRolesIdPut: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
id | int | ||
role | \Spinen\ConnectWise\Clients\Sales\Model\Role |
\Spinen\ConnectWise\Clients\Sales\Model\Role
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
\Spinen\ConnectWise\Clients\Sales\Model\Role salesRolesPost($role)
Create Role
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: BasicAuth
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Spinen\ConnectWise\Clients\Sales\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
$api_instance = new Spinen\ConnectWise\Clients\Sales\Api\RolesApi();
$role = new \Spinen\ConnectWise\Clients\Sales\Model\Role(); // \Spinen\ConnectWise\Clients\Sales\Model\Role |
try {
$result = $api_instance->salesRolesPost($role);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling RolesApi->salesRolesPost: ', $e->getMessage(), PHP_EOL;
}
?>
Name | Type | Description | Notes |
---|---|---|---|
role | \Spinen\ConnectWise\Clients\Sales\Model\Role |
\Spinen\ConnectWise\Clients\Sales\Model\Role
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]