REST Client

Typesafe REST API client for collections, globals and custom endpoints

Community 49 1.6k/wk MIT v3.0.5

Installation

pnpm add payload-rest-client

About

REST Client gives you a typed way to call the REST API of a Payload project from TypeScript code. Collections get find, create, update, delete and login calls, and sort keys, locales and body shapes are checked against your generated Payload types. Globals and custom endpoints you describe get the same typed interface.

Requests can carry custom headers, such as a bearer token after login, and you can swap in your own fetch function or set cache behaviour. This makes it usable from frontends, scripts and other Node services that need to read or write Payload content.

Package info

Package name
payload-rest-client
Latest version
3.0.5
Unpacked size
56 kB
License
MIT
Weekly downloads
1.6k
Last publish
Feb 19, 2025

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