localfr/agendize-client-bundle
Symfony bundle that wraps the Agendize API, giving PHP applications a configured client for appointment scheduling, booking, and customer-engagement services. Handles service wiring and dependency injection so Symfony projects can call Agendize endpoints with minimal setup.
As of v0.1.6, the package expects two credentials for the Agendize API: an apiKey and a token. Start by installing the package, publishing its config, and setting both values in .env:
composer require <vendor>/<package>
php artisan vendor:publish --tag=agendize-config
AGENDIZE_API_KEY=your-api-key
AGENDIZE_TOKEN=your-api-token
Look first at the package config file and service provider to confirm the exact config keys and binding names. Then make a single authenticated read call against a low-risk endpoint — for example, listing a resource or fetching the current account — before wiring anything into application flows. The first practical use case is usually a scheduled job or admin action that reads Agendize data (appointments, queues, or account resources) using the configured apiKey and token.
AgendizeService or per-domain client (Appointments, Queues) that accepts the package client and returns DTOs or arrays. This isolates endpoint paths, query parameters, and response shape changes.apiKey as application identity and token as the account/session credential. Keep the API key in config, and source the token from your own auth flow or Agendize dashboard depending on your integration. For multi-tenant apps, resolve both at runtime per tenant rather than relying only on global env values.PendingRequest. Log request IDs and endpoint names, never full tokens.401/403 responses in one place and convert them into domain exceptions. If your token is refreshable, trigger refresh there; otherwise surface a clear “reconnect Agendize” error.Http::fake() and config overrides. Set config(['agendize.apiKey' => 'test', 'agendize.token' => 'test']) in tests and fake the Agendize endpoints. Assert that your service sends the expected auth headers and maps responses correctly.apiKey and token are not interchangeable. The v0.1.6 release specifically adds support for both. Mixing them up typically produces authentication errors that look like invalid credentials rather than missing config.401 path early and decide whether you refresh, re-authenticate, or prompt an admin. Do not assume the package refreshes tokens automatically unless the source confirms it.php artisan config:clear is required in local and deployed environments when changing AGENDIZE_API_KEY or AGENDIZE_TOKEN, otherwise Laravel may serve stale values.apiKey and token; confirm whether the config file uses camelCase, snake_case, or nested keys, and whether env names differ.Authorization and token query parameters are masked. Avoid dumping the resolved config.GET request and log the status, response body, and request ID. If auth fails, verify both credentials independently against the Agendize authentication documentation before changing application code.How can I help you explore Laravel packages today?