Download the PHP package codemonster-ru/annabel without Composer

On this page you can find all versions of the php package codemonster-ru/annabel. 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 annabel

[!IMPORTANT] This repository is read-only.

Development happens in the Annabel monorepo: https://github.com/codemonster-ru/annabel

Issues and pull requests should be opened there.

Annabel

Latest Version on Packagist Total Downloads License Tests

Elegant and lightweight PHP framework for modern web applications.

Installation

Quick Start

CLI

Annabel ships with a lightweight CLI similar to Laravel's artisan. It already supports:

Commands may be registered by service providers and are resolved through the application container, including constructor dependency injection:

New commands may implement execute(InputInterface $input, OutputInterface $output): int. ArgvInput provides positional arguments and parsed long options; commands return ExitCode constants. The legacy handle(array) method remains supported for existing commands.

Testing

Application tests can use Annabel's lightweight HTTP helpers:

Database Integration

Annabel ships with first-class integration for
codemonster-ru/database.

1. Create config/database.php

2. Usage

Helpers

Function Description
app() Access the application container
base_path() Resolve base project paths
config() Get or set configuration values
env() Read environment variables
dump() / dd() Debugging utilities
request() Get current HTTP request
response() / json() Create HTTP response
http_client() Access the HTTP client
router() Access router or register route
route() Generate a named route URI
view() Render or return view instance
session() Access session store
storage() Access filesystem storage disks
old() Read flashed old form input
errors() Read flashed validation errors
auth() Access the authentication guard
user() Read the authenticated user
cache() Access PSR-16 cache store
mailer() Access mailers
queue() Access queue connections
dispatch() Dispatch a queue job
schedule() Access scheduled tasks
validator() Validate input data
db() Get the active database connection
schema() Get the schema builder
transaction() Execute a DB transaction

All helpers are autoloaded automatically.

Filesystem

Annabel registers codemonster-ru/filesystem by default. Publish the default config and use storage() to read or write files:

HTTP Client

Annabel registers codemonster-ru/http-client by default. Configure defaults in config/http-client.php and use http_client() for external API calls:

Middleware

Annabel supports PSR-15 middleware via Psr\Http\Server\MiddlewareInterface. Route middleware may be registered by class name, and global middleware may be added to the kernel with addMiddleware().

Middleware aliases and groups keep routes compact:

The framework registers auth and can when auth is enabled. The security provider registers csrf, throttle, and the default web / api groups. Custom aliases and groups can be registered on the HTTP kernel:

Publish the security config to tune CSRF, rate-limit storage, trusted proxies, and named throttle presets:

Authentication

Annabel registers codemonster-ru/auth by default. Publish the default config and configure a user provider in config/auth.php, or provide a small in-memory list for local applications:

Production applications should bind a database-backed Codemonster\Auth\Contracts\UserProviderInterface implementation through auth.provider.

Routing

Routes support dynamic parameters, constraints, names, and URI generation:

Route parameters are injected into closures and controllers by parameter name. The current Codemonster\Http\Request may be type-hinted alongside route parameters.

API Resources

API resources provide one transformation for individual models, collections, and existing simplePaginate() results:

Logging

Annabel binds Psr\Log\LoggerInterface in the container. Configure the default channel in config/logging.php; unhandled HTTP exceptions are reported before the error response is rendered.

Cache

Annabel binds Psr\SimpleCache\CacheInterface in the container. Configure the default store in config/cache.php; the framework ships with array, file, and redis stores. Set CACHE_STORE=redis and configure REDIS_HOST, REDIS_PORT, REDIS_PASSWORD, and REDIS_CACHE_DB for shared cache in multi-instance deployments.

Mail

Annabel registers codemonster-ru/mail by default. Configure the default mailer in config/mail.php; the framework ships with array, log, sendmail, and Symfony-powered smtp transports. Set MAIL_MAILER=smtp and provide an SMTP DSN through MAILER_DSN.

Queue

Annabel registers codemonster-ru/queue by default. Configure the default connection in config/queue.php; the framework ships with sync, database, and redis drivers.

The default sync connection runs jobs immediately. For SQL-backed background jobs, set QUEUE_CONNECTION=database, publish queue migrations, run migrate, and start the worker:

