PHP Framework

Framework for integrating TBC E-Commerce

PHP Framework

Framework for integrating TBC E-Commerce



PHP Framework for integrating TBC E-Commerce Methods are available at the following Github repository where you can find:

  • How to use
  • Purchase Form
  • Savecard Form
  • Get Payment Info
  • Completion
  • Cancel
  • Execution
  • Delete

How to use

All examples require composer install before using after cloning from GitHub.


Purchase Form

See purchase.php

Run PHP built-in server
$ php -S localhost:8000
Then open http://localhost:8000/examples/purchase.php in browser.


Savecard Form

See savecard.php

Run PHP built-in server
$ php -S localhost:8000
Then open http://localhost:8000/examples/savecard.php in browser.


Get Payment Info

See paymentinfo.php
Response will be instance of GetPaymentInfo
Response Types 200: OK

$ php examples/paymentinfo.php 
Array
(
[payId] => iffv0yv*****11839
[status] => WaitingConfirm
[currency] => GEL
[amount] => 0.01
[confirmedAmount] => 0
[returnedAmount] => 0
[links] =>
[transactionId] => 773B12D3202570B*****46AD40BDB890
[paymentMethod] => 4
[preAuth] => 1
[recurringCard] =>
[httpStatusCode] => 200
[developerMessage] =>
[userMessage] =>

)

Completion

See completion.php
Response will be instance of CompletionPayment
Response Types 200: OK

$ php examples/completion.php 
Array
(
[status] => Succeeded
[amount] => 10
[confirmedAmount] => 10
[httpStatusCode] => 200
[developerMessage] =>
[userMessage] =>
)

Cancel

See cancel.php
Response will be instance of CancelPayment
Response Types 200: OK

$ php examples/cancel.php 
Array
(
[httpStatusCode] => 200
[developerMessage] =>
[userMessage] =>
)

Execution

See execution.php
Response will be instance of ExecutionPayment
Response Types 200: OK

$ php examples/execution.php 
Array
(
[payId] => 7md1c87*****118316
[status] => Succeeded
[currency] => GEL
[amount] => 0.02
[confirmedAmount] => 0.02
[returnedAmount] => 0
[links] =>
[transactionId] => CaWyrkBlaeO8wj*****Xkufn2Xs=
[paymentMethod] => 11
[preAuth] =>
[recurringCard] => Array
(
[recId] => E95011edFFFc4D4*****36493bD154B7
[cardMask] => 5***********9535
[expiryDate] => 0524
)
                                                                            
[httpStatusCode] => 200
[developerMessage] =>
[userMessage] =>
)

Delete

See delete.php
Response will be instance of DeletePayment
Response Types 200: OK

$ php examples/delete.php 
Array
(
[httpStatusCode] => 200
[developerMessage] =>
[userMessage] =>
)

Did this page help you?