diff --git a/specs/Data-Gateway.json b/specs/Data-Gateway.json index b7262d9..abf7cfd 100644 --- a/specs/Data-Gateway.json +++ b/specs/Data-Gateway.json @@ -4883,6 +4883,69 @@ "updatedBy": "John Doe" } ] + }, + "CloudMatrix.Publisher": { + "title": "Cloud Matrix Third-Party Publisher", + "type": "object", + "description": "Represents a third-party publisher of Cloud Matrix assessment alternate product, including their name, isActive and optional metadata field for extensibility.", + "properties": { + "name": { + "type": "string", + "description": "Name of the publisher.", + "examples": [ + "Microsoft", + "Google" + ] + }, + "isActive": { + "type": "boolean", + "description": "Indicates whether the publisher is currently active for users to choose from.", + "examples": [ + true, + false + ] + }, + "metadata": { + "type": "object", + "properties": { + "updatedAt": { + "$ref": "#/components/schemas/DateTimeStringType" + }, + "updatedBy": { + "type": "string", + "examples": [ + "John Doe", + "admin" + ] + } + }, + "description": "Additional metadata about the publisher to provide extensibility.", + "examples": [ + { + "updatedAt": "2025-12-15T21:13:12.821Z", + "updatedBy": "John Doe" + } + ] + } + }, + "required": [ + "name", + "isActive" + ], + "examples": [ + { + "name": "Microsoft", + "isActive": true + }, + { + "name": "Google", + "isActive": false, + "metadata": { + "updatedAt": "2025-12-15T21:13:12.821Z", + "updatedBy": "John Doe" + } + } + ] } }, "securitySchemes": { @@ -4905,7 +4968,7 @@ }, "description": "Collects data from the various SHI Lab products and makes it available in a standardized way.", "title": "SHI - Data Gateway", - "version": "3.2.2" + "version": "3.3.0" }, "openapi": "3.1.1", "paths": { @@ -11508,6 +11571,159 @@ ], "summary": "Get a List of Cloud Matrix Template Metadata Objects" } + }, + "/Api/CloudMatrix/Publishers": { + "get": { + "description": "Get a list of Cloud Matrix third-party publishers.\n\nThis endpoint requires the `CloudMatrix.Read` scope (permission).", + "operationId": "/Api/CloudMatrix/Publishers/Get", + "responses": { + "200": { + "description": "Successful request to return the whole list of publishers.", + "content": { + "application/json": { + "schema": { + "type": "array", + "minItems": 1, + "items": { + "$ref": "#/components/schemas/CloudMatrix.Publisher" + } + }, + "examples": { + "Sample Output": { + "description": "A list of all publishers.", + "summary": "All Publishers", + "value": [ + { + "name": "Microsoft", + "isActive": true + }, + { + "name": "Google", + "isActive": false, + "metadata": { + "updatedAt": "2025-12-15T21:13:12.821Z", + "updatedBy": "John Doe" + } + } + ] + } + } + } + } + }, + "204": { + "description": "When the publisher JSON file does not exist on blob storage.", + "$ref": "#/components/responses/204" + }, + "500": { + "$ref": "#/components/responses/500" + } + }, + "tags": [ + "Cloud Matrix" + ], + "summary": "Get a List of All Cloud Matrix Third-Party Publishers" + }, + "put": { + "description": "Replace the list of Cloud Matrix third-party publishers. This will overwrite the existing list of publishers with the list provided in the request body. \n\nThis endpoint is only accessible from the `SHI` and `SHI Lab` tenants and requires the `CloudMatrix.ReadWrite.All` scope (permission).", + "operationId": "/Api/CloudMatrix/Publishers/Put", + "requestBody": { + "description": "The JSON payload containing all publishers to update.", + "required": true, + "content": { + "application/json": { + "schema": { + "type": "array", + "minItems": 1, + "items": { + "$ref": "#/components/schemas/CloudMatrix.Publisher" + } + }, + "examples": { + "Minimal Input": { + "description": "Sample input which includes one publisher.", + "summary": "A Sample Input That Is Valid", + "value": [ + { + "name": "Microsoft", + "isActive": true + } + ] + }, + "Minimal Input With Metadata": { + "description": "Sample input which includes two publishers, one with metadata.", + "summary": "A Sample Input With One Publisher That Contains Metadata", + "value": [ + { + "name": "Microsoft", + "isActive": true + }, + { + "name": "Google", + "isActive": false, + "metadata": { + "updatedAt": "2025-12-15T21:13:12.821Z", + "updatedBy": "John Doe" + } + } + ] + } + } + } + } + }, + "responses": { + "200": { + "description": "Indicates successful upload and replacement of publisher list on blob storage.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "isOverwrite": { + "type": "boolean", + "examples": [ + true, + false + ] + } + } + }, + "examples": { + "Initial Upload": { + "description": "This example demonstrates the response when the list of publishers is being uploaded for the first time. Since there is no existing list on blob storage, the `isOverwrite` property is set to false.", + "summary": "Initial Upload of Publishers", + "value": { + "isOverwrite": false + } + }, + "Replace Successful": { + "description": "This example demonstrates the response when the list of publishers is being replaced successfully. Since there is an existing list on blob storage, the `isOverwrite` property is set to true.", + "summary": "Successful Replacement of Publishers", + "value": { + "isOverwrite": true + } + } + } + } + } + }, + "400": { + "description": "Indicates the request body is missing, is null, is not a valid CloudMatrix.Publisher array, or is an empty array.", + "$ref": "#/components/responses/400" + }, + "415": { + "description": "Indicating the request does not have the correct content type header application/json." + }, + "500": { + "$ref": "#/components/responses/500" + } + }, + "tags": [ + "Cloud Matrix" + ], + "summary": "Upload and Replace the List of Cloud Matrix Third-Party Publishers" + } } }, "security": [ @@ -11567,4 +11783,4 @@ "name": "Cloud Matrix" } ] -} +} \ No newline at end of file diff --git a/src/dataGateway/TypeScript/package-lock.json b/src/dataGateway/TypeScript/package-lock.json index d6f92ec..00bb9be 100644 --- a/src/dataGateway/TypeScript/package-lock.json +++ b/src/dataGateway/TypeScript/package-lock.json @@ -1,12 +1,12 @@ { "name": "@shi-corp/sdk-data-gateway", - "version": "3.2.2", + "version": "3.3.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@shi-corp/sdk-data-gateway", - "version": "3.2.2", + "version": "3.3.0", "license": "MIT", "dependencies": { "@microsoft/kiota-authentication-azure": "~1.0.0-preview.100", diff --git a/src/dataGateway/TypeScript/package.json b/src/dataGateway/TypeScript/package.json index e3cd51c..485a00c 100644 --- a/src/dataGateway/TypeScript/package.json +++ b/src/dataGateway/TypeScript/package.json @@ -1,6 +1,6 @@ { "name": "@shi-corp/sdk-data-gateway", - "version": "3.2.2", + "version": "3.3.0", "type": "module", "main": "bin/index.js", "description": "SDK client used to interface with the SHI Data Gateway service.",