Download the PHP package carllee/line-pay-core-v4 without Composer

On this page you can find all versions of the php package carllee/line-pay-core-v4. 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 line-pay-core-v4

LINE Pay Core V4 PHP

License: MIT PHP Version

Core library for LINE Pay API V4 SDK. Provides shared utilities, base client, configuration, and error handling that power the Online and Offline SDKs.

🌐 Language / 語言 / 言語 / ภาษา: ภาษาไทย

Architecture

Overview

This package is the shared foundation for building LINE Pay V4 integrations in PHP. It handles the "heavy lifting" so that the Online and Offline SDKs can focus on their specific API logic.

Key Responsibilities

Component What It Does Why It Matters
HMAC-SHA256 Signature Generates and verifies API signatures The most complex part of LINE Pay V4 API — one wrong byte and requests fail
HTTP Client Wrapper Encapsulates Guzzle with retry logic Handles timeouts, connection errors, and response parsing consistently
Unified Error Parsing Parses LINE Pay error codes into typed exceptions 1xxx = Auth, 2xxx = Payment, 9xxx = Internal — no more guessing
Configuration Management Type-safe config with environment support Prevents "oops, wrong credentials in production" mistakes

Requirements

Installation

⚠️ Note: This is a core library meant to be used as a dependency.

Most developers should use the ready-made SDKs instead:

Use this package directly only if you need to build a custom LINE Pay client with specialized behavior.

Usage

Creating a Custom Client

Utilities

Security: Timing-Safe Signature Verification

The verifySignature method uses constant-time comparison to prevent timing attacks:

Why this matters: A timing attack can determine how many characters of a signature match by measuring response time. Constant-time comparison always takes the same amount of time regardless of how many characters match.

Error Handling

LINE Pay API error codes follow a pattern:

Code Range Category Description
1xxx Authentication Channel ID/Secret issues, invalid signatures
2xxx Payment Transaction errors, insufficient balance, expired
9xxx Internal LINE Pay server errors, maintenance

Configuration

Parameter Type Required Default Description
channelId string Yes - Channel ID from LINE Pay Merchant Center
channelSecret string Yes - Channel Secret from LINE Pay Merchant Center
env string No 'sandbox' Environment: 'production' or 'sandbox'
timeout int No 20 Request timeout in seconds

Related Packages

Development

License

MIT License - see the LICENSE file for details.

Author

Carl Lee - GitHub


All versions of line-pay-core-v4 with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
ext-json Version *
ext-openssl Version *
guzzlehttp/guzzle Version ^7.0
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 carllee/line-pay-core-v4 contains the following files

Loading the files please wait ...