RAPP.BW.MovableInk

<back to all web services

RequestMemberbyGUID

Requires Authentication
The following routes are available for this service:
All Verbs/RequestMemberbyGUID
<?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 MemberData implements JsonSerializable
{
    public function __construct(
        /** @var string|null */
        public ?string $MemberSummaryId=null,
        /** @var string|null */
        public ?string $MemberId=null,
        /** @var string|null */
        public ?string $MemberStatus=null,
        /** @var string|null */
        public ?string $ClubCode=null,
        /** @var string|null */
        public ?string $TierCode=null,
        /** @var int */
        public int $YtdBasePoints=0,
        /** @var int */
        public int $YtdNightCount=0,
        /** @var int */
        public int $PointsToNextTier=0,
        /** @var int */
        public int $NightsToNextTier=0,
        /** @var string|null */
        public ?string $ProgramCode=null,
        /** @var int */
        public int $CurrentPoints=0,
        /** @var int */
        public int $TotalBasePoints=0,
        /** @var int */
        public int $TotalBonusPoints=0,
        /** @var int|null */
        public ?int $YTDStayCount=null,
        /** @var string|null */
        public ?string $Surname=null,
        /** @var string|null */
        public ?string $Forename=null,
        /** @var int|null */
        public ?int $StaysToNextTier=null,
        /** @var string|null */
        public ?string $LanguagePreference=null,
        /** @var string|null */
        public ?string $CountryName=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['MemberSummaryId'])) $this->MemberSummaryId = $o['MemberSummaryId'];
        if (isset($o['MemberId'])) $this->MemberId = $o['MemberId'];
        if (isset($o['MemberStatus'])) $this->MemberStatus = $o['MemberStatus'];
        if (isset($o['ClubCode'])) $this->ClubCode = $o['ClubCode'];
        if (isset($o['TierCode'])) $this->TierCode = $o['TierCode'];
        if (isset($o['YtdBasePoints'])) $this->YtdBasePoints = $o['YtdBasePoints'];
        if (isset($o['YtdNightCount'])) $this->YtdNightCount = $o['YtdNightCount'];
        if (isset($o['PointsToNextTier'])) $this->PointsToNextTier = $o['PointsToNextTier'];
        if (isset($o['NightsToNextTier'])) $this->NightsToNextTier = $o['NightsToNextTier'];
        if (isset($o['ProgramCode'])) $this->ProgramCode = $o['ProgramCode'];
        if (isset($o['CurrentPoints'])) $this->CurrentPoints = $o['CurrentPoints'];
        if (isset($o['TotalBasePoints'])) $this->TotalBasePoints = $o['TotalBasePoints'];
        if (isset($o['TotalBonusPoints'])) $this->TotalBonusPoints = $o['TotalBonusPoints'];
        if (isset($o['YTDStayCount'])) $this->YTDStayCount = $o['YTDStayCount'];
        if (isset($o['Surname'])) $this->Surname = $o['Surname'];
        if (isset($o['Forename'])) $this->Forename = $o['Forename'];
        if (isset($o['StaysToNextTier'])) $this->StaysToNextTier = $o['StaysToNextTier'];
        if (isset($o['LanguagePreference'])) $this->LanguagePreference = $o['LanguagePreference'];
        if (isset($o['CountryName'])) $this->CountryName = $o['CountryName'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->MemberSummaryId)) $o['MemberSummaryId'] = $this->MemberSummaryId;
        if (isset($this->MemberId)) $o['MemberId'] = $this->MemberId;
        if (isset($this->MemberStatus)) $o['MemberStatus'] = $this->MemberStatus;
        if (isset($this->ClubCode)) $o['ClubCode'] = $this->ClubCode;
        if (isset($this->TierCode)) $o['TierCode'] = $this->TierCode;
        if (isset($this->YtdBasePoints)) $o['YtdBasePoints'] = $this->YtdBasePoints;
        if (isset($this->YtdNightCount)) $o['YtdNightCount'] = $this->YtdNightCount;
        if (isset($this->PointsToNextTier)) $o['PointsToNextTier'] = $this->PointsToNextTier;
        if (isset($this->NightsToNextTier)) $o['NightsToNextTier'] = $this->NightsToNextTier;
        if (isset($this->ProgramCode)) $o['ProgramCode'] = $this->ProgramCode;
        if (isset($this->CurrentPoints)) $o['CurrentPoints'] = $this->CurrentPoints;
        if (isset($this->TotalBasePoints)) $o['TotalBasePoints'] = $this->TotalBasePoints;
        if (isset($this->TotalBonusPoints)) $o['TotalBonusPoints'] = $this->TotalBonusPoints;
        if (isset($this->YTDStayCount)) $o['YTDStayCount'] = $this->YTDStayCount;
        if (isset($this->Surname)) $o['Surname'] = $this->Surname;
        if (isset($this->Forename)) $o['Forename'] = $this->Forename;
        if (isset($this->StaysToNextTier)) $o['StaysToNextTier'] = $this->StaysToNextTier;
        if (isset($this->LanguagePreference)) $o['LanguagePreference'] = $this->LanguagePreference;
        if (isset($this->CountryName)) $o['CountryName'] = $this->CountryName;
        return empty($o) ? new class(){} : $o;
    }
}

