Download the PHP package fluffydiscord/sylius-honkers-bundle without Composer

On this page you can find all versions of the php package fluffydiscord/sylius-honkers-bundle. 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 sylius-honkers-bundle

Sylius honkers.dev Bundle

Plug-and-play Sylius wrapper for the honkers.dev chatbot tool-server. Adds the default tools, data sources and shop widget on top of two lower layers, both pulled in automatically:

Read the Symfony bundle README for the tool-server mechanics — this page covers only the Sylius pieces.

Requires PHP ^8.1 and Sylius ^1.14 || ^2.2 || ^2.3.

Requirements

Package Constraint
php ^8.1
ext-intl *
sylius/sylius ^1.14 \|\| ^2.2 \|\| ^2.3@alpha
doctrine/orm ^2.20 \|\| ^3.6 \|\| ^4.0
doctrine/doctrine-bundle ^2.13 \|\| ^3.2 \|\| ^4.0
symfony/* ^6.4 \|\| ^7.0 \|\| ^8.0
twig/twig ^2.12 \|\| ^3.3

The @alpha on sylius/sylius is only because 2.3 has no stable tag yet (v2.3.0-ALPHA.1); it drops once 2.3 ships stable.

On Sylius 1.14 the widget uses a deprecated hook. 1.14 runs on Symfony 6.4 with no Twig Hooks, so the widget is registered as a sylius_ui template block on sylius.shop.layout.javascripts — the only mechanism 1.14 offers, deprecated in that same release. The container build reports sylius/ui-bundle deprecations for it: expected, not a bug. Endpoints, data sources and catalog notifications are identical on both lines.

Installation

1. Composer

2. Register the bundles

Register both the vanilla Symfony bundle and this Sylius wrapper in config/bundles.php:

3. Routes

The routes are owned by the Symfony bundle. config/routes/fluffy_discord_honkers.yaml:

Keep the endpoints off the shop's _locale prefix — they live under /chatbot/v1 on the shop host.

4. Configuration

The connection and widget config belong to the Symfony bundle. config/packages/fluffy_discord_honkers.yaml:

One site per channel

Map channel codes to site keys when each channel is its own site on the backend. config/packages/fluffy_discord_sylius_honkers.yaml:

5. Security

Add the chatbot_api firewall (see the Symfony bundle README) to config/packages/security.yaml before the Sylius shop firewall — firewalls match in order and shop matches ^/:

Shipped tools

The backend calls these mid-conversation for live data:

Add your own tool → Symfony bundle README.

Shipped sources

The backend pulls these in bulk and ingests them into its retrieval index:

Every absolute URL a source or tool emits is built on the resolved channel's hostname, not the request host. A read for channel=X returns links on X's domain; only the host is swapped.

Extension points

Both govern the products source; redefine the container alias in services.yaml to replace them:

Interface Default Purpose
ProductViewFactoryInterface ProductViewFactory price, stock, image and URL of an indexed product
ProductIndexabilityInterface ProductIndexability which products the source serves (enabled, in the channel, at least one priced enabled variant)

Add your own source → Symfony bundle README.

Catalog change notifications

These keep the backend's ingested sources fresh. Saving a Product, ProductTranslation, Taxon or TaxonTranslation collects the changed external ids; one POST {backend_url}/api/v1/catalog/changes per (source, locale) is sent on kernel.terminate and ConsoleEvents::TERMINATE, synchronously and one at a time through the SDK's CatalogIngestClient (2 s timeout, 5 s max duration, max 500 ids per request). A failure is logged and swallowed — a dropped notification costs at most one nightly cycle of staleness, never a broken shop request.

What each change announces:

Saved entity Announces
ProductTranslation its own locale
TaxonTranslation categories for its own locale
Product every locale of sylius_locale
Taxon categories for every locale, no product fan-out

With backend_url or ingest_secret empty, or with neither widget.site_key nor any channel_site_keys entry set, nothing is sent and a warning names the missing key.

Which site receives a (source, locale):

channel_site_keys Recipients
empty the widget.site_key site, for every locale
set the site of every enabled channel serving that locale; channels resolving to the same site key share one request

With channel keys set: an enabled channel that serves a changed locale but resolves no key is skipped with a warning; a channel mapped to an empty value is skipped with a debug record; a locale no enabled channel serves is sent nowhere.

Re-announce everything

Re-announces the whole catalog in 500-id batches, pausing 2 s between batches and honouring Retry-After on a 429.

Widget

When widget.enabled is true the bundle injects, via the sylius_shop.base#javascripts twig hook on Sylius 2 and the sylius.shop.layout.javascripts template block on Sylius 1.14:

site_key is resolved at render time by the fluffydiscord_chatbot_site_key(fallback) Twig function: the current channel's channel_site_keys entry, else the template's own site_key. The shop's ChannelContextInterface decides the channel; without a resolvable channel the fallback is used. When the resolved key is empty nothing renders — neither script nor element.

Include the template directly with a plain context — the channel key still applies:

widget_cdn_url defaults to {backend_url}/widget/v1/chat.js when widget.cdn_url is unset. The widget talks only to backend_url; it never calls /chatbot/v1 itself.


All versions of sylius-honkers-bundle with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
ext-intl Version *
doctrine/collections Version ^1.8 || ^2.1
doctrine/doctrine-bundle Version ^2.13 || ^3.2 || ^4.0
doctrine/orm Version ^2.20 || ^3.6 || ^4.0
fluffydiscord/honkers-sdk Version ^1.1
fluffydiscord/symfony-honkers-bundle Version ^1.1
liip/imagine-bundle Version ^2.13
sylius/sylius Version ^1.14 || ^2.2 || ^2.3@alpha
symfony/config Version ^6.4 || ^7.0 || ^8.0
symfony/console Version ^6.4 || ^7.0 || ^8.0
symfony/dependency-injection Version ^6.4 || ^7.0 || ^8.0
symfony/event-dispatcher Version ^6.4 || ^7.0 || ^8.0
symfony/http-client Version ^6.4 || ^7.0 || ^8.0
symfony/http-foundation Version ^6.4 || ^7.0 || ^8.0
symfony/http-kernel Version ^6.4 || ^7.0 || ^8.0
symfony/translation Version ^6.4 || ^7.0 || ^8.0
twig/twig Version ^2.12 || ^3.3
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 fluffydiscord/sylius-honkers-bundle contains the following files

Loading the files please wait ...