hsbc payme api demo
Go to file
2021-08-12 12:50:48 +08:00
.env.example init version 2021-08-12 12:50:48 +08:00
.gitignore init version 2021-08-12 12:50:48 +08:00
composer.json init version 2021-08-12 12:50:48 +08:00
example.php init version 2021-08-12 12:50:48 +08:00
README.MD init version 2021-08-12 12:50:48 +08:00

Contributors Forks Stargazers Issues

PayMe API Demo

Explore the docs »

View Demo · Report Bug · Request Feature

About The Project

PayMe API Flow

Built With

Getting Started

Prerequisites

Get your PayMe business account ready and Receive your API credentials

  • API Credentials consist of 4 parameters
    Client ID 
    Secret Key
    Signing Key ID
    Signing Key
    

Installation

  1. Get the PayMe API package
  2. Clone this repo
    git clone https://github.com/apphk/payme-api-demo
    
  3. Rename .env.example to .env and update the variables with your credentials
    CLIENT_ID = ''
    CLIENT_SECRET = ''
    SIGNING_KEY_ID = ''
    SIGNING_KEY = ''
    ...
    
  4. Install packages
    composer install
    
  5. Run example.php
    php example.php 
    

Usage

  • Init api client
    $client = new ApiClient($clientId, $clientSecret, $signingKeyId, $signingKey, $apiUrl);
    
  • Send payment request
    $response = $client->payment()->requests($request);
    
  • Get payment request status
    $response = $client->payment()->status($paymentRequestId);
    
  • Cancel payment request
    $response = $client->payment()->cancel($paymentRequestId);
    
  • Transactions
    $response = $client->payment()->transactions();
    
  • Get transaction by id
    $response = $client->payment()->transaction($transactionId);
    
  • Refunds
    $response = $client->payment()->refunds($transactionId, $refundsRequest);
    

For more api details, please refer to the Documentation

Roadmap

See the open issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Contact

Project team: https://hksay.com