Download the PHP package parabellumkoval/backpack-profile without Composer

On this page you can find all versions of the php package parabellumkoval/backpack-profile. 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 backpack-profile

Backpack Profile

Comprehensive user profile, referral, and wallet subsystem for Laravel applications that use Backpack. The package ships ready-to-use CRUD panels, API endpoints, referral triggers, wallet management, reward distribution, withdrawal workflows, and a Sanctum-based authentication layer that can be consumed from SPA or mobile clients.


Feature Overview


Requirements


Installation

  1. Install the package

  2. Run migrations

    This creates core tables such as ak_profiles, ak_referral_partners, ak_reward_events, ak_rewards, ak_wallet_balances, ak_wallet_ledger, and ak_withdrawal_requests.

  3. (Optional) Publish assets

    • Config is copied to config/backpack/profile.php.
    • Views land under resources/views/vendor/profile and resources/views/vendor/backpack/crud.
    • Migrations and route stubs are publishable if you need to customize them heavily.
  4. Configure Backpack Settings (recommended)

    Register Backpack\Profile\app\Settings\ProfileSettingsRegistrar inside your Backpack Settings registrar so that referral, wallet, and withdrawal options become editable from the admin UI.


Quick Start Checklist

Task Notes
Configure config/auth.php guards Define a profile guard if you plan to use profile-authenticated routes.
Sanctum personal access tokens Ensure config/sanctum.php is set up; SPA/mobile clients should store bearer tokens securely.
Socialite credentials Set GOOGLE_CLIENT_ID, FACEBOOK_CLIENT_ID, etc., and update config/services.php.
Currency converter binding Bind Backpack\Profile\app\Contracts\CurrencyConverter to your implementation if you need real conversion rates.
Settings defaults Review config/backpack/profile.php (currencies, referral levels, middlewares, withdrawal minimums).

Database Schema

Table Purpose
ak_profiles Profile metadata linked 1:1 with the users table (user_id). Stores locale, sponsor, marketing opt-in flags, referral code, etc.
ak_referral_partners Flattened referral tree with parent relationships for fast traversal.
ak_reward_events Event log for referral trigger executions (pending/processing/processed/failed, reversal support).
ak_rewards Monetary/points rewards issued to beneficiaries (actor or upline) per event.
ak_wallet_balances Snapshot of wallet balances per user and currency.
ak_wallet_ledger Journal of wallet operations (credit/debit/hold/release/capture).
ak_withdrawal_requests Withdrawal workflow records, including FX metadata and admin actions.
ak_event_counters Incremental counters for idempotent trigger execution (subject_type + subject_id).

Note: legacy code still references columns such as firstname, lastname, and addresses. If you rely on these attributes, ensure your schema includes matching columns or adjust the model to align with the published migrations. See IMPROVEMENTS.md for known inconsistencies.


Configuration Highlights

config/backpack/profile.php drives most behavior:

Backpack Settings extender (ProfileSettingsRegistrar) mirrors these options in a GUI-friendly manner. Ensure the registrar is invoked by the host application so admins can manage referral triggers, currencies, and withdrawal policies.


Backpack Admin Panels

Once the service provider boots, the following routes are available under the Backpack prefix (default /admin):

All admin controllers rely on Backpack's CRUD operations, custom columns (e.g., user_card, price, status), and the translation strings shipped under resources/lang/en|ru.


API Surface

Authentication (/api/auth/...)

Responses are JSON-only thanks to ForceJsonResponse middleware. The detailed request/response contract and recommended Nuxt/Auth.js integration steps are documented in AUTH_SYSTEM.md.

Profile (/api/profile/...)

Important: the controller expects an authenticated profile guard but the update route is wired to auth:sanctum. Align guards in your application or adjust the controller as described in IMPROVEMENTS.md.

Wallet & Withdrawals (/api/wallet/...)

Routes are wrapped in middleware from Settings::get('profile.private_middlewares') (defaults to ['api', 'auth.api:sanctum']).

WithdrawalService enforces minimum amounts, currency conversion, wallet holds, and ledger bookkeeping. Admin actions (approve/reject/mark paid) are exposed through Backpack routes.


Services & Facades

All services are container-bound in ServiceProvider. You can override bindings in your application service provider if you need to replace behavior.


Events, Notifications, and Observers


Extending the Referral Engine

  1. Implement Backpack\Profile\app\Contracts\ReferralTrigger.
  2. Register the trigger alias with TriggerRegistry::register($alias, $class), typically from a service provider or module boot method.
  3. Configure trigger settings (fixed/percent payouts, actor award, level distribution) via the Backpack Settings UI or config/settings.php.
  4. Invoke Profile::trigger($alias, $externalId, $payload, $actorUserId, $opts) whenever an event occurs (e.g., order paid).

Reversals can be created via Profile::reverse(...) or admin UI actions.


Frontend Integration Notes


Testing & Development


Known Gaps & Roadmap

See IMPROVEMENTS.md for a curated backlog of technical debt and missing functionality (schema mismatches, outdated controllers, guard inconsistencies, missing tests, etc.). Addressing those items is recommended before turning the package into a reusable release.


License

The package is open-sourced software licensed under the MIT license.


All versions of backpack-profile with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
laravel/framework Version ^12.0
backpack/crud Version dev-store
laravel/sanctum Version ^4.2.0
laravel/socialite Version ^5.23.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 parabellumkoval/backpack-profile contains the following files

Loading the files please wait ...