| All Verbs | /api/suitedata |
|---|
<?php namespace dtos;
use DateTime;
use Exception;
use DateInterval;
use JsonSerializable;
use ServiceStack\{IReturn,IReturnVoid,IGet,IPost,IPut,IDelete,IPatch,IMeta,IHasSessionId,IHasBearerToken,IHasVersion};
use ServiceStack\{ICrud,ICreateDb,IUpdateDb,IPatchDb,IDeleteDb,ISaveDb,AuditBase,QueryDb,QueryDb2,QueryData,QueryData2,QueryResponse};
use ServiceStack\{ResponseStatus,ResponseError,EmptyResponse,IdResponse,ArrayList,KeyValuePair2,StringResponse,StringsResponse,Tuple2,Tuple3,ByteArray};
use ServiceStack\{JsonConverters,Returns,TypeContext};
// @ApiResponse(Description="Suite Appliance Data")
class GetSuiteDataResponse implements JsonSerializable
{
public function __construct(
/** @var string */
public string $SuiteApplianceLicenseeId='',
/** @var string|null */
public ?string $DomainName=null,
/** @var string|null */
public ?string $SkinName=null,
/** @var string */
public string $LicenseeConnectionId='',
/** @var string */
public string $LicenseeContactId='',
/** @var string|null */
public ?string $LicenseeContactName=null,
/** @var bool|null */
public ?bool $IsBrandedURL=null,
/** @var ResponseStatus|null */
public ?ResponseStatus $ResponseStatus=null
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['SuiteApplianceLicenseeId'])) $this->SuiteApplianceLicenseeId = $o['SuiteApplianceLicenseeId'];
if (isset($o['DomainName'])) $this->DomainName = $o['DomainName'];
if (isset($o['SkinName'])) $this->SkinName = $o['SkinName'];
if (isset($o['LicenseeConnectionId'])) $this->LicenseeConnectionId = $o['LicenseeConnectionId'];
if (isset($o['LicenseeContactId'])) $this->LicenseeContactId = $o['LicenseeContactId'];
if (isset($o['LicenseeContactName'])) $this->LicenseeContactName = $o['LicenseeContactName'];
if (isset($o['IsBrandedURL'])) $this->IsBrandedURL = $o['IsBrandedURL'];
if (isset($o['ResponseStatus'])) $this->ResponseStatus = JsonConverters::from('ResponseStatus', $o['ResponseStatus']);
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->SuiteApplianceLicenseeId)) $o['SuiteApplianceLicenseeId'] = $this->SuiteApplianceLicenseeId;
if (isset($this->DomainName)) $o['DomainName'] = $this->DomainName;
if (isset($this->SkinName)) $o['SkinName'] = $this->SkinName;
if (isset($this->LicenseeConnectionId)) $o['LicenseeConnectionId'] = $this->LicenseeConnectionId;
if (isset($this->LicenseeContactId)) $o['LicenseeContactId'] = $this->LicenseeContactId;
if (isset($this->LicenseeContactName)) $o['LicenseeContactName'] = $this->LicenseeContactName;
if (isset($this->IsBrandedURL)) $o['IsBrandedURL'] = $this->IsBrandedURL;
if (isset($this->ResponseStatus)) $o['ResponseStatus'] = JsonConverters::to('ResponseStatus', $this->ResponseStatus);
return empty($o) ? new class(){} : $o;
}
}
/** @description Gets the suite data for a particular licensee */
// @Api(Description="Gets the suite data for a particular licensee")
class GetSuiteDataForLicensee implements JsonSerializable
{
public function __construct(
/** @description The suite id */
// @ApiMember(Description="The suite id", Name="Suite Id")
/** @var string */
public string $SuiteId='',
/** @description The id of the licensee */
// @ApiMember(Description="The id of the licensee", Name="LicenseeId")
/** @var string */
public string $LicenseeId=''
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['SuiteId'])) $this->SuiteId = $o['SuiteId'];
if (isset($o['LicenseeId'])) $this->LicenseeId = $o['LicenseeId'];
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->SuiteId)) $o['SuiteId'] = $this->SuiteId;
if (isset($this->LicenseeId)) $o['LicenseeId'] = $this->LicenseeId;
return empty($o) ? new class(){} : $o;
}
}
PHP GetSuiteDataForLicensee DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /api/suitedata HTTP/1.1
Host: pfapi.pstpf.com.au
Accept: text/csv
Content-Type: text/csv
Content-Length: length
{"SuiteId":"00000000-0000-0000-0000-000000000000","LicenseeId":"00000000-0000-0000-0000-000000000000"}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length
{"SuiteApplianceLicenseeId":"00000000-0000-0000-0000-000000000000","DomainName":"String","SkinName":"String","LicenseeConnectionId":"00000000-0000-0000-0000-000000000000","LicenseeContactId":"00000000-0000-0000-0000-000000000000","LicenseeContactName":"String","IsBrandedURL":false,"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}