novanda1

payload imagekit

by novanda1
Cloud storage
v3
^3.59.1

Overview

Summary generated from the README

Uploads images from configured Payload upload collections to ImageKit. Configured per collection with upload options such as folder and auto-tagging extensions, and can save selected ImageKit response properties like the URL or AI tags to the database. Local disk storage is disabled by default. Requires ImageKit API keys and an endpoint, and the Payload Cloud storage must be disabled if used.

Features

  • Uploads files from chosen Payload collections to ImageKit
  • Per-collection upload options such as target folder
  • Auto-tagging extensions for AWS and Google with confidence and tag limits
  • Saves selected ImageKit response properties like URL and AI tags to the database
  • Disables local file storage by default, configurable per collection

Use cases

  • Serve Payload media through ImageKit's image delivery instead of local storage
  • Attach AI-generated tags to uploaded images automatically
  • Keep uploads off the server disk when deploying to hosts without persistent storage

From the author

Payload CMS plugin ImageKit

Installation

npm i payloadcms-plugin-imagekit

24

Stars

6

Forks

0

Open Issues

1 years ago

Last Updated

0

Weekly Downloads

v0.5.0

npm Version

40.6 KB

Unpacked Size

4

Dependencies

GitHub stars

Trends appear after 7 days of data. Daily snapshots have not started yet.

npm weekly downloads

Trends appear after 7 days of data. Daily snapshots have not started yet.

Each point is npm's rolling 7-day download count.

Health Score

29/100Fair

Composite score based on GitHub activity, stars, npm downloads, publish recency, dependency count, and package size.

Badge for your README

Payload Directory health badge
Markdown
[![Payload Directory](https://payloaddirectory.dev/badge/521210678-root.svg)](https://payloaddirectory.dev/plugins/521210678-root)
HTML
<a href="https://payloaddirectory.dev/plugins/521210678-root"><img src="https://payloaddirectory.dev/badge/521210678-root.svg" alt="Payload Directory"></a>
Updated Oct 15, 2025Created Aug 4, 2022Published Oct 15, 2025

README

Payload CMS ImageKit Plugin

This plugin sync your image to ImageKit.

Installation

npm install payloadcms-plugin-imagekit

Usage

Install this plugin within your Payload as follows:

import { buildConfig } from "payload/config";
import imagekitPlugin from "payloadcms-plugin-imagekit";

export default buildConfig({
  // ...
  plugins: [
    imagekitPlugin({
      config: {
        publicKey: "your_public_api_key",
        privateKey: "your_private_api_key",
        endpoint: "https://ik.imagekit.io/your_imagekit_id/",
      },
      collections: {
        media: {
          uploadOption: {
            folder: "some folder",
            extensions: [
              {
                name: "aws-auto-tagging",
                minConfidence: 80, // only tags with a confidence value higher than 80% will be attached
                maxTags: 10, // a maximum of 10 tags from aws will be attached
              },
              {
                name: "google-auto-tagging",
                minConfidence: 70, // only tags with a confidence value higher than 70% will be attached
                maxTags: 10, // a maximum of 10 tags from google will be attached
              },
            ],
          },
          savedProperties: ["url", "AITags"],
        },
      },
    }),
  ],
});

Plugin options

This plugin have 1 parameter that contain an object.

OptionDescription
config (required)ImageKit Config ImageKitOptions
collections (optional)Collections options

config

Type object

  • publicKey: type string
  • privateKey: type string
  • endpoint: type string;

collections

Type object

  • [key] (required)
    type: string
    description: Object keys should be PayloadCMS collection name that store the media/image.
    value type: object
    value options:

    • uploadOption (optional)
      type: object
      type detail: TUploadOption. Except file.
      description: An options to saved in ImageKit.

    • savedProperties (optional)
      type: []string
      type detail: TImageKitProperties. Except thumbnailUrl and fileId.
      description: An object that saved to PayloadCMS/Database that you may need it for your Frontend.

    • disableLocalStorage (optional)
      type: boolean
      default: true
      description: Completely disable uploading files to disk locally. More

Payload Cloud

If your project is hosted using Payload Cloud - their default file storage solution will conflict with this plugin. You will need to disable file storage via the Payload Cloud plugin like so:

// ...
plugins: [
  payloadCloud({
    storage: false, // Disable file storage
  }),
  imagekitPlugin({
    // Your imagekit config here
  }),
],
// ...

Screenshot

image

Similar plugins

payload imagekit — Payload Plugin Directory