UDDS OX API - documentation ver.2.5 (2023-04-07) ( www.dlaoperatora.pl )

Function onlinePaymentCreate

Payments service is deliverd by: KSI Payments API PROXY

Arguments

      $parameters = array(        
        [ 'apiServer' ] = '' ;             // (optional) default is defined in UDDS API config
        [ 'currency' ] = '' ;              // (optional) currency code default is 'PLN'
        [ 'languageCode' ] = '' ;          // (optional) default is 'pl'

        [ 'shopName' ]                     // (optional) depends of provider
        [ 'idSeller' ]                     // idSeller from gate-payments database ( table `seller` with configuration )
        [ 'transactionId' ] = '' ;         // id of transaction eg. invoice id or reservation webId.
        [ 'amount' ] = '' ;                // value
        [ 'description' ] = '' ;           // short description of transaction
        [ 'payerName' ] = '' ;             //
        [ 'payerSurname' ] = '' ;          //
        [ 'payerEmail' ] = '' ;            // where payment info will be send from payments provider
        [ 'returnUrl' ] = '' ;             // url where customer will be redirected after payment process

        [ 'idSource' ] = '' ;              // (optional) CRM source entity id
                                           // required to auto process
        [ 'source' ] = '' ;                // (optional) CRM entity name eg. R2 | OFERTY_WWW | FAKTURY etc ...
                                           // required to auto process
        [ 'secondaryCallbackUrl' ] = '' ;  // (optional) secondaryCallbackUrl
        [ 'extra' ] = array() ;            // (optional) secondaryCallbackUrl extra parameters
          

      )
      

Returns

Status information, created payment id (uuid) and payment form URL.
array (
  [ 'status' ] = 'OK',
  [ 'uuid' ] = 'xxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxx',
  [ 'url' ] = 'https://platnosciX.xx/pay.html?xxxxxxxxx'
)

Example


  require_once ( 'classUddsOx.php' ) ;

  $udds = new classUddsOx ;
  $udds->customerCode = [your_customerCode] ;
  $udds->login = [your_login] ;
  $udds->password = [your_password] ;
  $udds->serverUrl = 'http://api.dlaoperatora.pl/udds/' ;
 
  $myParams = array() ;
  $myParams [ 'shopName' ] = 'KSITEST' ;
  $myParams [ 'idSeller' ] = 1 ;
  $myParams [ 'transactionId' ] = 'UIYTYUHS3HS' ;
  $myParams [ 'amount' ] = 977.50 ;
  $myParams [ 'description' ] = 'Booking no: 879/12' ;
  $myParams [ 'payerName' ] = 'Marcin' ;
  $myParams [ 'payerSurname' ] = 'Kowalski' ;
  $myParams [ 'payerEmail' ] = 'xksi@xksi.pl' ;
  $myParams [ 'returnUrl' ] = 'https://demo.dlaoperatora.pl/reservation_UIYTYUHS3HS.html' ;
  $myParams [ 'source' ] = 'R2' ;
  $myParams [ 'idSource' ] = '785' ;       

  $ret = $udds->onlinePaymentCreate( $myParams ) ;  


Returns $ret =
array ( [ 'status' ] = 'OK', [ 'uuid' ] = 'xxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxx', [ 'url' ] = 'https://platnosciX.xx/pay.html?xxxxxxxxx' )