Skip to content

Commit 2c2162e

Browse files
authored
Add new extension namespace registry (#3107)
* Add new extension namespace registry * Fixed error in format registry table * Added clarification registry submission process * Update index.md Added a clarification and a fix.
1 parent 452b94d commit 2c2162e

File tree

6 files changed

+74
-1
lines changed

6 files changed

+74
-1
lines changed

_config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,8 @@ collections:
3030
name: Alternative Schema Type Registry
3131
output: true
3232
permalink: /registry/:collection/:title
33+
namespace:
34+
slug: namespace
35+
name: Extension Namespace Registry
36+
output: true
37+
permalink: /registry/:collection/:title

api/namespace.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
---
3+
{
4+
{% for page in site.namespace %}"{{ page.slug }}": {
5+
"slug": "{{ page.slug }}",
6+
"issue": "{{ page.issue }}",
7+
"description": "{{ page.description }}",
8+
"owner": "{{ page.owner }}"
9+
}{% unless forloop.last %},{% endunless %}
10+
{% endfor %}
11+
}

registries/_namespace/ms.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
owner: DarrelMiller
3+
issue:
4+
description: Extensions created and used by Microsoft
5+
layout: default
6+
---
7+
8+
# <a href="..">{{ page.collection }}</a>
9+
10+
## {{ page.slug }} - {{ page.description }}
11+
12+
13+
The `x-{{page.slug}}-` prefix is reserved for extensions created by Microsoft. These extensions are available for use by anyone.
14+
15+
{% if page.issue %}
16+
### GitHub Issue
17+
18+
* [#{{ page.issue }}](https://github.com/OAI/OpenAPI-Specification/issues/{{ page.issue }})
19+
{% endif %}

registries/_namespace/oas-draft.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
owner: DarrelMiller
3+
issue:
4+
description: Extensions created by OAI to indicate proposed changes to the OAS specification
5+
layout: default
6+
---
7+
8+
# <a href="..">{{ page.collection }}</a>
9+
10+
## {{ page.slug }} - {{ page.description }}
11+
12+
13+
The `x-{{page.slug}}-` prefix is reserved for extensions created as part of the [draft features(https://github.com/OAI/OpenAPI-Specification/blob/main/DEVELOPMENT.md#draft-features)] process. These extensions are available for use by anyone.
14+
15+
{% if page.issue %}
16+
### GitHub Issue
17+
18+
* [#{{ page.issue }}](https://github.com/OAI/OpenAPI-Specification/issues/{{ page.issue }})
19+
{% endif %}

registry/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ permalink: /registry/index.html
55

66
## Contributing
77

8-
Please raise a [Pull-Request](https://github.com/OAI/OpenAPI-Specification/pulls) or [Issue](https://github.com/OAI/OpenAPI-Specification/issues) to contribute or discuss a registry value.
8+
Please raise a [Pull-Request](https://github.com/OAI/OpenAPI-Specification/pulls) against the `gh-pages` branch and add a new Markdown file to a folder in the `registries/_{registryName}`. The name of the file is considered the registration entry, ignoring the file extension. Alternatively you can open an [Issue](https://github.com/OAI/OpenAPI-Specification/issues) to discuss a registry value.
99

1010
### Contents
1111

registry/namespace.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
layout: default
3+
permalink: /registry/namespace/index.html
4+
---
5+
6+
# Namespace Registry
7+
8+
To allow for creators of OpenAPI descriptions to define new extensions without the risk of name collisions, a namespace registry is maintained by OAI. The namespace registry is a simple list of unique identifiers that are used as part of a prefix for extensions to ensure uniqueness. A prefix has the format `x-{namespace}-` where `{namespace}` is a unique string associated to the creator of the extensions within the namespace. Namespace identifiers MUST be registered as lowercase identifiers.
9+
10+
## Contributing
11+
12+
Please raise a [Pull-Request](https://github.com/OAI/OpenAPI-Specification/pulls) or [Issue](https://github.com/OAI/OpenAPI-Specification/issues) to contribute or discuss a registry value.
13+
14+
## Values
15+
16+
|Value|Prefix|Description|Issue|
17+
|---|---|---|---|
18+
{% for value in site.namespace %}| <a href="/registry/namespace/{{ value.slug }}.html">{{ value.slug }}</a> | x-{{ value.slug }}-|{{ value.description }} | {% if value.issue %}<a href="https://github.com/OAI/OpenAPI-Specification/issues/{{ value.issue }}">#{{ value.issue }}</a>{% endif %} |
19+
{% endfor %}

0 commit comments

Comments
 (0)