Datacenter build and management service
https://github.com/joyent/conch-api/blob/master/lib/Conch/Route/JSONSchema.pm
Sets up the routes for /json_schema that do not require authentication.
Sets up the routes for /json_schema that require authentication.
GET /json_schema/query_params/:json_schema_name
GET /json_schema/request/:json_schema_name
GET /json_schema/response/:json_schema_name
GET /json_schema/common/:json_schema_name
GET /json_schema/device_report/:json_schema_name
Returns the JSON Schema document specified by type and name, used for validating endpoint requests and responses.
$defs
.application/schema+json
).POST /json_schema/:json_schema_type/:json_schema_name
Stores a new JSON Schema in the database. Unresolvable $ref
s are not permitted.
application/schema+json
).201 Created
, plus Location headerGET /json_schema/:json_schema_id
GET /json_schema/:json_schema_type/:json_schema_name/:json_schema_version
GET /json_schema/:json_schema_type/:json_schema_name/latest
Fetches the referenced JSON Schema document.
application/schema+json
).DELETE /json_schema/:json_schema_id
DELETE /json_schema/:json_schema_type/:json_schema_name/:json_schema_version
Deactivates the database entry for a single JSON Schema, rendering it unusable.
This operation is not permitted until all references from other documents have been removed,
exception of references using .../latest
which will now resolve to a different document
(and internal references will be re-verified).
If this JSON Schema was the latest of its series (/json_schema/foo/bar/latest
), then that
.../latest
link will now resolve to an earlier version in the series.
204 No Content
GET /json_schema/:json_schema_type
GET /json_schema/:json_schema_type/:json_schema_name
Gets meta information about all JSON Schemas in a particular type series, or a type and name series.
Optionally accepts the following query parameter:
active_only
(default 0
): set to 1
to only query for JSON Schemas that have not been
deactivated.with_hardware_products
(default 0
): set to 1
to include a list of hardware products
that reference each JSON Schema
Copyright Joyent, Inc.
This Source Code Form is subject to the terms of the Mozilla Public License, v.2.0. If a copy of the MPL was not distributed with this file, You can obtain one at https://www.mozilla.org/en-US/MPL/2.0/.