Skip to content

Instantly share code, notes, and snippets.

@TheRealJon
Last active October 8, 2024 19:52
Show Gist options
  • Save TheRealJon/f65c8cb21a15881c190aca406fad71eb to your computer and use it in GitHub Desktop.
Save TheRealJon/f65c8cb21a15881c190aca406fad71eb to your computer and use it in GitHub Desktop.
{
"openapi": "3.0.3",
"info": {
"title": "OLM V1 Console API - OpenAPI 3.0",
"description": "Proposed REST endpoints for OCP Console UI",
"contact": {
"email": "[email protected]"
},
"license": {
"name": "The Unlicense License",
"url": "https://unlicense.org/"
},
"version": "0.0.1"
},
"paths": {
"/catalogs/{catalog}": {
"get": {
"summary": "List all FBC objects provided by the specified catalog. Can be filtered by schemas, packages, and names provided through URL search params.",
"operationId": "listObjects",
"parameters": [
{
"name": "catalog",
"in": "path",
"description": "name of catalog to list objects from",
"required": true,
"explode": true,
"schema": {
"type": "array",
"items": {
"type": "string"
}
}
},
{
"name": "schemas",
"in": "query",
"description": "schemas to filter by",
"required": false,
"schema": {
"type": "array",
"items": {
"type": "string"
}
}
},
{
"name": "packages",
"in": "query",
"description": "packages to filter by",
"required": false,
"schema": {
"type": "array",
"items": {
"type": "string"
}
}
},
{
"name": "names",
"in": "query",
"description": "names to filter by",
"required": false,
"schema": {
"type": "array",
"items": {
"type": "string"
}
}
}
],
"responses": {
"200": {
"description": "successful operation",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"required": ["schema"],
"additionalProperties": true,
"properties": {
"schema": {
"type": "string",
"enum": ["olm.package", "olm.channel", "olm.bundle"]
},
"package": {
"type": "string"
},
"name": {
"type": "string"
},
"properties": {
"type": "array"
}
}
}
}
}
}
},
"400": {
"description": "Invalid request"
},
"404": {
"description": "Catalog not found"
}
}
}
},
"/catalogs/{catalog}/schema/{schema}/package/{package}/name/{name}": {
"get": {
"summary": "Get a specific object from the FBC using a fully-qualified path",
"operationId": "getObject",
"parameters": [
{
"name": "catalog",
"in": "path",
"description": "name of catalog that provides the object",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "schema",
"in": "path",
"description": "schema of the desired object",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "package",
"description": "package the desired object belongs to",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "name",
"description": "name of the desired object",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "successful operation",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": ["schema"],
"additionalProperties": true,
"properties": {
"schema": {
"type": "string",
"enum": ["olm.package", "olm.channel", "olm.bundle"]
},
"package": {
"type": "string"
},
"name": {
"type": "string"
},
"properties": {
"type": "array"
}
}
}
}
}
},
"400": {
"description": "Invalid request"
},
"404": {
"description": "Object not found"
}
}
}
}
},
"components": {
"schemas": {
"Meta": {
"type": "object",
"required": ["schema"],
"additionalProperties": true,
"properties": {
"schema": {
"type": "string",
"enum": ["olm.package", "olm.channel", "olm.bundle"]
},
"package": {
"type": "string"
},
"name": {
"type": "string"
},
"properties": {
"type": "array",
"items": {
"type": "object"
}
}
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
OSZAR »