ring-client-api 11.3.1 → 11.4.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +45 -51
  3. package/lib/{api/api.d.ts → api.d.ts} +0 -0
  4. package/lib/{api/api.js → api.js} +0 -0
  5. package/lib/{api/device-data.d.ts → device-data.d.ts} +0 -0
  6. package/lib/{api/device-data.js → device-data.js} +0 -0
  7. package/lib/{api/ffmpeg.d.ts → ffmpeg.d.ts} +0 -0
  8. package/lib/{api/ffmpeg.js → ffmpeg.js} +0 -0
  9. package/lib/{api/index.d.ts → index.d.ts} +0 -0
  10. package/lib/{api/index.js → index.js} +0 -0
  11. package/lib/{api/location.d.ts → location.d.ts} +0 -0
  12. package/lib/{api/location.js → location.js} +0 -0
  13. package/lib/{api/refresh-token.d.ts → refresh-token.d.ts} +0 -0
  14. package/lib/{api/refresh-token.js → refresh-token.js} +0 -0
  15. package/lib/{api/rest-client.d.ts → rest-client.d.ts} +0 -0
  16. package/lib/{api/rest-client.js → rest-client.js} +0 -0
  17. package/lib/ring-auth-cli.js +7 -1
  18. package/lib/{api/ring-camera.d.ts → ring-camera.d.ts} +0 -0
  19. package/lib/{api/ring-camera.js → ring-camera.js} +0 -0
  20. package/lib/{api/ring-chime.d.ts → ring-chime.d.ts} +0 -0
  21. package/lib/{api/ring-chime.js → ring-chime.js} +0 -0
  22. package/lib/ring-device-data-cli.js +7 -1
  23. package/lib/{api/ring-device.d.ts → ring-device.d.ts} +0 -0
  24. package/lib/{api/ring-device.js → ring-device.js} +0 -0
  25. package/lib/{api/ring-types.d.ts → ring-types.d.ts} +0 -0
  26. package/lib/{api/ring-types.js → ring-types.js} +0 -0
  27. package/lib/{api/streaming → streaming}/peer-connection.d.ts +0 -0
  28. package/lib/{api/streaming → streaming}/peer-connection.js +0 -0
  29. package/lib/{api/streaming → streaming}/ring-edge-connection.d.ts +0 -0
  30. package/lib/{api/streaming → streaming}/ring-edge-connection.js +0 -0
  31. package/lib/{api/streaming → streaming}/simple-webrtc-session.d.ts +0 -0
  32. package/lib/{api/streaming → streaming}/simple-webrtc-session.js +0 -0
  33. package/lib/{api/streaming → streaming}/streaming-connection-base.d.ts +0 -0
  34. package/lib/{api/streaming → streaming}/streaming-connection-base.js +0 -0
  35. package/lib/{api/streaming → streaming}/streaming-session.d.ts +0 -0
  36. package/lib/{api/streaming → streaming}/streaming-session.js +0 -0
  37. package/lib/{api/streaming → streaming}/webrtc-connection.d.ts +0 -0
  38. package/lib/{api/streaming → streaming}/webrtc-connection.js +0 -0
  39. package/lib/{api/subscribed.d.ts → subscribed.d.ts} +0 -0
  40. package/lib/{api/subscribed.js → subscribed.js} +0 -0
  41. package/lib/test/{api/ring-camera.spec.d.ts → ring-camera.spec.d.ts} +0 -0
  42. package/lib/test/ring-camera.spec.js +25 -0
  43. package/lib/{api/util.d.ts → util.d.ts} +0 -0
  44. package/lib/{api/util.js → util.js} +0 -0
  45. package/package.json +47 -80
  46. package/CHANGELOG.md +0 -1574
  47. package/lib/build/github-releaser.d.ts +0 -1
  48. package/lib/build/github-releaser.js +0 -19
  49. package/lib/build/package-homebridge.d.ts +0 -1
  50. package/lib/build/package-homebridge.js +0 -6
  51. package/lib/jest.config.d.ts +0 -3
  52. package/lib/jest.config.js +0 -6
  53. package/lib/test/api/ring-camera.spec.js +0 -25
  54. package/media/camera-offline.jpg +0 -0
  55. package/media/snapshots-blocked.jpg +0 -0
  56. package/ring-auth-cli.js +0 -2
  57. package/ring-device-data-cli.js +0 -2
@@ -1 +0,0 @@
1
- export {};
@@ -1,19 +0,0 @@
1
- "use strict";
2
- require('dotenv/config');
3
- const conventionalGithubReleaser = require('conventional-github-releaser');
4
- conventionalGithubReleaser({
5
- type: 'oauth',
6
- url: 'https://api.github.com/',
7
- token: process.env.GITHUB_TOKEN,
8
- }, {
9
- preset: 'angular',
10
- }, (e, release) => {
11
- if (e) {
12
- // eslint-disable-next-line no-console
13
- console.error(e);
14
- process.exit(1);
15
- }
16
- // eslint-disable-next-line no-console
17
- console.log(release);
18
- process.exit(0);
19
- });
@@ -1 +0,0 @@
1
- export {};
@@ -1,6 +0,0 @@
1
- "use strict";
2
- const fs = require('fs');
3
- const main = JSON.parse(fs.readFileSync('package.json'));
4
- const homebridge = JSON.parse(fs.readFileSync('homebridge/package.json'));
5
- const output = JSON.stringify(Object.assign(main, homebridge), null, 2);
6
- fs.writeFileSync('release-homebridge/package.json', output);
@@ -1,3 +0,0 @@
1
- export const preset: string;
2
- export const testEnvironment: string;
3
- export const testMatch: string[];
@@ -1,6 +0,0 @@
1
- "use strict";
2
- module.exports = {
3
- preset: 'ts-jest',
4
- testEnvironment: 'node',
5
- testMatch: ['**/test/**/*.spec.ts'],
6
- };
@@ -1,25 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const api_1 = require("../../api");
4
- describe('Ring Camera', () => {
5
- describe('battery level', () => {
6
- it('should handle string battery life', () => {
7
- expect((0, api_1.getBatteryLevel)({
8
- battery_life: '49',
9
- })).toEqual(49);
10
- });
11
- it('should handle null battery life', () => {
12
- expect((0, api_1.getBatteryLevel)({ battery_life: null })).toEqual(null);
13
- });
14
- it('should handle right battery only', () => {
15
- expect((0, api_1.getBatteryLevel)({ battery_life: null, battery_life_2: 24 })).toEqual(24);
16
- });
17
- it('should handle left battery only', () => {
18
- expect((0, api_1.getBatteryLevel)({ battery_life: 76, battery_life_2: null })).toEqual(76);
19
- });
20
- it('should handle dual batteries', () => {
21
- expect((0, api_1.getBatteryLevel)({ battery_life: '92', battery_life_2: 84 })).toEqual(84);
22
- expect((0, api_1.getBatteryLevel)({ battery_life: '92', battery_life_2: 100 })).toEqual(92);
23
- });
24
- });
25
- });
Binary file
Binary file
package/ring-auth-cli.js DELETED
@@ -1,2 +0,0 @@
1
- #!/usr/bin/env node
2
- require('./lib/api/refresh-token').logRefreshToken()
@@ -1,2 +0,0 @@
1
- #!/usr/bin/env node
2
- require('./lib/api/device-data').logDeviceData()