diff --git a/.github/workflows/release-github.yml b/.github/workflows/release-github.yml index 897303fae..5dfe64c51 100644 --- a/.github/workflows/release-github.yml +++ b/.github/workflows/release-github.yml @@ -86,9 +86,15 @@ jobs: npm run dist - name: Check if semantic-release created a build id: check_build - uses: andstor/file-existence-action@v2 + uses: actions/github-script@v6 with: - files: './src/sdks/core/dist/lib/firebolt.mjs' + script: | + const fs = require('fs'); + const path = './src/sdks/core/dist/lib/firebolt.mjs'; + return fs.existsSync(path); + - name: File Existence Output + run: | + echo "File exists: ${{ steps.check_build.outputs.result }}" - name: Release Firebolt SDKs to NPM if: steps.check_build.outputs.files_exists == 'true' && github.event_name != 'pull_request' && (github.ref_name != 'main' || github.event_name == 'workflow_dispatch') env: diff --git a/package-lock.json b/package-lock.json index d1e53d25e..4a6d3d7da 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,7 +19,7 @@ "devDependencies": { "@commitlint/cli": "^17.0.3", "@commitlint/config-conventional": "^17.0.3", - "@firebolt-js/openrpc": "3.1.1-next.2", + "@firebolt-js/openrpc": "3.1.1", "@firebolt-js/schemas": "2.0.0", "@saithodev/semantic-release-backmerge": "^3.2.0", "@semantic-release/changelog": "^6.0.1", @@ -1075,9 +1075,9 @@ "link": true }, "node_modules/@firebolt-js/openrpc": { - "version": "3.1.1-next.2", - "resolved": "https://registry.npmjs.org/@firebolt-js/openrpc/-/openrpc-3.1.1-next.2.tgz", - "integrity": "sha512-D5b8ovtmRQNSlJ52LRJHtp0rmvlao6axzpmqYjW8wsljNeTj9QcAJ1xiUiYBt2uFitvGM6zQA04e3rbJhErJ+w==", + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/@firebolt-js/openrpc/-/openrpc-3.1.1.tgz", + "integrity": "sha512-+ypWAo02Q/eYc3PQ0pHii/37u2Q9fIdeGyT8o9ghLO1rIYgB5q7N2rTE0hYEKgbOTAq6GdyFLV/TZ4Vj8D2jCA==", "dev": true, "dependencies": { "ajv": "^8.12.0", @@ -16962,7 +16962,7 @@ }, "src/sdks/core": { "name": "@firebolt-js/sdk", - "version": "1.3.1-next.1", + "version": "1.3.1-next.2", "license": "Apache-2.0", "devDependencies": { "jest": "^28.1.0", @@ -16973,7 +16973,7 @@ }, "src/sdks/discovery": { "name": "@firebolt-js/discovery-sdk", - "version": "1.3.1-next.1", + "version": "1.3.1-next.2", "license": "Apache-2.0", "devDependencies": { "jest": "^28.1.0", @@ -16984,7 +16984,7 @@ }, "src/sdks/manage": { "name": "@firebolt-js/manage-sdk", - "version": "1.3.1-next.1", + "version": "1.3.1-next.2", "license": "Apache-2.0", "devDependencies": { "jest": "^28.1.0", diff --git a/package.json b/package.json index 4da98cae0..0ebfc8eeb 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ "devDependencies": { "@commitlint/cli": "^17.0.3", "@commitlint/config-conventional": "^17.0.3", - "@firebolt-js/openrpc": "3.1.1-next.2", + "@firebolt-js/openrpc": "3.1.1", "@firebolt-js/schemas": "2.0.0", "@saithodev/semantic-release-backmerge": "^3.2.0", "@semantic-release/changelog": "^6.0.1", diff --git a/src/openrpc/device.json b/src/openrpc/device.json index 0dd8e11b4..54c9db7d4 100644 --- a/src/openrpc/device.json +++ b/src/openrpc/device.json @@ -41,7 +41,7 @@ }, { "name": "distributor", - "summary": "Get the distributor ID for this device", + "summary": "Get the name of the entity which is distributing the current device. There can be multiple distributors which distribute the same device model.", "params": [], "tags": [ { @@ -74,7 +74,7 @@ }, { "name": "platform", - "summary": "Get the platform ID for this device", + "summary": "Get a transient platform identifier for the device. This API should be used to correlate metrics on the device only and cannot be guaranteed to have consistent responses across platforms.", "params": [], "tags": [ { @@ -173,7 +173,7 @@ }, { "name": "model", - "summary": "Get the device model", + "summary": "Get the manufacturer designated model of the device", "params": [], "tags": [ { @@ -239,7 +239,7 @@ }, { "name": "make", - "summary": "Get the device make", + "summary": "Get the manufacturer of the device model", "params": [], "tags": [ { diff --git a/src/openrpc/discovery.json b/src/openrpc/discovery.json index 01ab2205e..306a10e0a 100644 --- a/src/openrpc/discovery.json +++ b/src/openrpc/discovery.json @@ -561,7 +561,7 @@ }, { "name": "progress", - "summary": "How much of the content has been watched (percentage as 0-1 for VOD, number of seconds for live)", + "summary": "How much of the content has been watched (percentage as (0-0.999) for VOD, number of seconds for live)", "schema": { "type": "number", "minimum": 0 @@ -1181,7 +1181,7 @@ "params": [ { "name": "appId", - "value": "xrn:firebolt:application-type:settings " + "value": "xrn:firebolt:application-type:settings" }, { "name": "intent", @@ -1250,6 +1250,43 @@ "name": "success", "value": true } + }, + { + "name": "Launch the Aggregated Experience to it's search screen.", + "params": [ + { + "name": "appId", + "value": "xrn:firebolt:application-type:main" + }, + { + "name": "intent", + "value": { + "action": "search", + "data": { + "query": "a cool show", + "suggestions": [ + { + "entityType": "program", + "programType": "movie", + "entityId": "xyz" + }, + { + "entityType": "music", + "musicType": "song", + "entityId": "abc" + } + ] + }, + "context": { + "source": "voice" + } + } + } + ], + "result": { + "name": "success", + "value": true + } } ] }, diff --git a/src/openrpc/localization.json b/src/openrpc/localization.json index db92eeb5b..cc2a803ce 100644 --- a/src/openrpc/localization.json +++ b/src/openrpc/localization.json @@ -298,7 +298,7 @@ ] } ], - "summary": "Get any platform-specific localization information, in an Map", + "summary": "Get any platform-specific localization information", "params": [], "result": { "name": "info", @@ -306,7 +306,7 @@ "schema": { "type": "object", "additionalProperties": { - "type": "string", + "type": ["number", "string", "boolean"], "maxLength": 1024 }, "maxProperties": 32 @@ -346,9 +346,9 @@ }, { "name": "value", - "summary": "Value to be set for additionalInfo", + "summary": "Value to be set for additionalInfo. Value can be a number, string or boolean", "schema": { - "type": "string" + "type": ["number", "string", "boolean"] }, "required": true } diff --git a/src/openrpc/second_screen.json b/src/openrpc/second_screen.json index af25e2c9d..e7cd1054b 100644 --- a/src/openrpc/second_screen.json +++ b/src/openrpc/second_screen.json @@ -13,7 +13,7 @@ { "name": "capabilities", "x-uses": [ - "xrn:firebolt:capability:device:info" + "xrn:firebolt:capability:secondscreen:protocol" ] } ], diff --git a/src/schemas/intents.json b/src/schemas/intents.json index 8f5a86c38..4c01f7c39 100644 --- a/src/schemas/intents.json +++ b/src/schemas/intents.json @@ -609,10 +609,16 @@ "properties": { "query": { "type": "string" + }, + "suggestions": { + "type": "array", + "items": { + "$ref": "https://meta.comcast.com/firebolt/entity#/definitions/Entity" + } } }, "additionalProperties": false - } + } } } ], diff --git a/src/sdks/core/sdk.config.json b/src/sdks/core/sdk.config.json index f34bf72c8..c682afc3b 100644 --- a/src/sdks/core/sdk.config.json +++ b/src/sdks/core/sdk.config.json @@ -129,7 +129,7 @@ "module": "SecondScreen", "use": [ "xrn:firebolt:capability:protocol:dial", - "xrn:firebolt:capability:device:info" + "xrn:firebolt:capability:secondscreen:protocol" ] }, { diff --git a/src/sdks/core/test/suite/device.test.ts b/src/sdks/core/test/suite/device.test.ts index 7f9601cac..f5a55849d 100644 --- a/src/sdks/core/test/suite/device.test.ts +++ b/src/sdks/core/test/suite/device.test.ts @@ -112,17 +112,17 @@ test("Device.make()", () => { }); test("Device.hdcp()", () => { - const expectedOutput: Device.BooleanMap = { + const expectedOutput: Device.HDCPVersionMap = { "hdcp1.4": true, "hdcp2.2": true, }; - return Device.hdcp().then((res: Device.BooleanMap) => { + return Device.hdcp().then((res: Device.HDCPVersionMap) => { expect(res).toEqual(expectedOutput); }); }); test("Device.hdcp(subscriber)", () => { - return Device.hdcp((supportedHdrProfiles: Device.BooleanMap) => {}).then( + return Device.hdcp((supportedHdrProfiles: Device.HDCPVersionMap) => {}).then( (res: number) => { expect(res > 0).toBe(true); }