@honeybadger-io/js 6.6.0 → 6.7.0
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.
- package/dist/browser/honeybadger.js +347 -83
- package/dist/browser/honeybadger.js.map +1 -1
- package/dist/browser/honeybadger.min.js +1 -1
- package/dist/browser/honeybadger.min.js.map +1 -1
- package/dist/browser/integrations/events.d.ts +3 -0
- package/dist/server/{checkins-manager/checkin.d.ts → check-ins-manager/check-in.d.ts} +10 -10
- package/dist/server/check-ins-manager/client.d.ts +21 -0
- package/dist/server/check-ins-manager/index.d.ts +15 -0
- package/dist/server/{checkins-manager → check-ins-manager}/types.d.ts +8 -8
- package/dist/server/check-ins-sync-exec.d.ts +2 -0
- package/dist/server/{checkins-sync-exec.js → check-ins-sync-exec.js} +130 -129
- package/dist/server/check-ins-sync-exec.js.map +1 -0
- package/dist/server/check-ins-sync.d.ts +2 -0
- package/dist/server/honeybadger.d.ts +4 -4
- package/dist/server/honeybadger.js +320 -85
- package/dist/server/honeybadger.js.map +1 -1
- package/package.json +4 -4
- package/dist/server/checkins-manager/client.d.ts +0 -21
- package/dist/server/checkins-manager/index.d.ts +0 -15
- package/dist/server/checkins-sync-exec.d.ts +0 -2
- package/dist/server/checkins-sync-exec.js.map +0 -1
- package/dist/server/checkins-sync.d.ts +0 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare class
|
|
1
|
+
import { CheckInDto, CheckInPayload, CheckInResponsePayload } from './types/types';
|
|
2
|
+
export declare class CheckIn implements CheckInDto {
|
|
3
3
|
id?: string;
|
|
4
4
|
projectId: string;
|
|
5
5
|
name: string;
|
|
@@ -10,22 +10,22 @@ export declare class Checkin implements CheckinDto {
|
|
|
10
10
|
cronSchedule?: string;
|
|
11
11
|
cronTimezone?: string;
|
|
12
12
|
/**
|
|
13
|
-
* Only set when the
|
|
13
|
+
* Only set when the check-in has been deleted
|
|
14
14
|
* after an update request.
|
|
15
15
|
* Note: this property exists only locally.
|
|
16
16
|
*/
|
|
17
17
|
private deleted;
|
|
18
|
-
constructor(props:
|
|
18
|
+
constructor(props: CheckInDto);
|
|
19
19
|
isDeleted(): boolean;
|
|
20
20
|
markAsDeleted(): void;
|
|
21
21
|
validate(): void;
|
|
22
|
-
asRequestPayload():
|
|
22
|
+
asRequestPayload(): CheckInPayload;
|
|
23
23
|
/**
|
|
24
|
-
* Compares two
|
|
25
|
-
* If the one in the config file does not match the
|
|
24
|
+
* Compares two check-ins, usually the one from the API and the one from the config file.
|
|
25
|
+
* If the one in the config file does not match the check-in from the API,
|
|
26
26
|
* then we issue an update request.
|
|
27
27
|
*/
|
|
28
|
-
isInSync(other:
|
|
29
|
-
static fromResponsePayload(projectId: string, payload:
|
|
28
|
+
isInSync(other: CheckIn): boolean;
|
|
29
|
+
static fromResponsePayload(projectId: string, payload: CheckInResponsePayload): CheckIn;
|
|
30
30
|
}
|
|
31
|
-
//# sourceMappingURL=
|
|
31
|
+
//# sourceMappingURL=check-in.d.ts.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Types } from '@honeybadger-io/core';
|
|
2
|
+
import { CheckIn } from './types/check-in';
|
|
3
|
+
export declare class CheckInsClient {
|
|
4
|
+
private readonly BASE_URL;
|
|
5
|
+
private readonly cache;
|
|
6
|
+
private readonly config;
|
|
7
|
+
private readonly logger;
|
|
8
|
+
private readonly transport;
|
|
9
|
+
constructor(config: {
|
|
10
|
+
personalAuthToken: string;
|
|
11
|
+
logger: Types.Logger;
|
|
12
|
+
}, transport: Types.Transport);
|
|
13
|
+
listForProject(projectId: string): Promise<CheckIn[]>;
|
|
14
|
+
get(projectId: string, checkInId: string): Promise<CheckIn>;
|
|
15
|
+
create(checkIn: CheckIn): Promise<CheckIn>;
|
|
16
|
+
update(checkIn: CheckIn): Promise<CheckIn>;
|
|
17
|
+
remove(checkIn: CheckIn): Promise<void>;
|
|
18
|
+
private getHeaders;
|
|
19
|
+
private getErrorMessage;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=client.d.ts.map
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { Types } from '@honeybadger-io/core';
|
|
2
|
+
import { CheckInsClient } from './types/client';
|
|
3
|
+
import { CheckInsConfig } from './types/types';
|
|
4
|
+
import { CheckIn } from './types/check-in';
|
|
5
|
+
export declare class CheckInsManager {
|
|
6
|
+
private readonly client;
|
|
7
|
+
config: Required<CheckInsConfig>;
|
|
8
|
+
logger: Types.Logger;
|
|
9
|
+
constructor(config: Partial<CheckInsConfig>, client?: CheckInsClient);
|
|
10
|
+
sync(): Promise<CheckIn[]>;
|
|
11
|
+
private getLocalCheckIns;
|
|
12
|
+
private createOrUpdate;
|
|
13
|
+
private remove;
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Types } from '@honeybadger-io/core';
|
|
2
|
-
export declare type
|
|
2
|
+
export declare type CheckInDto = {
|
|
3
3
|
/**
|
|
4
4
|
* Checkin identifier.
|
|
5
5
|
*/
|
|
@@ -42,13 +42,13 @@ export declare type CheckinDto = {
|
|
|
42
42
|
*/
|
|
43
43
|
projectId: string;
|
|
44
44
|
};
|
|
45
|
-
export declare type
|
|
45
|
+
export declare type CheckInsConfig = {
|
|
46
46
|
debug?: boolean;
|
|
47
47
|
logger?: Types.Logger;
|
|
48
48
|
personalAuthToken: string;
|
|
49
|
-
checkins:
|
|
49
|
+
checkins: CheckInDto[];
|
|
50
50
|
};
|
|
51
|
-
export declare type
|
|
51
|
+
export declare type CheckInPayload = {
|
|
52
52
|
name: string;
|
|
53
53
|
slug?: string;
|
|
54
54
|
schedule_type: 'simple' | 'cron';
|
|
@@ -57,10 +57,10 @@ export declare type CheckinPayload = {
|
|
|
57
57
|
cron_schedule?: string;
|
|
58
58
|
cron_timezone?: string;
|
|
59
59
|
};
|
|
60
|
-
export declare type
|
|
61
|
-
check_in:
|
|
60
|
+
export declare type CheckInTransportPayload = {
|
|
61
|
+
check_in: CheckInPayload;
|
|
62
62
|
};
|
|
63
|
-
export declare type
|
|
63
|
+
export declare type CheckInResponsePayload = {
|
|
64
64
|
id: string;
|
|
65
|
-
} &
|
|
65
|
+
} & CheckInPayload;
|
|
66
66
|
//# sourceMappingURL=types.d.ts.map
|