Repository

Typed repository classes for collections and globals over the Payload Local API

Community 0 5/wk MIT v1.1.4

Installation

pnpm add payload-repository

About

Payload Repository wraps Payload's Local API in a set of classes, one per collection or global. Your domain queries and writes go into named methods, such as publishing a post, so controllers and jobs do not repeat filter and option objects. Types come from your generated Payload types, so field names, selects and return values are checked by the compiler.

Transformers let a layer change data, filters or options before an operation runs. A multi-tenant app can add a tenant filter to every read and set the tenant on every write in one place. Separate transformer sets can be merged so each layer contributes its own rules, and async transformers are supported.

Package info

Package name
payload-repository
Latest version
1.1.4
Unpacked size
39 kB
License
MIT
Weekly downloads
5
Last publish
Jun 29, 2026

More from bhofstaetter

View profile

Type-safe factory functions that build Payload field configs with less boilerplate

Helpers for extracting IDs, resolving documents and composing field validators

Spins up a throwaway Payload instance on a test database container for integration tests

Type-safe client for the Payload REST API with CRUD, auth and file uploads

Framework-agnostic SDK for inline visual editing on Payload-powered sites

Angular query builder that sends list queries to Payload and other backends as signals

Registers custom drag-and-drop blocks for the Olgax page builder

Lets Puck components pull filtered Payload collection items into a resolved prop

Signed client for the VAP API, plus a Payload plugin for storefront sign-in and checkout