Download the PHP package m0d1xd/tap-company-sdk without Composer

On this page you can find all versions of the php package m0d1xd/tap-company-sdk. 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 tap-company-sdk

Tap Company Laravel SDK

Full-platform Laravel SDK for the Tap Payments API.

Supports Laravel 12–13 and PHP 8.2+.

Disclaimer: This package is not an official product of Tap Company / Tap Payments, and is not affiliated with, endorsed by, or maintained by their developers. It is a personal, vibe-coded Laravel SDK built independently to provide a nicer developer experience on top of the public Tap Payments API. Use at your own risk; API behavior and docs may change without notice.

Installation

Publish the config:

Configuration

You can supply any Tap setting via .env, the published config file, or Tap::configure() in code. The SDK always reads config('tap.*') — env() is only a convenience default in the config file.

Environment variables

Copy .env.example into your Laravel app .env (or merge the TAP_* keys):

Request logging

Set TAP_LOGGING_ENABLED=true to write every outgoing API call and incoming webhook to storage/logs/tap.log via the dedicated tap log channel. Outgoing entries include method, URL, status, redacted headers, and the JSON body actually sent (so PaymentSource objects log as {"id":"src_kw.knet"}). Disable bodies with TAP_LOGGING_PAYLOADS=false (headers are still recorded), or point TAP_LOGGING_CHANNEL at another Laravel channel (e.g. stack) if you prefer.

Debugging requests

Set TAP_DEBUG=true to dump each outgoing request (redacted headers and JSON body) to the console or browser before it is sent. For a single call:

Tap::dd() is code-only — there is no env flag that can halt requests in production. Secrets such as the Bearer token are always redacted.

Published config

After php artisan vendor:publish --tag=tap-config, edit config/tap.php and set values directly if you prefer not to use .env:

Programmatic configuration

Set any option at runtime from a service provider (before the Tap client is first resolved):

Authentication uses Authorization: Bearer {secret_key} against Tap’s REST API.

Object examples

Full Tap request/response JSON samples (sourced from the official reference .md pages) live in docs/examples/ — charges, authorizations, refunds, customers, tokens, cards, invoices, intents, payouts, marketplace leads/businesses/merchants/destinations, files, disputes, connect, and webhooks.

Quick start — charge

Optional idempotency:

Typed payment sources

TapCompany\LaravelSdk\Data\PaymentSource gives you autocomplete instead of raw ['id' => 'src_...'] arrays. It implements Arrayable/JsonSerializable, so an instance can be dropped straight into the source key of any charge/authorization payload:

Available named constructors: card(), all(), applePay(), googlePay(), samsungPay(), knet(), mada(), stcPay(), fawry(), benefit(), benefitPay(), qpay(), omannet(), tabbyInstallment(), token(string $id), savedCard(string $id, bool $onFile = true), encryptedCard(string $encrypted, bool $onFile = false), or of(PaymentSourceId|string $id) for anything else. The full backing list of ids lives in the TapCompany\LaravelSdk\Enums\PaymentSourceId enum.

TapCompany\LaravelSdk\Enums\ChargeStatus mirrors the status values Tap returns on a charge (CAPTURED, DECLINED, INITIATED, ...) with isSuccessful()/isTerminal() helpers:

Authorize and capture

Refunds

Customers, tokens, and cards

Also available: createEncrypted(), createApplePay(), createSamsungPay(), createNetworkToken(), cards()->verify().

Invoices and intents (POS)

Marketplace / Connect

Retailer helpers: leads()->createRetailer(), updateRetailer(), convertToRetailer().

Files, payouts, disputes

Webhooks

Enable the package route with TAP_WEBHOOK_ENABLED=true (default path /tap/webhook). Full setup — configuration, registering post.url with Tap, events, and a custom controller — is in docs/webhooks.md.

The controller validates Tap’s hashstring HMAC and dispatches:

Manual verification:

Available resources

Accessor Purpose
Tap::charges() Create, retrieve, update, list, download
Tap::authorizations() Authorize, update, capture, download
Tap::refunds() Refunds
Tap::customers() Customer CRUD
Tap::tokens() Payment tokens
Tap::cards() Saved cards + verify
Tap::invoices() Invoices
Tap::intents() POS intents
Tap::payouts() Settlements
Tap::leads() Marketplace leads
Tap::connect() Connect onboarding URL
Tap::businesses() Marketplace businesses
Tap::merchants() Sub-merchants
Tap::destinations() Split destinations
Tap::files() File uploads
Tap::disputes() Dispute downloads

Testing

Use Tap test cards with sk_test_* keys.

Contributing

See CONTRIBUTING.md for Conventional Commits, PR titles, and the test workflow.

Releasing / Deploy

This library is published to Packagist as m0d1xd/tap-company-sdk. Versions are cut automatically from Conventional Commits on main via release-please; each GitHub Release triggers a Packagist sync workflow.

Integrate Packagist with GitHub Actions: add PACKAGIST_USERNAME and PACKAGIST_TOKEN secrets, then follow docs/deploy.md.

License

MIT


All versions of tap-company-sdk with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
illuminate/contracts Version ^12.0|^13.0
illuminate/http Version ^12.0|^13.0
illuminate/log Version ^12.0|^13.0
illuminate/support Version ^12.0|^13.0
illuminate/events Version ^12.0|^13.0
illuminate/routing Version ^12.0|^13.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 m0d1xd/tap-company-sdk contains the following files

Loading the files please wait ...