// @DataContract
class Response implements JsonSerializable
{
    public function __construct(
        // @DataMember
        /** @var bool|null */
        public ?bool $HasError=null,

        // @DataMember
        /** @var string|null */
        public ?string $Error=null,

        // @DataMember
        /** @var MemberData|null */
        public ?MemberData $MemberData=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['HasError'])) $this->HasError = $o['HasError'];
        if (isset($o['Error'])) $this->Error = $o['Error'];
        if (isset($o['MemberData'])) $this->MemberData = JsonConverters::from('MemberData', $o['MemberData']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->HasError)) $o['HasError'] = $this->HasError;
        if (isset($this->Error)) $o['Error'] = $this->Error;
        if (isset($this->MemberData)) $o['MemberData'] = JsonConverters::to('MemberData', $this->MemberData);
        return empty($o) ? new class(){} : $o;
    }
}

// @DataContract
class RequestMemberbyGUID implements JsonSerializable
{
    public function __construct(
        // @DataMember
        /** @var string|null */
        public ?string $MemberGUID=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['MemberGUID'])) $this->MemberGUID = $o['MemberGUID'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->MemberGUID)) $o['MemberGUID'] = $this->MemberGUID;
        return empty($o) ? new class(){} : $o;
    }
}

PHP RequestMemberbyGUID DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /RequestMemberbyGUID HTTP/1.1 
Host: bwdynamicsuat.rapp-customers.co.uk 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<RequestMemberbyGUID xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RAPP.BW.MovableInk">
  <MemberGUID>String</MemberGUID>
</RequestMemberbyGUID>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<Response xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RAPP.BW.MovableInk">
  <Error>String</Error>
  <HasError>false</HasError>
  <MemberData>
    <ClubCode>String</ClubCode>
    <CountryName>String</CountryName>
    <CurrentPoints>0</CurrentPoints>
    <Forename>String</Forename>
    <LanguagePreference>String</LanguagePreference>
    <MemberId>String</MemberId>
    <MemberStatus>String</MemberStatus>
    <MemberSummaryId>String</MemberSummaryId>
    <NightsToNextTier>0</NightsToNextTier>
    <PointsToNextTier>0</PointsToNextTier>
    <ProgramCode>String</ProgramCode>
    <StaysToNextTier>0</StaysToNextTier>
    <Surname>String</Surname>
    <TierCode>String</TierCode>
    <TotalBasePoints>0</TotalBasePoints>
    <TotalBonusPoints>0</TotalBonusPoints>
    <YTDStayCount>0</YTDStayCount>
    <YtdBasePoints>0</YtdBasePoints>
    <YtdNightCount>0</YtdNightCount>
  </MemberData>
</Response>