This package has been deprecated

Author message:

replaced by @ceramicstudio/idx-tools

@ceramicstudio/idx-schemas
TypeScript icon, indicating that this package has built-in type declarations

0.1.5 • Public • Published

IDX schemas

Installation

npm install @ceramicstudio/idx-schemas

Interfaces and types

CeramicApi

Ceramic API interface exported by the @ceramicnetwork/ceramic-common library

SchemaItem

interface SchemaItem {
  docId?: string
  name: string
  schema: Record<string, unknown>
}

PublishConfig

interface PublishConfig {
  ceramic: CeramicApi
  schemas: Array<SchemaItem>
}

Constants

schemas

A record of all the JSON schemas defined and used by IDX, with the following keys:

schemasList

An array of SchemaItem of the exported schemas

API

isSchemaSecure

Arguments

  1. schema: Record<string, unknown>: the JSON schema definition

Returns boolean

publishSchema

Creates or updates (if a docId is provided) a schema on the Ceramic network

Arguments

  1. ceramic: CeramicApi
  2. item: SchemaItem

Returns Promise<string> the docId of the published schema

publishSchemas

Creates or updates schemas on the Ceramic network

Arguments

  1. config: PublishConfig

Returns Promise<Record<string, string>> the name to docId record of the published schemas

License

Apache-2.0 OR MIT

Readme

Keywords

none

Package Sidebar

Install

npm i @ceramicstudio/idx-schemas

Weekly Downloads

1

Version

0.1.5

License

(Apache-2.0 OR MIT)

Unpacked Size

36.6 kB

Total Files

21

Last publish

Collaborators

  • ceramic-velvetshark
  • cb3box
  • jpham2023
  • paul_lecam
  • oed
  • ukstv