Skip to Content
Clerk logo

Clerk Docs

Ctrl + K
Go to clerk.com

Organization metadata

Organization metadata allows you to store information about an organization that is not part of the standard fields, such as custom attributes that are specific to your application.

There are two types of metadata: public and private.

Both public and private metadata are set and can be accessed from the Backend API(opens in a new tab). Only public metadata can be accessed from the Frontend API(opens in a new tab).

Both the Organization and Organization Membership objects have the metadata fields: publicMetadata and privateMetadata.

The publicMetadata property should be used if you need to set some metadata from your backend and have them displayed as read-only on the frontend.

The privateMetadata property should be used if custom attributes contain sensitive information that should not be displayed on the frontend.

Set organization metadata

To ease the flow of setting metadata, Clerk provides the updateOrganizationMetadata() and updateOrganizationMembershipMetadata() methods from the Backend SDK(opens in a new tab), which is a wrapper around the Backend API(opens in a new tab).

Metadata is limited to 8kb maximum.

Last updated on April 8, 2024

What did you think of this content?

Clerk © 2024