amabnl / amadeus-ws-client

PHP Amadeus SOAP Web Service client library
Apache License 2.0
183 stars 191 forks source link

Create Form of payment after PNR_AddMultiElements #455

Closed ERaufi closed 2 years ago

ERaufi commented 2 years ago

I am trying to create form of payment after PNR_AddMultiElements but when I call it it gives me this error

[ { "code": "25779", "text": "ERROR(S) DETECTED AT CREATION TIME", "level": "general" }, { "code": "1949", "text": "PASSENGER AND/OR SEGMENT DATA NOT VALID", "level": "fp" } ]

my code

$optOfFormOfPayment = new FopCreateFopOptions([ 'transactionCode' => FopCreateFopOptions::TRANS_CREATE_FORM_OF_PAYMENT, 'fopGroup' => [ new Group([ 'paxRef' => [ new PaxRef([ 'type' => PaxRef::TYPE_ADULT, 'value' => 1 ]) ], 'mopInfo' => [ new MopInfo([ 'sequenceNr' => 1, 'fopCode' => 'VI', 'fopType' => MopInfo::FOPTYPE_FP_ELEMENT, 'mopPaymentType' => MopInfo::MOP_PAY_TYPE_CREDIT_CARD, 'creditCardInfo' => new CreditCardInfo([ 'vendorCode' => 'VI', 'cardNumber' => '4541099100010016', 'expiryDate' => '0913', ]) ]) ] ]) ] ]); $msg = $client->fopCreateFormOfPayment($optOfFormOfPayment);

responseXml

`

257793M1ERROR(S) DETECTED AT CREATION TIMEPAX119493M1PASSENGER AND/OR SEGMENT DATA NOT VALID1VINFPCCVIXXXXXXXXXXXX00160930CC

`