Customers
User information
 Loading ...
Show article in Knowledge Base

 Examples using the API with PHP Export knowledge base Export     SubscribeSubscribe      Show article info

Log in:

$client = new SoapClient('http://www.visionflow.com/api/docs/service.wsdl', array('trace' => true, 'exceptions' => false));
$client->__setLocation('https://www.visionflow.com/service/VisionProject-v2/VisionProjectWebServiceService');

$systemUser = $client->loginWithAPIKey2(array(
'username' => '*****',
'password' => '*****',
'webserviceAPIKey' => '*****'
));
 

Find all customers:

$result = $client->findCustomers(array('queryObject' => array(
'accountManagerId' => 0,
'companyId' => 0,
'entityStatusId' => 0,
'parentCustomerId' => 0,
'primaryKey' => 0,
)));

 

 

Find all system users:

$result = $client->findSystemUsers(array('queryObject' => array(
'billingRate' => 0,
'companyId' => 0,
'costRate' => 0,
'customerId' => 0,
'datePresentationType' => 0,
'defaultNumberOfRows' => 0,
'defaultViewForProjects' => 0,
'enableEmailNotifications' => 0,
'enableEmailNotificationsHasBeenSet' => 0,
'enablePushNotifications' => 0,
'enablePushNotificationsHasBeenSet' => 0,
'firstDayInWeek' => 0,
'gender' => 0,
'genderHasBeenSet' => 0,
'primaryKey' => 0,
'receiveNewsLetter' => 0,
'receiveNewsLetterHasBeenSet' => 0,
'receiveSystemAnnouncements' => 0,
'receiveSystemAnnouncementsHasBeenSet' => 0,
'showGettingStartedHelp' => 0,
'showGettingStartedHelpHasBeenSet' => 0,
'userGroupId' => 0,
'userThumbnailEnabled' => 0,
'userThumbnailEnabledHasBeenSet' => 0,
'userTypeId' => 0,
'weeklyHours' => 0,
'workScheduleId' => 0,
)));

 

Find all issues in a specific project:

$result = $client->findProjectIssues(array('queryObject' => array(
'actualTime' => 0,
'billingAmount' => 0,
'buildNumber' => 0,
'componentId' => 0,
'containsRecipients' => 0,
'containsRecipientsHasBeenSet' => 0,
'costAmount' => 0,
'createdBySystemUserId' => 0,
'currentOwnerSystemUserId' => 0,
'currentOwnerUserGroupId' => 0,
'customerId' => 0,
'fixedPrice' => 0,
'fixedTime' => 0,
'isVoteable' => 0,
'isVoteableHasBeenSet' => 0,
'issueNotIncludedInRecurringSeries' => 0,
'issueNotIncludedInRecurringSeriesHasBeenSet' => 0,
'issuePriorityId' => 0,
'issueRank' => 0,
'issueResolutionId' => 0,
'issueSeverityId' => 0,
'issueStatusId' => 0,
'issueTemplateTypeId' => 0,
'issueTypeId' => 0,
'lastRepliedById' => 0,
'latestReplyIsBySupportUser' => 0,
'latestReplyIsBySupportUserHasBeenSet' => 0,
'mailSettingId' => 0,
'numberOfComments' => 0,
'numberOfSubIssues' => 0,
'originalEmailFormat' => 0,
'originalEstimatedTime' => 0,
'parentProjectIssueId' => 0,
'permissionType' => 0,
'primaryKey' => 0,
'productConfigItemId' => 0,
'projectId' => 17750,
'rating' => 0,
'recurringIssueTemplateProjectIssueId' => 0,
'releaseId' => 0,
'releaseVersionId' => 0,
'remainingTime' => 0,
'responsibleSystemUserId' => 0,
'SLAPlanId' => 0,
'storyPoints' => 0,
'subIssueOrder' => 0,
'subIssuesDoneInOrder' => 0,
'subIssuesDoneInOrderHasBeenSet' => 0,
'ticketId' => 0,
'votes' => 0,
)));
 

Perform some checks on the resulting issues:

foreach ($result->return as $row) {
if (($row->billingAmount || $row->parentProjectIssueId) && substr($row->completionDate, 0, 7) == date('Y-m')) {
if ($row->customerId == 0 && $row->createdBySystemUserId > 0) {
$result2 = $client->findSystemUsers(array('queryObject' => array(
'billingRate' => 0,
'companyId' => 0,
'costRate' => 0,
'customerId' => 0,
'datePresentationType' => 0,
'defaultNumberOfRows' => 0,
'defaultViewForProjects' => 0,
'enableEmailNotifications' => 0,
'enableEmailNotificationsHasBeenSet' => 0,
'enablePushNotifications' => 0,
'enablePushNotificationsHasBeenSet' => 0,
'firstDayInWeek' => 0,
'gender' => 0,
'genderHasBeenSet' => 0,
'primaryKey' => $row->createdBySystemUserId,
'receiveNewsLetter' => 0,
'receiveNewsLetterHasBeenSet' => 0,
'receiveSystemAnnouncements' => 0,
'receiveSystemAnnouncementsHasBeenSet' => 0,
'showGettingStartedHelp' => 0,
'showGettingStartedHelpHasBeenSet' => 0,
'userGroupId' => 0,
'userThumbnailEnabled' => 0,
'userThumbnailEnabledHasBeenSet' => 0,
'userTypeId' => 0,
'weeklyHours' => 0,
'workScheduleId' => 0,
)));
$row->customerId = $result2->return->customerId;
}
$_SESSION['tasks'][] = $row;
}
}

User comments
 Loading ...