diff --git a/docs/agency-index.md b/docs/agency-index.md index 293696d..db8d8ae 100644 --- a/docs/agency-index.md +++ b/docs/agency-index.md @@ -2,6 +2,8 @@ The SHARE IT Act requires federal agencies to publish metadata for their software projects. This metadata is compiled into an **agency-index.json** file, which serves as a centralized inventory of the agency's software portfolio. +View the agency-index.json schema here: https://github.com/DSACMS/gov-codejson/tree/main/schemas/agency-index/schema-2.0.0.json + To create an agency-index.json: 1. Identify GitHub organizations and other platforms where source code is hosted 2. Generate the agency-index.json using the tools below. Learn more about usage in [procedures.md](https://github.com/DSACMS/gov-codejson/blob/main/docs/procedures.md#generate-an-agency-indexjson-file-for-agencies) @@ -11,4 +13,4 @@ To create an agency-index.json: - Agency's top level domain (TLD) - A GitHub repository -Agency index files are found here: https://github.com/DSACMS/code-gov/tree/main/agency-indexes \ No newline at end of file +More examples of agency index files can be found here: https://github.com/DSACMS/code-gov/tree/main/agency-indexes \ No newline at end of file diff --git a/schemas/agency-index/schema-2.0.0.json b/schemas/agency-index/schema-2.0.0.json new file mode 100644 index 0000000..496f8d2 --- /dev/null +++ b/schemas/agency-index/schema-2.0.0.json @@ -0,0 +1,55 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "title": "Code.gov Inventory", + "description": "A federal source code catalog", + "type": "object", + "required": [ + "version", + "measurementType", + "agency", + "releases" + ], + "properties": { + "agency": { + "description": "The agency acronym for Clinger Cohen Act agency, as defined by the United States Government Manual.", + "type": "string" + }, + "measurementType": { + "type": "object", + "properties": { + "ifOther": { + "description": "A one- or two- sentence description of the measurement type used, if 'other' is selected as the value of 'method' field.", + "type": "string" + }, + "method": { + "description": "An enumerated list of methods for measuring the open source requirement.", + "type": "string", + "enum": [ + "linesOfCode", + "modules", + "cost", + "projects", + "systems", + "other" + ] + } + }, + "additionalProperties": false + }, + "releases": { + "type": "array", + "items": { + "allOf": [ + { + "$ref": "../schema-2.0.0.json" + } + ] + }, + "additionalProperties": false + }, + "version": { + "description": "The version of the metadata schema in use. Implements semantic versioning 2.0.0 rules as defined at http://semver.org", + "type": "string" + } + } +} \ No newline at end of file