For Redis-backed workers, set QUEUE_CONNECTION=redis and configure REDIS_HOST, REDIS_PORT, REDIS_PASSWORD, REDIS_QUEUE_DB, and QUEUE_REDIS_PREFIX. Redis failed jobs are stored in Redis and work with the same queue:failed, queue:retry, and queue:flush commands.

Scheduler

Annabel registers codemonster-ru/scheduler by default. Define tasks in routes/schedule.php and run schedule:run every minute from cron:

Use schedule:list to inspect registered tasks, cron expressions, due status, and overlap locks.

Scheduler locks use the configured cache store when the cache provider is registered.

Production optimization

Build configuration and route caches during deployment:

Routes with closures cannot be cached. Use controller handlers such as [HomeController::class, 'index']. Clear all generated caches before changing environment configuration or when troubleshooting:

The individual config:cache, config:clear, route:cache, and route:clear commands are also available.

Events

Annabel binds Psr\EventDispatcher\EventDispatcherInterface and Psr\EventDispatcher\ListenerProviderInterface. Register listeners through the framework listener provider and dispatch events through the PSR dispatcher.

Validation

Annabel ships with a small validation layer for request/config data. It supports common scalar rules, nested fields through dot notation, validated() data, and validateOrFail() for exception-driven flows.

Controllers can use Codemonster\Annabel\Http\ValidatesRequests to validate the current request. Validation failures return JSON 422 responses for API requests, or redirect back with flashed errors and _old_input for web forms. Redirects are restricted to local same-origin locations. Sensitive fields are excluded recursively according to config/validation.php.

HTTP Exceptions

Framework HTTP exceptions live under Codemonster\Annabel\Http\Exceptions. They expose stable status and header contracts for bad requests, authentication, authorization, missing routes, and unsupported methods.

Container parameters

The Annabel container implements Psr\Container\ContainerInterface, so it can be passed to libraries expecting a PSR-11 container.

You can pass named constructor parameters when resolving classes or closure bindings:

Note: for singleton bindings, passing parameters after the instance is resolved throws an exception.

Note: Application::serve() will throw if an instance already exists; call Application::resetInstance() first.

Providers

Annabel reads provider settings from config/app.php before registering services.

All providers are registered first and booted after registration completes.

Installed packages may declare providers in Composer metadata:

Only providers owned by that package should be declared. Applications can disable selected packages through providers.packages.dont_discover, use * to disable all package discovery, or set providers.packages.discover to false. The generated manifest cache is invalidated when package composer.json metadata changes.

Publishable Resources

Package providers may register publishable files or directory trees:

Publishing is explicit and does not overwrite existing files unless requested:

Destinations must remain inside the application base path. Symbolic-link escape paths are rejected.

Testing

Author

Kirill Kolesnikov

License

MIT


All versions of annabel with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2
codemonster-ru/api-resource Version ^1.0
codemonster-ru/auth Version ^1.0
codemonster-ru/cache Version ^1.0
codemonster-ru/config Version ^2.1
codemonster-ru/database Version ^2.1
codemonster-ru/env Version ^2.0
codemonster-ru/errors Version ^1.2
codemonster-ru/events Version ^1.0
codemonster-ru/filesystem Version ^1.0
codemonster-ru/http Version ^2.1
codemonster-ru/http-client Version ^1.0
codemonster-ru/logging Version ^1.0
codemonster-ru/mail Version ^1.0
codemonster-ru/queue Version ^1.0
codemonster-ru/razor Version ^1.1
codemonster-ru/router Version ^2.6
codemonster-ru/scheduler Version ^1.0
codemonster-ru/security Version ^1.1
codemonster-ru/session Version ^2.0.1
codemonster-ru/support Version ^1.4
codemonster-ru/validation Version ^1.0
codemonster-ru/view Version ^2.0
codemonster-ru/view-php Version ^2.1
psr/container Version ^2.0
psr/event-dispatcher Version ^1.0
psr/http-message Version ^2.0
psr/http-server-middleware Version ^1.0
psr/log Version ^3.0
psr/simple-cache Version ^3.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 codemonster-ru/annabel contains the following files

Loading the files please wait ...