Download the PHP package freedomtech-hosting/polydock-app without Composer
On this page you can find all versions of the php package freedomtech-hosting/polydock-app. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download freedomtech-hosting/polydock-app
More information about freedomtech-hosting/polydock-app
Files in freedomtech-hosting/polydock-app
Package polydock-app
Short Description Library for Polydock Apps
License MIT
Informations about the package polydock-app
NOTE: Deprecated — see the polydock-engine repo.
Polydock App Library
A PHP library providing the core interfaces, base classes, and utilities for building Polydock applications. This library defines the contract for app lifecycle management, instance handling, and integration with the Polydock engine.
Quick Start
Create a new Polydock app by extending PolydockAppBase:
Custom Store App Form Fields
Polydock App classes can define custom form fields that appear in the admin panel when configuring a Store App. These fields allow app-specific settings to be collected and stored.
Defining Custom Fields
- Add the
#[PolydockAppStoreFields]attribute to your class - Implement the
HasStoreAppFormFieldsinterface (recommended for type safety) - Create static
getStoreAppFormSchema()andgetStoreAppInfolistSchema()methods
Field Name Prefixing
All custom field names are automatically prefixed with app_config_ when stored to avoid collisions with built-in model fields. You should define fields without the prefix - it's added automatically.
For example, a field named ai_endpoint will be stored as app_config_ai_endpoint in PolydockVariables.
Encrypted Fields
Mark sensitive fields for encrypted storage by adding the encrypted extra attribute:
The value will be encrypted before storage and automatically decrypted when retrieved.
Accessing Custom Field Values
Custom field values are stored as PolydockVariables and can be accessed from your app lifecycle methods:
Supported Field Types
Any Filament form component can be used, including:
TextInput- Text, email, URL, password inputsTextarea- Multi-line textSelect- Dropdown selectionsToggle- Boolean switchesCheckbox/CheckboxList- Checkbox inputsRadio- Radio button groupsDatePicker/DateTimePicker- Date inputsFileUpload- File uploads (stored as paths)KeyValue- Key-value pair editorsRepeater- Repeatable field groups (stored as JSON)Section/Grid/Fieldset- Layout components
Validation
Use standard Filament validation rules: