| All Verbs | /GetInbox |
|---|
<?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};
class RemMsgEvidence implements JsonSerializable
{
public function __construct(
/** @var int */
public int $RemMessageEvidenceId=0,
/** @var int|null */
public ?int $RemId=null,
/** @var int|null */
public ?int $EvidenceTypeId=null,
/** @var int|null */
public ?int $EvidenceCodeId=null,
/** @var string|null */
public ?string $EvidenceRemSubject=null,
/** @var string|null */
public ?string $EvidenceMessageID=null,
/** @var DateTime|null */
public ?DateTime $EvidenceDate=null
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['RemMessageEvidenceId'])) $this->RemMessageEvidenceId = $o['RemMessageEvidenceId'];
if (isset($o['RemId'])) $this->RemId = $o['RemId'];
if (isset($o['EvidenceTypeId'])) $this->EvidenceTypeId = $o['EvidenceTypeId'];
if (isset($o['EvidenceCodeId'])) $this->EvidenceCodeId = $o['EvidenceCodeId'];
if (isset($o['EvidenceRemSubject'])) $this->EvidenceRemSubject = $o['EvidenceRemSubject'];
if (isset($o['EvidenceMessageID'])) $this->EvidenceMessageID = $o['EvidenceMessageID'];
if (isset($o['EvidenceDate'])) $this->EvidenceDate = JsonConverters::from('DateTime', $o['EvidenceDate']);
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->RemMessageEvidenceId)) $o['RemMessageEvidenceId'] = $this->RemMessageEvidenceId;
if (isset($this->RemId)) $o['RemId'] = $this->RemId;
if (isset($this->EvidenceTypeId)) $o['EvidenceTypeId'] = $this->EvidenceTypeId;
if (isset($this->EvidenceCodeId)) $o['EvidenceCodeId'] = $this->EvidenceCodeId;
if (isset($this->EvidenceRemSubject)) $o['EvidenceRemSubject'] = $this->EvidenceRemSubject;
if (isset($this->EvidenceMessageID)) $o['EvidenceMessageID'] = $this->EvidenceMessageID;
if (isset($this->EvidenceDate)) $o['EvidenceDate'] = JsonConverters::to('DateTime', $this->EvidenceDate);
return empty($o) ? new class(){} : $o;
}
}
class RemMsgDelivery implements JsonSerializable
{
public function __construct(
/** @var int */
public int $RemDeliveryId=0,
/** @var int */
public int $RemId=0,
/** @var string|null */
public ?string $AddressType=null,
/** @var string|null */
public ?string $RemDisplayName=null,
/** @var string|null */
public ?string $RemAddress=null,
/** @var string|null */
public ?string $Status=null,
/** @var int|null */
public ?int $RemSPId=null,
/** @var int */
public int $SystemAcceptance=0,
/** @var DateTime|null */
public ?DateTime $SystemAcceptanceDate=null,
/** @var int */
public int $RecipientAcceptance=0,
/** @var DateTime|null */
public ?DateTime $RecipientAcceptanceDate=null,
/** @var int */
public int $Delivered=0,
/** @var DateTime|null */
public ?DateTime $DeliveredDate=null,
/** @var int */
public int $Read=0,
/** @var DateTime|null */
public ?DateTime $ReadDate=null
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['RemDeliveryId'])) $this->RemDeliveryId = $o['RemDeliveryId'];
if (isset($o['RemId'])) $this->RemId = $o['RemId'];
if (isset($o['AddressType'])) $this->AddressType = $o['AddressType'];
if (isset($o['RemDisplayName'])) $this->RemDisplayName = $o['RemDisplayName'];
if (isset($o['RemAddress'])) $this->RemAddress = $o['RemAddress'];
if (isset($o['Status'])) $this->Status = $o['Status'];
if (isset($o['RemSPId'])) $this->RemSPId = $o['RemSPId'];
if (isset($o['SystemAcceptance'])) $this->SystemAcceptance = $o['SystemAcceptance'];
if (isset($o['SystemAcceptanceDate'])) $this->SystemAcceptanceDate = JsonConverters::from('DateTime', $o['SystemAcceptanceDate']);
if (isset($o['RecipientAcceptance'])) $this->RecipientAcceptance = $o['RecipientAcceptance'];
if (isset($o['RecipientAcceptanceDate'])) $this->RecipientAcceptanceDate = JsonConverters::from('DateTime', $o['RecipientAcceptanceDate']);
if (isset($o['Delivered'])) $this->Delivered = $o['Delivered'];
if (isset($o['DeliveredDate'])) $this->DeliveredDate = JsonConverters::from('DateTime', $o['DeliveredDate']);
if (isset($o['Read'])) $this->Read = $o['Read'];
if (isset($o['ReadDate'])) $this->ReadDate = JsonConverters::from('DateTime', $o['ReadDate']);
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->RemDeliveryId)) $o['RemDeliveryId'] = $this->RemDeliveryId;
if (isset($this->RemId)) $o['RemId'] = $this->RemId;
if (isset($this->AddressType)) $o['AddressType'] = $this->AddressType;
if (isset($this->RemDisplayName)) $o['RemDisplayName'] = $this->RemDisplayName;
if (isset($this->RemAddress)) $o['RemAddress'] = $this->RemAddress;
if (isset($this->Status)) $o['Status'] = $this->Status;
if (isset($this->RemSPId)) $o['RemSPId'] = $this->RemSPId;
if (isset($this->SystemAcceptance)) $o['SystemAcceptance'] = $this->SystemAcceptance;
if (isset($this->SystemAcceptanceDate)) $o['SystemAcceptanceDate'] = JsonConverters::to('DateTime', $this->SystemAcceptanceDate);
if (isset($this->RecipientAcceptance)) $o['RecipientAcceptance'] = $this->RecipientAcceptance;
if (isset($this->RecipientAcceptanceDate)) $o['RecipientAcceptanceDate'] = JsonConverters::to('DateTime', $this->RecipientAcceptanceDate);
if (isset($this->Delivered)) $o['Delivered'] = $this->Delivered;
if (isset($this->DeliveredDate)) $o['DeliveredDate'] = JsonConverters::to('DateTime', $this->DeliveredDate);
if (isset($this->Read)) $o['Read'] = $this->Read;
if (isset($this->ReadDate)) $o['ReadDate'] = JsonConverters::to('DateTime', $this->ReadDate);
return empty($o) ? new class(){} : $o;
}
}
class ViewedRemMessage implements JsonSerializable
{
public function __construct(
/** @var int */
public int $kepId=0,
/** @var string|null */
public ?string $kepCC=null,
/** @var string|null */
public ?string $kepEventCode=null,
/** @var string|null */
public ?string $kepEvidenceType=null,
/** @var string|null */
public ?string $kepFrom=null,
/** @var string|null */
public ?string $kepIleti=null,
/** @var string|null */
public ?string $kepMessageID=null,
/** @var string|null */
public ?string $kepMsgType=null,
/** @var DateTime */
public DateTime $kepReceivedDate=new DateTime(),
/** @var bool|null */
public ?bool $kepReceivedDateSpecified=null,
/** @var DateTime */
public DateTime $kepSendDate=new DateTime(),
/** @var bool|null */
public ?bool $kepSendDateSpecified=null,
/** @var string|null */
public ?string $kepSubject=null,
/** @var string|null */
public ?string $kepTo=null,
/** @var string|null */
public ?string $kepTRgunSayac=null,
/** @var string|null */
public ?string $kepTRIletiID=null,
/** @var string|null */
public ?string $kepTRIletiTip=null,
/** @var string|null */
public ?string $kepUAMessageIdentifier=null,
/** @var string|null */
public ?string $status=null,
/** @var array<RemMsgEvidence>|null */
public ?array $kepDelilListesi=null,
/** @var array<RemMsgDelivery>|null */
public ?array $kepTeslimalListesi=null
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['kepId'])) $this->kepId = $o['kepId'];
if (isset($o['kepCC'])) $this->kepCC = $o['kepCC'];
if (isset($o['kepEventCode'])) $this->kepEventCode = $o['kepEventCode'];
if (isset($o['kepEvidenceType'])) $this->kepEvidenceType = $o['kepEvidenceType'];
if (isset($o['kepFrom'])) $this->kepFrom = $o['kepFrom'];
if (isset($o['kepIleti'])) $this->kepIleti = $o['kepIleti'];
if (isset($o['kepMessageID'])) $this->kepMessageID = $o['kepMessageID'];
if (isset($o['kepMsgType'])) $this->kepMsgType = $o['kepMsgType'];
if (isset($o['kepReceivedDate'])) $this->kepReceivedDate = JsonConverters::from('DateTime', $o['kepReceivedDate']);
if (isset($o['kepReceivedDateSpecified'])) $this->kepReceivedDateSpecified = $o['kepReceivedDateSpecified'];
if (isset($o['kepSendDate'])) $this->kepSendDate = JsonConverters::from('DateTime', $o['kepSendDate']);
if (isset($o['kepSendDateSpecified'])) $this->kepSendDateSpecified = $o['kepSendDateSpecified'];
if (isset($o['kepSubject'])) $this->kepSubject = $o['kepSubject'];
if (isset($o['kepTo'])) $this->kepTo = $o['kepTo'];
if (isset($o['kepTRgunSayac'])) $this->kepTRgunSayac = $o['kepTRgunSayac'];
if (isset($o['kepTRIletiID'])) $this->kepTRIletiID = $o['kepTRIletiID'];
if (isset($o['kepTRIletiTip'])) $this->kepTRIletiTip = $o['kepTRIletiTip'];
if (isset($o['kepUAMessageIdentifier'])) $this->kepUAMessageIdentifier = $o['kepUAMessageIdentifier'];
if (isset($o['status'])) $this->status = $o['status'];
if (isset($o['kepDelilListesi'])) $this->kepDelilListesi = JsonConverters::fromArray('RemMsgEvidence', $o['kepDelilListesi']);
if (isset($o['kepTeslimalListesi'])) $this->kepTeslimalListesi = JsonConverters::fromArray('RemMsgDelivery', $o['kepTeslimalListesi']);
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->kepId)) $o['kepId'] = $this->kepId;
if (isset($this->kepCC)) $o['kepCC'] = $this->kepCC;
if (isset($this->kepEventCode)) $o['kepEventCode'] = $this->kepEventCode;
if (isset($this->kepEvidenceType)) $o['kepEvidenceType'] = $this->kepEvidenceType;
if (isset($this->kepFrom)) $o['kepFrom'] = $this->kepFrom;
if (isset($this->kepIleti)) $o['kepIleti'] = $this->kepIleti;
if (isset($this->kepMessageID)) $o['kepMessageID'] = $this->kepMessageID;
if (isset($this->kepMsgType)) $o['kepMsgType'] = $this->kepMsgType;
if (isset($this->kepReceivedDate)) $o['kepReceivedDate'] = JsonConverters::to('DateTime', $this->kepReceivedDate);
if (isset($this->kepReceivedDateSpecified)) $o['kepReceivedDateSpecified'] = $this->kepReceivedDateSpecified;
if (isset($this->kepSendDate)) $o['kepSendDate'] = JsonConverters::to('DateTime', $this->kepSendDate);
if (isset($this->kepSendDateSpecified)) $o['kepSendDateSpecified'] = $this->kepSendDateSpecified;
if (isset($this->kepSubject)) $o['kepSubject'] = $this->kepSubject;
if (isset($this->kepTo)) $o['kepTo'] = $this->kepTo;
if (isset($this->kepTRgunSayac)) $o['kepTRgunSayac'] = $this->kepTRgunSayac;
if (isset($this->kepTRIletiID)) $o['kepTRIletiID'] = $this->kepTRIletiID;
if (isset($this->kepTRIletiTip)) $o['kepTRIletiTip'] = $this->kepTRIletiTip;
if (isset($this->kepUAMessageIdentifier)) $o['kepUAMessageIdentifier'] = $this->kepUAMessageIdentifier;
if (isset($this->status)) $o['status'] = $this->status;
if (isset($this->kepDelilListesi)) $o['kepDelilListesi'] = JsonConverters::toArray('RemMsgEvidence', $this->kepDelilListesi);
if (isset($this->kepTeslimalListesi)) $o['kepTeslimalListesi'] = JsonConverters::toArray('RemMsgDelivery', $this->kepTeslimalListesi);
return empty($o) ? new class(){} : $o;
}
}
class GetInboxResponse implements JsonSerializable
{
public function __construct(
/** @var array<ViewedRemMessage>|null */
public ?array $Result=null,
/** @var bool|null */
public ?bool $ServiceSuccessResult=null,
/** @var string|null */
public ?string $ErrorMesage=null
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['Result'])) $this->Result = JsonConverters::fromArray('ViewedRemMessage', $o['Result']);
if (isset($o['ServiceSuccessResult'])) $this->ServiceSuccessResult = $o['ServiceSuccessResult'];
if (isset($o['ErrorMesage'])) $this->ErrorMesage = $o['ErrorMesage'];
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->Result)) $o['Result'] = JsonConverters::toArray('ViewedRemMessage', $this->Result);
if (isset($this->ServiceSuccessResult)) $o['ServiceSuccessResult'] = $this->ServiceSuccessResult;
if (isset($this->ErrorMesage)) $o['ErrorMesage'] = $this->ErrorMesage;
return empty($o) ? new class(){} : $o;
}
}
class GetInbox implements JsonSerializable
{
public function __construct(
/** @var string|null */
public ?string $AuthorizationID=null,
/** @var string|null */
public ?string $ClientKey=null,
/** @var int */
public int $RemAdressID=0,
/** @var int */
public int $LastRemID=0,
/** @var DateTime */
public DateTime $DateBegin=new DateTime(),
/** @var DateTime */
public DateTime $DateEnd=new DateTime(),
/** @var int|null */
public ?int $CurrentRemID=null
) {
}
/** @throws Exception */
public function fromMap($o): void {
if (isset($o['AuthorizationID'])) $this->AuthorizationID = $o['AuthorizationID'];
if (isset($o['ClientKey'])) $this->ClientKey = $o['ClientKey'];
if (isset($o['RemAdressID'])) $this->RemAdressID = $o['RemAdressID'];
if (isset($o['LastRemID'])) $this->LastRemID = $o['LastRemID'];
if (isset($o['DateBegin'])) $this->DateBegin = JsonConverters::from('DateTime', $o['DateBegin']);
if (isset($o['DateEnd'])) $this->DateEnd = JsonConverters::from('DateTime', $o['DateEnd']);
if (isset($o['CurrentRemID'])) $this->CurrentRemID = $o['CurrentRemID'];
}
/** @throws Exception */
public function jsonSerialize(): mixed
{
$o = [];
if (isset($this->AuthorizationID)) $o['AuthorizationID'] = $this->AuthorizationID;
if (isset($this->ClientKey)) $o['ClientKey'] = $this->ClientKey;
if (isset($this->RemAdressID)) $o['RemAdressID'] = $this->RemAdressID;
if (isset($this->LastRemID)) $o['LastRemID'] = $this->LastRemID;
if (isset($this->DateBegin)) $o['DateBegin'] = JsonConverters::to('DateTime', $this->DateBegin);
if (isset($this->DateEnd)) $o['DateEnd'] = JsonConverters::to('DateTime', $this->DateEnd);
if (isset($this->CurrentRemID)) $o['CurrentRemID'] = $this->CurrentRemID;
return empty($o) ? new class(){} : $o;
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /GetInbox HTTP/1.1
Host: remservices.eyyubiye.bel.tr
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
AuthorizationID: String,
ClientKey: String,
RemAdressID: 0,
LastRemID: 0,
DateBegin: 0001-01-01,
DateEnd: 0001-01-01,
CurrentRemID: 0
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
Result:
[
{
kepId: 0,
kepCC: String,
kepEventCode: String,
kepEvidenceType: String,
kepFrom: String,
kepIleti: String,
kepMessageID: String,
kepMsgType: String,
kepReceivedDate: 0001-01-01,
kepReceivedDateSpecified: False,
kepSendDate: 0001-01-01,
kepSendDateSpecified: False,
kepSubject: String,
kepTo: String,
kepTRgunSayac: String,
kepTRIletiID: String,
kepTRIletiTip: String,
kepUAMessageIdentifier: String,
status: String,
kepDelilListesi:
[
{
RemMessageEvidenceId: 0,
RemId: 0,
EvidenceTypeId: 0,
EvidenceCodeId: 0,
EvidenceRemSubject: String,
EvidenceMessageID: String,
EvidenceDate: 0001-01-01
}
],
kepTeslimalListesi:
[
{
RemDeliveryId: 0,
RemId: 0,
AddressType: String,
RemDisplayName: String,
RemAddress: String,
Status: String,
RemSPId: 0,
SystemAcceptance: 0,
SystemAcceptanceDate: 0001-01-01,
RecipientAcceptance: 0,
RecipientAcceptanceDate: 0001-01-01,
Delivered: 0,
DeliveredDate: 0001-01-01,
Read: 0,
ReadDate: 0001-01-01
}
]
}
],
ServiceSuccessResult: False,
ErrorMesage: String
}