Download the PHP package pkomjit/omise-php without Composer

On this page you can find all versions of the php package pkomjit/omise-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package omise-php

Omise PHP SDK

A PHP SDK for Omise payment gateway integration. Supports both standalone PHP and Laravel applications.

Unofficial package. This is a community-maintained SDK and is not affiliated with or endorsed by Omise / Opn Payments. For the official library see omise/omise-php.

Features

Supported Payment Methods

Payment Method Type Country Currency Limits Docs
Credit Card Card/3DS Multi Multi Varies docs/credit-card.md
PromptPay QR Code Thailand THB 20 - 150,000 THB docs/promptpay.md
Rabbit LINE Pay Redirect Thailand THB 20 - 150,000 THB docs/rabbit-linepay.md
Direct Debit Bank Link Thailand THB 20 - 150,000 THB docs/direct-debit.md
Mobile Banking App Redirect Thailand/Singapore THB/SGD Varies by bank docs/mobile-banking.md
ShopeePay QR Redirect Thailand/Singapore/Malaysia THB/SGD/MYR Varies by country docs/shopeepay-qr.md
ShopeePay App App Redirect Thailand/Singapore/Malaysia THB/SGD/MYR Varies by country docs/shopeepay-jumpapp.md
TrueMoney QR QR Code Thailand THB 100 - 50,000 THB docs/truemoney-qr.md
TrueMoney App App Redirect Thailand THB 100 - 50,000 THB docs/truemoney-jumpapp.md

Supported Currencies (Multi-Currency)

Currency Country Limits (min - max)
THB Thailand 20 - 150,000
USD USA 1 - 50,000
EUR Europe 1 - 50,000
GBP UK 1 - 50,000
JPY Japan 100 - 6,000,000
SGD Singapore 1 - 20,000
MYR Malaysia 1 - 30,000
AUD Australia 1 - 50,000
CAD Canada 1 - 50,000
HKD Hong Kong 1 - 500,000

Note: Multi-currency requires activation. Contact [email protected] to enable.

Supported Banks

Internet Banking / Mobile Banking

Bank Code Type
Bank of Ayudhya (Krungsri) bay Internet/Mobile
Bangkok Bank bbl Internet/Mobile
Krungthai Bank ktb Internet/Mobile
Siam Commercial Bank scb Internet/Mobile
Kasikorn Bank kbank Mobile only

Direct Debit

Bank Code
Bank of Ayudhya (Krungsri) direct_debit_bay
Kasikorn Bank direct_debit_kbank
Krungthai Bank direct_debit_ktb
Siam Commercial Bank direct_debit_scb

Mobile Banking

Bank Code Country
Bangkok Bank (Bualuang mBanking) mobile_banking_bbl Thailand
Kasikorn Bank (K PLUS) mobile_banking_kbank Thailand
Krungthai Bank (KTB NEXT) mobile_banking_ktb Thailand
Bank of Ayudhya (KMA) mobile_banking_bay Thailand
Siam Commercial Bank (SCB Easy) mobile_banking_scb Thailand
OCBC Digital mobile_banking_ocbc Singapore

Installation

Quick Start

Standalone PHP

Laravel

  1. Publish the configuration:

  2. Add your API keys to .env:

  3. Use the facade:

Or use dependency injection:

Payment Method Documentation

For detailed usage of each payment method, see the documentation in the docs/ folder:

Charge API

Source API

Event API

Webhook Handling

Basic Usage

Laravel Webhook Controller

Webhook Events

Common webhook events you can listen for:

Configuration Options

Environment Variables

The SDK can read from environment variables:

Expected variables:

Error Handling

Testing

Test Mode

Use test keys (prefixed with _test_) for development:

Running Tests

API Reference

Omise (Main Class)

Method Description
charges() Get Charge API
sources() Get Source API
events() Get Event API
tokens() Get Token API
customers() Get Customer API
linkedAccounts() Get LinkedAccount API
promptPay() Get PromptPay payment method
rabbitLinePay() Get Rabbit LINE Pay payment method
creditCard() Get Credit Card payment method
directDebit() Get Direct Debit payment method
truemoneyQR() Get TrueMoney QR payment method
truemoneyJumpApp() Get TrueMoney Jump App payment method
mobileBanking() Get Mobile Banking payment method
shopeepayQR() Get ShopeePay QR payment method
shopeepayJumpApp() Get ShopeePay Jump App payment method
webhooks() Get webhook handler
payWithPromptPay($amount, $webhooks) Quick PromptPay payment
payWithRabbitLinePay($amount, $returnUri, $webhooks) Quick Rabbit LINE Pay payment
payWithCard($tokenId, $amount, $currency, $returnUri) Quick credit card payment
payWithTruemoneyQR($amount, $webhooks) Quick TrueMoney QR payment
payWithTruemoneyJumpApp($amount, $returnUri, $webhooks) Quick TrueMoney App payment
payWithMobileBanking($bankType, $amount, $returnUri, $options) Quick Mobile Banking payment
payWithShopeepayQR($amount, $currency, $returnUri, $webhooks) Quick ShopeePay QR payment
payWithShopeepayJumpApp($amount, $currency, $returnUri, $options) Quick ShopeePay App payment
getCharge($id) Retrieve a charge
getEvent($id) Retrieve an event
getCustomer($id) Retrieve a customer
getDefaultCurrency() Get the default currency
isTestMode() Check if in test mode
isLiveMode() Check if in live mode

Currency Helper

Method Description
Currency::isSupported($currency) Check if currency is supported
Currency::toSmallestUnit($amount, $currency) Convert to smallest unit
Currency::toMainUnit($amount, $currency) Convert to main unit
Currency::format($amount, $currency) Format with symbol
Currency::getSymbol($currency) Get currency symbol
Currency::getMinimumAmount($currency) Get minimum in smallest unit
Currency::getMaximumAmount($currency) Get maximum in smallest unit
Currency::validateAmount($amount, $currency) Validate amount limits

License

MIT License. See LICENSE.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Support


All versions of omise-php with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
guzzlehttp/guzzle Version ^7.0
psr/http-message Version ^1.0|^2.0
psr/log Version ^2.0|^3.0
ext-curl Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package pkomjit/omise-php contains the following files

Loading the files please wait ...