npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@antibusy/strapi-deep-field

v0.1.0

Published

Strapi 5 schema discovery, nested field extraction and populate utilities

Readme

Strapi Deep Field

@antibusy/strapi-deep-field is a server library for Strapi >=5.0.0 <6.0.0. It registers no plugin, routes, permissions, or admin UI.

npm install @antibusy/strapi-deep-field
import { createDeepField, type DeepFieldService } from '@antibusy/strapi-deep-field';

const deepField: DeepFieldService = createDeepField({ strapi });
const fields = await deepField.listFields('api::contact.contact', {
  types: ['string', 'email'],
  includePrivate: false,
});

Create a service in the consuming plugin and pass its host Strapi instance. Metadata caches are isolated per Strapi instance and expire after one minute. Content Manager provides saved labels/main fields when available, with schema fallbacks otherwise. No browser runtime is provided; admin pages call endpoints owned by their consuming plugin.

Authorization

These utilities perform trusted server operations. getValue queries Document Service without an HTTP caller's permission context. The consuming workflow or endpoint must enforce collection, record, tenant, and field access and sanitize returned data. includePrivate: false excludes private/password attributes and all descendants beneath them during field discovery. Omitting it preserves the original plugin's internal discovery behavior. It is not an authorization check.

API Reference

Service Methods

listFields(collectionUid, options?)

List all mappable fields for a collection.

Options:

  • types: Array of basic types to include (default: all types)
  • includeRepeatable: Include fields in repeatable components (default: true)
  • maxDepth: Maximum traversal depth (default: 3)
  • customFieldUids: Array of custom field UIDs to include
  • includeRelations: Include relation fields (default: true)
  • componentCategories: Filter by component categories

Returns: MappableField[]

getValue(collectionUid, documentId, fieldPath, options?)

Get value from a field path in an entry (fetches the entry automatically).

Options:

  • relationOutput: 'documentId' | 'mainField' | 'populate' (default: 'documentId')
  • forEntryMutation: Prepare value for create/update operations

Returns: FieldValueResult

getValueFromEntry(entry, fieldPath, collectionUid, options?)

Get value from a field path in an already-fetched entry.

buildPopulateConfig(collectionUid, paths)

Build Strapi populate configuration for given field paths.

Returns: Record<string, any>

getMainField(collectionUid)

Get the main display field for a collection.

Returns: MainFieldInfo | null

getComponentInfo(componentUid)

Get information about a component.

Returns: ComponentInfo | null

validateFieldPath(collectionUid, fieldPath, expectedTypes?)

Validate if a field path is valid for a collection.

Returns: { valid: boolean; error?: string; field?: MappableField }

Field Path Notation

Use dot notation for nested fields:

  • Simple field: firstName
  • Component field: address.street
  • Dynamic zone with component filter: identities[identity.line].uid
  • Relation field: organization.name

Local development and release

Run npm ci, npm test, and npm pack. Parity tests use the published plugin 0.0.7 as a pinned development-only dependency. Version 0.1.0 is initially installed in Customer's consuming plugins using identical vendored tarballs. After publication, replace their relative file dependencies with the registry version and regenerate lockfiles. Publishing this library does not change the independent Deep Field plugin.

License

MIT