@xyo-network/url-safety-plugin 2.73.4 → 2.74.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.
- package/dist/Plugin.d.mts +67 -0
- package/dist/Plugin.d.mts.map +1 -0
- package/dist/Plugin.d.ts +67 -0
- package/dist/Plugin.d.ts.map +1 -0
- package/dist/Witness/Config.d.mts +13 -0
- package/dist/Witness/Config.d.mts.map +1 -0
- package/dist/Witness/Config.d.ts +13 -0
- package/dist/Witness/Config.d.ts.map +1 -0
- package/dist/Witness/Params.d.mts +12 -0
- package/dist/Witness/Params.d.mts.map +1 -0
- package/dist/Witness/Params.d.ts +12 -0
- package/dist/Witness/Params.d.ts.map +1 -0
- package/dist/Witness/Witness.d.mts +24 -0
- package/dist/Witness/Witness.d.mts.map +1 -0
- package/dist/Witness/Witness.d.ts +24 -0
- package/dist/Witness/Witness.d.ts.map +1 -0
- package/dist/Witness/index.d.mts +4 -0
- package/dist/Witness/index.d.mts.map +1 -0
- package/dist/Witness/index.d.ts +4 -0
- package/dist/Witness/index.d.ts.map +1 -0
- package/dist/docs.json +19436 -20176
- package/dist/index.d.mts +5 -119
- package/dist/index.d.mts.map +1 -0
- package/dist/index.d.ts +5 -119
- package/dist/index.d.ts.map +1 -0
- package/package.json +10 -16
- package/tsup.config.ts +0 -16
package/dist/index.d.mts
CHANGED
|
@@ -1,119 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import * as _xyo_network_account_model from '@xyo-network/account-model';
|
|
7
|
-
import * as _xyo_network_core from '@xyo-network/core';
|
|
8
|
-
import { UrlPayload } from '@xyo-network/url-payload-plugin';
|
|
9
|
-
import { UrlSafetyPayload } from '@xyo-network/url-safety-payload-plugin';
|
|
10
|
-
import { WitnessConfig, WitnessParams, AbstractWitness } from '@xyo-network/witness';
|
|
11
|
-
import { AnyConfigSchema } from '@xyo-network/module';
|
|
12
|
-
|
|
13
|
-
declare const UrlSafetyWitnessConfigSchema: "network.xyo.url.safety.witness.config";
|
|
14
|
-
type UrlSafetyWitnessConfigSchema = typeof UrlSafetyWitnessConfigSchema;
|
|
15
|
-
type UrlSafetyWitnessConfig = WitnessConfig<{
|
|
16
|
-
google?: {
|
|
17
|
-
safeBrowsing?: {
|
|
18
|
-
endPoint?: string;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
21
|
-
schema: UrlSafetyWitnessConfigSchema;
|
|
22
|
-
urls?: string[];
|
|
23
|
-
}>;
|
|
24
|
-
|
|
25
|
-
type UrlSafetyWitnessParams = WitnessParams<AnyConfigSchema<UrlSafetyWitnessConfig>, {
|
|
26
|
-
google?: {
|
|
27
|
-
safeBrowsing?: {
|
|
28
|
-
endPoint?: string;
|
|
29
|
-
key?: string;
|
|
30
|
-
};
|
|
31
|
-
};
|
|
32
|
-
}>;
|
|
33
|
-
|
|
34
|
-
type GoogleSafeBrowsingMatchSchema = 'com.google.safebrowsing.match';
|
|
35
|
-
declare const GoogleSafeBrowsingMatchSchema: GoogleSafeBrowsingMatchSchema;
|
|
36
|
-
interface GoogleSafeBrowsingMatch {
|
|
37
|
-
cacheDuration: string;
|
|
38
|
-
platformType: string;
|
|
39
|
-
threat: {
|
|
40
|
-
url: string;
|
|
41
|
-
};
|
|
42
|
-
threatEntryType: string;
|
|
43
|
-
threatType: string;
|
|
44
|
-
}
|
|
45
|
-
type GoogleSafeBrowsingMatchPayload = Payload<GoogleSafeBrowsingMatch, GoogleSafeBrowsingMatchSchema>;
|
|
46
|
-
declare class UrlSafetyWitness<TParams extends UrlSafetyWitnessParams = UrlSafetyWitnessParams> extends AbstractWitness<TParams> {
|
|
47
|
-
static configSchemas: "network.xyo.url.safety.witness.config"[];
|
|
48
|
-
get key(): string | undefined;
|
|
49
|
-
get urls(): string[] | undefined;
|
|
50
|
-
protected observeHandler(payloads?: UrlPayload[]): Promise<UrlSafetyPayload[]>;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
declare const UrlSafetyPlugin: () => _xyo_network_payloadset_plugin.PayloadSetWitnessPlugin<UrlSafetyWitness<_xyo_network_core.BaseParamsFields & {
|
|
54
|
-
account?: _xyo_network_account_model.AccountInstance | "random" | undefined;
|
|
55
|
-
config: _xyo_network_payload_model.SchemaFields & _xyo_network_payload_model.PayloadFields & {
|
|
56
|
-
accountDerivationPath?: string | undefined;
|
|
57
|
-
readonly archivist?: _xyo_network_module_model.ArchivistModuleConfig | undefined;
|
|
58
|
-
readonly name?: string | undefined;
|
|
59
|
-
readonly paging?: Record<string, {
|
|
60
|
-
size?: number | undefined;
|
|
61
|
-
}> | undefined;
|
|
62
|
-
readonly schema: string;
|
|
63
|
-
readonly security?: {
|
|
64
|
-
readonly allowAnonymous?: boolean | undefined;
|
|
65
|
-
readonly allowed?: Record<string, (string | _xyo_network_module_model.CosigningAddressSet)[]> | undefined;
|
|
66
|
-
readonly disallowed?: Record<string, string[]> | undefined;
|
|
67
|
-
} | undefined;
|
|
68
|
-
readonly sign?: boolean | undefined;
|
|
69
|
-
readonly storeQueries?: boolean | undefined;
|
|
70
|
-
readonly timestamp?: boolean | undefined;
|
|
71
|
-
} & Omit<Omit<_xyo_network_payload_model.SchemaFields & _xyo_network_payload_model.PayloadFields & {
|
|
72
|
-
accountDerivationPath?: string | undefined;
|
|
73
|
-
readonly archivist?: _xyo_network_module_model.ArchivistModuleConfig | undefined;
|
|
74
|
-
readonly name?: string | undefined;
|
|
75
|
-
readonly paging?: Record<string, {
|
|
76
|
-
size?: number | undefined;
|
|
77
|
-
}> | undefined;
|
|
78
|
-
readonly schema: "network.xyo.url.safety.witness.config";
|
|
79
|
-
readonly security?: {
|
|
80
|
-
readonly allowAnonymous?: boolean | undefined;
|
|
81
|
-
readonly allowed?: Record<string, (string | _xyo_network_module_model.CosigningAddressSet)[]> | undefined;
|
|
82
|
-
readonly disallowed?: Record<string, string[]> | undefined;
|
|
83
|
-
} | undefined;
|
|
84
|
-
readonly sign?: boolean | undefined;
|
|
85
|
-
readonly storeQueries?: boolean | undefined;
|
|
86
|
-
readonly timestamp?: boolean | undefined;
|
|
87
|
-
} & Omit<{
|
|
88
|
-
archivist?: string | undefined;
|
|
89
|
-
schema: "network.xyo.url.safety.witness.config";
|
|
90
|
-
targetSet?: (_xyo_network_payload_model.SchemaFields & _xyo_network_payload_model.PayloadFields & _xyo_network_payload_model.PayloadSet & {
|
|
91
|
-
schema: "network.xyo.payload.set";
|
|
92
|
-
}) | undefined;
|
|
93
|
-
} & {
|
|
94
|
-
google?: {
|
|
95
|
-
safeBrowsing?: {
|
|
96
|
-
endPoint?: string | undefined;
|
|
97
|
-
} | undefined;
|
|
98
|
-
} | undefined;
|
|
99
|
-
schema: "network.xyo.url.safety.witness.config";
|
|
100
|
-
urls?: string[] | undefined;
|
|
101
|
-
}, "schema"> & {
|
|
102
|
-
schema: "network.xyo.url.safety.witness.config";
|
|
103
|
-
}, "schema"> & {
|
|
104
|
-
schema: string;
|
|
105
|
-
}, "schema"> & {
|
|
106
|
-
schema: string;
|
|
107
|
-
};
|
|
108
|
-
ephemeralQueryAccountEnabled?: boolean | undefined;
|
|
109
|
-
wallet?: _xyo_network_wallet_model.WalletInstance | undefined;
|
|
110
|
-
} & {
|
|
111
|
-
google?: {
|
|
112
|
-
safeBrowsing?: {
|
|
113
|
-
endPoint?: string | undefined;
|
|
114
|
-
key?: string | undefined;
|
|
115
|
-
} | undefined;
|
|
116
|
-
} | undefined;
|
|
117
|
-
}>>;
|
|
118
|
-
|
|
119
|
-
export { GoogleSafeBrowsingMatch, GoogleSafeBrowsingMatchPayload, GoogleSafeBrowsingMatchSchema, UrlSafetyPlugin, UrlSafetyWitness, UrlSafetyWitnessConfig, UrlSafetyWitnessConfigSchema, UrlSafetyWitnessParams, UrlSafetyPlugin as default };
|
|
1
|
+
import { UrlSafetyPlugin } from './Plugin';
|
|
2
|
+
export * from './Witness';
|
|
3
|
+
export { UrlSafetyPlugin };
|
|
4
|
+
export default UrlSafetyPlugin;
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAE1C,cAAc,WAAW,CAAA;AAEzB,OAAO,EAAE,eAAe,EAAE,CAAA;AAG1B,eAAe,eAAe,CAAA"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,119 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import * as _xyo_network_account_model from '@xyo-network/account-model';
|
|
7
|
-
import * as _xyo_network_core from '@xyo-network/core';
|
|
8
|
-
import { UrlPayload } from '@xyo-network/url-payload-plugin';
|
|
9
|
-
import { UrlSafetyPayload } from '@xyo-network/url-safety-payload-plugin';
|
|
10
|
-
import { WitnessConfig, WitnessParams, AbstractWitness } from '@xyo-network/witness';
|
|
11
|
-
import { AnyConfigSchema } from '@xyo-network/module';
|
|
12
|
-
|
|
13
|
-
declare const UrlSafetyWitnessConfigSchema: "network.xyo.url.safety.witness.config";
|
|
14
|
-
type UrlSafetyWitnessConfigSchema = typeof UrlSafetyWitnessConfigSchema;
|
|
15
|
-
type UrlSafetyWitnessConfig = WitnessConfig<{
|
|
16
|
-
google?: {
|
|
17
|
-
safeBrowsing?: {
|
|
18
|
-
endPoint?: string;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
21
|
-
schema: UrlSafetyWitnessConfigSchema;
|
|
22
|
-
urls?: string[];
|
|
23
|
-
}>;
|
|
24
|
-
|
|
25
|
-
type UrlSafetyWitnessParams = WitnessParams<AnyConfigSchema<UrlSafetyWitnessConfig>, {
|
|
26
|
-
google?: {
|
|
27
|
-
safeBrowsing?: {
|
|
28
|
-
endPoint?: string;
|
|
29
|
-
key?: string;
|
|
30
|
-
};
|
|
31
|
-
};
|
|
32
|
-
}>;
|
|
33
|
-
|
|
34
|
-
type GoogleSafeBrowsingMatchSchema = 'com.google.safebrowsing.match';
|
|
35
|
-
declare const GoogleSafeBrowsingMatchSchema: GoogleSafeBrowsingMatchSchema;
|
|
36
|
-
interface GoogleSafeBrowsingMatch {
|
|
37
|
-
cacheDuration: string;
|
|
38
|
-
platformType: string;
|
|
39
|
-
threat: {
|
|
40
|
-
url: string;
|
|
41
|
-
};
|
|
42
|
-
threatEntryType: string;
|
|
43
|
-
threatType: string;
|
|
44
|
-
}
|
|
45
|
-
type GoogleSafeBrowsingMatchPayload = Payload<GoogleSafeBrowsingMatch, GoogleSafeBrowsingMatchSchema>;
|
|
46
|
-
declare class UrlSafetyWitness<TParams extends UrlSafetyWitnessParams = UrlSafetyWitnessParams> extends AbstractWitness<TParams> {
|
|
47
|
-
static configSchemas: "network.xyo.url.safety.witness.config"[];
|
|
48
|
-
get key(): string | undefined;
|
|
49
|
-
get urls(): string[] | undefined;
|
|
50
|
-
protected observeHandler(payloads?: UrlPayload[]): Promise<UrlSafetyPayload[]>;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
declare const UrlSafetyPlugin: () => _xyo_network_payloadset_plugin.PayloadSetWitnessPlugin<UrlSafetyWitness<_xyo_network_core.BaseParamsFields & {
|
|
54
|
-
account?: _xyo_network_account_model.AccountInstance | "random" | undefined;
|
|
55
|
-
config: _xyo_network_payload_model.SchemaFields & _xyo_network_payload_model.PayloadFields & {
|
|
56
|
-
accountDerivationPath?: string | undefined;
|
|
57
|
-
readonly archivist?: _xyo_network_module_model.ArchivistModuleConfig | undefined;
|
|
58
|
-
readonly name?: string | undefined;
|
|
59
|
-
readonly paging?: Record<string, {
|
|
60
|
-
size?: number | undefined;
|
|
61
|
-
}> | undefined;
|
|
62
|
-
readonly schema: string;
|
|
63
|
-
readonly security?: {
|
|
64
|
-
readonly allowAnonymous?: boolean | undefined;
|
|
65
|
-
readonly allowed?: Record<string, (string | _xyo_network_module_model.CosigningAddressSet)[]> | undefined;
|
|
66
|
-
readonly disallowed?: Record<string, string[]> | undefined;
|
|
67
|
-
} | undefined;
|
|
68
|
-
readonly sign?: boolean | undefined;
|
|
69
|
-
readonly storeQueries?: boolean | undefined;
|
|
70
|
-
readonly timestamp?: boolean | undefined;
|
|
71
|
-
} & Omit<Omit<_xyo_network_payload_model.SchemaFields & _xyo_network_payload_model.PayloadFields & {
|
|
72
|
-
accountDerivationPath?: string | undefined;
|
|
73
|
-
readonly archivist?: _xyo_network_module_model.ArchivistModuleConfig | undefined;
|
|
74
|
-
readonly name?: string | undefined;
|
|
75
|
-
readonly paging?: Record<string, {
|
|
76
|
-
size?: number | undefined;
|
|
77
|
-
}> | undefined;
|
|
78
|
-
readonly schema: "network.xyo.url.safety.witness.config";
|
|
79
|
-
readonly security?: {
|
|
80
|
-
readonly allowAnonymous?: boolean | undefined;
|
|
81
|
-
readonly allowed?: Record<string, (string | _xyo_network_module_model.CosigningAddressSet)[]> | undefined;
|
|
82
|
-
readonly disallowed?: Record<string, string[]> | undefined;
|
|
83
|
-
} | undefined;
|
|
84
|
-
readonly sign?: boolean | undefined;
|
|
85
|
-
readonly storeQueries?: boolean | undefined;
|
|
86
|
-
readonly timestamp?: boolean | undefined;
|
|
87
|
-
} & Omit<{
|
|
88
|
-
archivist?: string | undefined;
|
|
89
|
-
schema: "network.xyo.url.safety.witness.config";
|
|
90
|
-
targetSet?: (_xyo_network_payload_model.SchemaFields & _xyo_network_payload_model.PayloadFields & _xyo_network_payload_model.PayloadSet & {
|
|
91
|
-
schema: "network.xyo.payload.set";
|
|
92
|
-
}) | undefined;
|
|
93
|
-
} & {
|
|
94
|
-
google?: {
|
|
95
|
-
safeBrowsing?: {
|
|
96
|
-
endPoint?: string | undefined;
|
|
97
|
-
} | undefined;
|
|
98
|
-
} | undefined;
|
|
99
|
-
schema: "network.xyo.url.safety.witness.config";
|
|
100
|
-
urls?: string[] | undefined;
|
|
101
|
-
}, "schema"> & {
|
|
102
|
-
schema: "network.xyo.url.safety.witness.config";
|
|
103
|
-
}, "schema"> & {
|
|
104
|
-
schema: string;
|
|
105
|
-
}, "schema"> & {
|
|
106
|
-
schema: string;
|
|
107
|
-
};
|
|
108
|
-
ephemeralQueryAccountEnabled?: boolean | undefined;
|
|
109
|
-
wallet?: _xyo_network_wallet_model.WalletInstance | undefined;
|
|
110
|
-
} & {
|
|
111
|
-
google?: {
|
|
112
|
-
safeBrowsing?: {
|
|
113
|
-
endPoint?: string | undefined;
|
|
114
|
-
key?: string | undefined;
|
|
115
|
-
} | undefined;
|
|
116
|
-
} | undefined;
|
|
117
|
-
}>>;
|
|
118
|
-
|
|
119
|
-
export { GoogleSafeBrowsingMatch, GoogleSafeBrowsingMatchPayload, GoogleSafeBrowsingMatchSchema, UrlSafetyPlugin, UrlSafetyWitness, UrlSafetyWitnessConfig, UrlSafetyWitnessConfigSchema, UrlSafetyWitnessParams, UrlSafetyPlugin as default };
|
|
1
|
+
import { UrlSafetyPlugin } from './Plugin';
|
|
2
|
+
export * from './Witness';
|
|
3
|
+
export { UrlSafetyPlugin };
|
|
4
|
+
export default UrlSafetyPlugin;
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAE1C,cAAc,WAAW,CAAA;AAEzB,OAAO,EAAE,eAAe,EAAE,CAAA;AAG1B,eAAe,eAAe,CAAA"}
|
package/package.json
CHANGED
|
@@ -10,25 +10,19 @@
|
|
|
10
10
|
"url": "https://github.com/XYOracleNetwork/sdk-xyo-client-js/issues"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@xyo-network/axios": "~2.
|
|
14
|
-
"@xyo-network/module": "~2.
|
|
15
|
-
"@xyo-network/payload-model": "~2.
|
|
16
|
-
"@xyo-network/payloadset-plugin": "~2.
|
|
17
|
-
"@xyo-network/url-payload-plugin": "~2.
|
|
18
|
-
"@xyo-network/url-safety-payload-plugin": "~2.
|
|
19
|
-
"@xyo-network/witness": "~2.
|
|
13
|
+
"@xyo-network/axios": "~2.74.1",
|
|
14
|
+
"@xyo-network/module": "~2.74.1",
|
|
15
|
+
"@xyo-network/payload-model": "~2.74.1",
|
|
16
|
+
"@xyo-network/payloadset-plugin": "~2.74.1",
|
|
17
|
+
"@xyo-network/url-payload-plugin": "~2.74.1",
|
|
18
|
+
"@xyo-network/url-safety-payload-plugin": "~2.74.1",
|
|
19
|
+
"@xyo-network/witness": "~2.74.1"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
|
-
"@xylabs/ts-scripts-yarn3": "^
|
|
23
|
-
"@xylabs/tsconfig": "^
|
|
24
|
-
"publint": "^0.2.2",
|
|
25
|
-
"tsup": "^7.2.0",
|
|
22
|
+
"@xylabs/ts-scripts-yarn3": "^3.0.28",
|
|
23
|
+
"@xylabs/tsconfig": "^3.0.28",
|
|
26
24
|
"typescript": "^5.2.2"
|
|
27
25
|
},
|
|
28
|
-
"scripts": {
|
|
29
|
-
"package-compile": "tsup && publint",
|
|
30
|
-
"package-recompile": "tsup && publint"
|
|
31
|
-
},
|
|
32
26
|
"description": "Primary SDK for using XYO Protocol 2.0",
|
|
33
27
|
"docs": "dist/docs.json",
|
|
34
28
|
"types": "dist/index.d.ts",
|
|
@@ -69,5 +63,5 @@
|
|
|
69
63
|
"url": "https://github.com/XYOracleNetwork/sdk-xyo-client-js.git"
|
|
70
64
|
},
|
|
71
65
|
"sideEffects": false,
|
|
72
|
-
"version": "2.
|
|
66
|
+
"version": "2.74.1"
|
|
73
67
|
}
|
package/tsup.config.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { defineConfig } from 'tsup'
|
|
2
|
-
|
|
3
|
-
// eslint-disable-next-line import/no-default-export
|
|
4
|
-
export default defineConfig({
|
|
5
|
-
bundle: true,
|
|
6
|
-
cjsInterop: true,
|
|
7
|
-
clean: false,
|
|
8
|
-
dts: {
|
|
9
|
-
entry: ['src/index.ts'],
|
|
10
|
-
},
|
|
11
|
-
entry: ['src/index.ts'],
|
|
12
|
-
format: ['cjs', 'esm'],
|
|
13
|
-
sourcemap: true,
|
|
14
|
-
splitting: false,
|
|
15
|
-
tsconfig: 'tsconfig.json',
|
|
16
|
-
})
|