diff --git a/src/Spaces.test.ts b/src/Spaces.test.ts index c0451e17..41d80dc3 100644 --- a/src/Spaces.test.ts +++ b/src/Spaces.test.ts @@ -41,8 +41,7 @@ describe('Spaces', () => { it('applies the agent header to an existing SDK instance', ({ client }) => { const spaces = new Spaces(client); expect(client.options.agents).toEqual({ - 'ably-spaces': spaces.version, - 'space-custom-client': true, + spaces: spaces.version, }); }); @@ -53,8 +52,7 @@ describe('Spaces', () => { expect(ablyClient.options.agents).toEqual({ 'some-client': '1.2.3', - 'ably-spaces': spaces.version, - 'space-custom-client': true, + spaces: spaces.version, }); }); }); diff --git a/src/Spaces.ts b/src/Spaces.ts index be2b98f0..6117aff1 100644 --- a/src/Spaces.ts +++ b/src/Spaces.ts @@ -50,7 +50,7 @@ class Spaces { } private addAgent(options: { agents?: Record }) { - const agent = { 'ably-spaces': this.version, 'space-custom-client': true }; + const agent = { spaces: this.version }; options.agents = { ...(options.agents ?? options.agents), ...agent }; }