Custom datasources
Expose records from an internal API or another system through a plugin.
A custom datasource lets Aviato work with records that do not live in a supported database: for example, an internal service or a helpdesk API. The SDK supplies collection metadata and operations; the connector applies the caller's permissions.
Describe the collection
Define the collection name, fields, and primary key. Use stable identifiers. Treat record IDs as opaque: simple composite keys use a|b; keys containing | use ~ followed by dot-separated UTF-8 hex components. Upgrade the connector and SDK together for those keys. Advertise which filtering, sorting, and count operations your datasource implements so the connector knows which work to delegate.
Implement only the operations you support
A list operation is the starting point. Add get, create, update, or delete as appropriate for the source. Do not expose a write operation merely because the upstream API supports it; decide what operators should be allowed to change.
For sources that cannot efficiently filter or sort, the connector may need to process records in memory. Avoid advertising capabilities that your handler ignores, and test large result sets. The connector checks every record it receives against the caller's permissions, including those behind a count: counts are recomputed from up to 2,000 returned records, and a larger count is refused when a returned record falls outside the filter.
Choose live access or replication
Live access queries the source for each operation. Replication maintains a connector-side copy using changes from your plugin and refreshes it periodically or on demand. Replication changes freshness and storage requirements; persist the connector data directory and explain the refresh interval to users. Updates and deletes are still checked against the source: the connector fetches the record again with get (or pulls pending changes when get is unavailable) before applying the caller's permissions.
Choose the TypeScript, Go, or Laravel integration guide for installation and connector connection. The public SDK READMEs include Go custom collection examples and Laravel datasource examples.