Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 24 additions & 2 deletions docs/commercial.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,33 @@ Sourcemeta One is available in two editions:
hosting solution that competes with Sourcemeta. After four years from each
release, the code transitions to AGPL-3.0.

- **Enterprise**: Includes additional features and supply chain security
capabilities not available in the Community edition. Requires a [commercial
- **Enterprise**: Includes the [Standard
Library](https://github.com/sourcemeta/std), additional features, and supply
chain security capabilities not available in the Community edition. Requires
a [commercial
license](https://github.com/sourcemeta/one/blob/main/LICENSE-COMMERCIAL)
from Sourcemeta.

## Standard Library

The Enterprise edition includes a growing library of hand-crafted high-quality
schemas maintained by Sourcemeta. The standard library provides ready-to-use
schemas for commonly used standards and specifications such as IETF URIs, email
addresses, JSON Pointers, HTTP problem details, and IEEE POSIX paths, among
others. To use it, add `@sourcemeta/std/v0` to the
[`extends`](configuration.md#extends) property of your configuration file.

For organizations looking to double down on their JSON Schema governance
initiative, the standard library provides a strong foundation of high-quality
schemas ready on day one, removing the need to invest significant time and
effort into authoring and maintaining a large catalog of schemas from scratch.

Every schema in the standard library is maintained by a member of the JSON
Schema Technical Steering Committee, extensively unit tested, performance tuned
for production use, and checked for compliance against the JSON Schema
specification. As part of the Enterprise plan, Sourcemeta will extend the
standard library with any additional standard your organization requires.

## Supply Chain Security

Starting with v4.2.2, the Enterprise container image ships with built-in
Expand Down
32 changes: 19 additions & 13 deletions docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,15 +132,15 @@ contain the actual schema definitions that power your instance.

| Property | Type | Required | Default | Description |
|-----------------|------|----------|---------|-------------|
| `/path` | String | :red_circle: **Yes** (unless `includes` is set) | N/A | The path (relative to the location of the configuration file) to the directory which includes the schemas for this collection. The directory will be recursively traversed in search of `.json`, `.yaml`, or `.yml` schemas |
| `/path` | String | :red_circle: **Yes** (unless `include` is set) | N/A | The path (relative to the location of the configuration file) to the directory which includes the schemas for this collection. The directory will be recursively traversed in search of `.json`, `.yaml`, or `.yml` schemas |
| `/baseUri` | String | No | *The `file://` URI of the configuration directory* | The base URI of every schema file that is part of this collection, for rebasing purposes. If a schema defines an explicit identifier that is not relative to this base URI, the generation of the instance will fail |
| `/defaultDialect` | String | No | None | The default JSON Schema dialect URI to use for schemas that do not declare the `$schema` keyword |
| `/title` | String | No | None | The concise title of the schema collection |
| `/description` | String | No | None | A longer description of the schema collection |
| `/email` | String | No | None | The e-mail address associated with the schema collection |
| `/github` | String | No | None | The GitHub organisation or `organisation/repository` identifier associated with the schema collection |
| `/website` | String | No | None | The absolute URL to the website associated with the schema collection |
| `/includes` | String | No | None | A `jsonschema.json` manifest definition to include in-place. See the [Includes](#includes) section for more information. **If this property is set, none of the other properties can be set (including `path`)** |
| `/include` | String | No | None | A `jsonschema.json` manifest definition to include in-place. See the [Include](#include) section for more information. **If this property is set, none of the other properties can be set (including `path`)** |
| `/resolve` | Object | No | None | A URI-to-URI map to hook into the schema reference resolution process. See the [Resolve](#resolve) section for more information |
| `/lint` | Object | No | None | Linting configuration for this schema collection. See the [JSON Schema CLI configuration](https://github.com/sourcemeta/jsonschema/blob/main/docs/configuration.markdown) for more information |
| `/lint/rules` (**Enterprise**) | Array | No | None | An array of file paths (relative to the configuration file location) to custom linting rule definitions |
Expand All @@ -157,9 +157,9 @@ contain the actual schema definitions that power your instance.
organise them into a tree of nested subdirectories. A large number of
schemas spread across multiple levels of directories scales well.

### Includes
### Include

The `includes` property enables modular schema collection management by
The `include` property enables modular schema collection management by
allowing you to extract collection definitions into separate `jsonschema.json`
files and reference them in-place. Unlike inline definitions, this approach
promotes reusability across multiple configuration files while maintaining
Expand All @@ -173,7 +173,7 @@ during processing. For example:
"url": "https://schemas.example.com",
"contents": {
"my-first-collection": {
"includes": "./jsonschema.json"
"include": "./jsonschema.json"
}
}
}
Expand All @@ -186,7 +186,7 @@ during processing. For example:
}
```

If a directory path is provided to the `includes` property, the instance will
If a directory path is provided to the `include` property, the instance will
look for a file called `jsonschema.json` inside such directory.

### Resolve
Expand All @@ -196,15 +196,21 @@ resolution process. When set, the object translates any reference that equals a
property name in the object to the corresponding property value.

This is useful when mounting schemas that consume other external schemas and
you want to route the reference back into the instance. For example, let's say
your schema collection depends on [GeoJSON](https://geojson.org) and has
various references to its latest official URL:
`https://geojson.org/schema/GeoJSON.json`. Instead of depending on an external
resource outside your control, you can configure the instance to extend from
the `@sourcemeta/std` built-in collection and rephrase the
you want to route the reference back into the instance. For example, if you are
an Enterprise customer, let's say your schema collection depends on
[GeoJSON](https://geojson.org) and has various references to its latest
official URL: `https://geojson.org/schema/GeoJSON.json`. Instead of depending
on an external resource outside your control, you can configure the instance to
extend from the `@sourcemeta/std/v0` built-in collection and rephrase the
`https://geojson.org/schema/GeoJSON.json` references to consume from the
internal version:

!!! note

The `@sourcemeta/std/v0` standard library is only available to Enterprise
customers. Learn more about [commercial
licensing](commercial.md#standard-library).

```json hl_lines="3 8" title="one.json"
{
"url": "https://schemas.example.com",
Expand Down Expand Up @@ -248,7 +254,7 @@ collection identifier (prefixed with `@`). For example:
```json hl_lines="3" title="one.json"
{
"url": "https://schemas.example.com",
"extends": [ "@self/v1", "@geojson/v1.0.5", "../path/to/my/other/config/one.json" ]
"extends": [ "@self/v1", "../path/to/my/other/config/one.json" ]
}
```

Expand Down
Loading