pixiReportActiveLogins
Returns the users currently logged in to Pixi that count against licences, optionally including mobile sessions.
Lists the active, licence-relevant logins from the latest login snapshot in UsersLoggedIn.
- The procedure first determines the latest snapshot timestamp (
Tag). It considers session types 1 and 2 (desktop/web), or types 1, 2, 4 and 5 ifIncludeMobileLicences= 1. - It then delegates to the internal procedure
Pixi_ShowConcurrentUsersForTagin distinct mode. That procedure recalculates the timestamp as the latestTagof session types 1 and 2 only. If there is no entry, it uses the current date and time. - Desktop/web sessions (types 1, 2) with that
Tagare included only if all of these apply:- their
AppNameis a client inExeClientVersionwithLicenceNeeded= 1; - the licence manager for that client type is enabled: setting
pixiLicencesManagerfor desktop (UserActiveSessionTypeRef= 1) orpixiLicencesManagerWebfor web (UserActiveSessionTypeRef= 2).
- their
- If
IncludeMobileLicences= 1, mobile sessions (types 4, 5) with the sameTagare added. - Computers listed in
MasterUsersand the Pixi usermasterare always excluded. - Rows are grouped per session and Pixi user, so each session appears once.
AppNameisDesktop/WeborMobile.ComputerNameis the maximum computer name of the session.
NrOfLicences contains the value of the setting pixiLicences if pixiLicencesManager is 1; otherwise it is 0.
Notes
- All reads use
NOLOCK, so results may include uncommitted data. - The timestamp computed by this procedure is overwritten inside
Pixi_ShowConcurrentUsersForTag, which always uses the latestTagof session types 1 and 2. Mobile sessions therefore appear only if theirTagequals that desktop/web timestamp. - If no licence manager setting (
pixiLicencesManager,pixiLicencesManagerWeb) is enabled, no desktop/web sessions are returned. UsersCountis always0, because the internal procedure is called with its default.- The result has no guaranteed sort order.
- If the setting
pixiLicencesManagerdoes not exist (NULL),NrOfLicencesis not reset to 0. It then reflectspixiLicences, as read byfpixi_GetSetting(definition not attached).
Tables used
| Parameter | Type | Default | Description |
|---|---|---|---|
IncludeMobileLicences
|
bit boolean |
0 |
Whether mobile sessions (session types 4 and 5) are included in the result. Allowed values
Example: |
Result set 1 · Always (may be empty)
One row per active licence-relevant session.
| Column | Type | Description |
|---|---|---|
OnDate
|
datetime dateTime |
Snapshot timestamp the logins refer to |
UsersCount
Nullable |
int |
Always 0 for this call |
Username
Nullable |
string |
Pixi user name of the session ( |
AppName
Nullable |
varchar(11) string |
Session kind: |
ComputerName
Nullable |
string |
Computer or login name of the session ( |
NrOfLicences
Nullable |
int |
Number of licences from setting |
Response example
<SqlRowSet1>
<row>
<OnDate>2024-05-14T10:15:00</OnDate>
<UsersCount>0</UsersCount>
<Username>mmueller</Username>
<AppName>Desktop/Web</AppName>
<ComputerName>WS-LAGER01</ComputerName>
<NrOfLicences>10</NrOfLicences>
</row>
<row>
<OnDate>2024-05-14T10:15:00</OnDate>
<UsersCount>0</UsersCount>
<Username>kschmidt</Username>
<AppName>Mobile</AppName>
<ComputerName>MDE-07</ComputerName>
<NrOfLicences>10</NrOfLicences>
</row>
</SqlRowSet1>
POST https://apigateway.descartes.com/tms/pixi/
Content-Type: text/xml; charset=utf-8
Authorization: Basic BASE64(USERNAME:PASSWORD)
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="https://apigateway.descartes.com/tms/pixi/">
<SOAP-ENV:Body>
<ns1:pixiReportActiveLogins>
<!-- <IncludeMobileLicences>1</IncludeMobileLicences> -->
</ns1:pixiReportActiveLogins>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
curl -X POST 'https://apigateway.descartes.com/tms/pixi/' \
--user 'USERNAME:PASSWORD' \
--header 'Content-Type: text/xml; charset=utf-8' \
--data-binary @- <<'XML'
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="https://apigateway.descartes.com/tms/pixi/">
<SOAP-ENV:Body>
<ns1:pixiReportActiveLogins>
<!-- <IncludeMobileLicences>1</IncludeMobileLicences> -->
</ns1:pixiReportActiveLogins>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
XML
<?php
$soapClient = new SoapClient(null, [
'login' => 'USERNAME',
'password' => 'PASSWORD',
'location' => 'https://apigateway.descartes.com/tms/pixi/',
'uri' => 'https://apigateway.descartes.com/tms/pixi/',
]);
$arguments = [
// 'IncludeMobileLicences' => '1',
];
$soapArguments = [];
foreach ($arguments as $name => $value) {
$soapArguments[] = new SoapVar($value, XSD_STRING, '', '', $name);
}
$response = $soapClient->__soapCall('pixiReportActiveLogins', $soapArguments);
- SQL object:
- dbo.pipiReportActiveLogins