@secrecy/lib 1.7.0-integration-trpc-client.13 → 1.7.0-integration-trpc-client.15
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.
|
@@ -42,6 +42,12 @@ export class SecrecyAppClient {
|
|
|
42
42
|
async limits() {
|
|
43
43
|
return await this.#apiClient.application.limits.query({});
|
|
44
44
|
}
|
|
45
|
+
async limitsComplete() {
|
|
46
|
+
return await this.#apiClient.application.limitsComplete.query({});
|
|
47
|
+
}
|
|
48
|
+
async limitsCons() {
|
|
49
|
+
return await this.#apiClient.application.limitsCons.query({});
|
|
50
|
+
}
|
|
45
51
|
async updateNotifications(notifications) {
|
|
46
52
|
const updateAppNotifications = await this.#apiClient.application.updateNotification.mutate({
|
|
47
53
|
cloud: notifications.cloud,
|
|
@@ -11,6 +11,8 @@ export declare class SecrecyAppClient<Schema extends DatabaseSchema = DatabaseSc
|
|
|
11
11
|
get userId(): string;
|
|
12
12
|
getJwt(): Promise<string>;
|
|
13
13
|
limits(): Promise<RouterOutputs['application']['limits']>;
|
|
14
|
+
limitsComplete(): Promise<RouterOutputs['application']['limitsComplete']>;
|
|
15
|
+
limitsCons(): Promise<RouterOutputs['application']['limitsCons']>;
|
|
14
16
|
updateNotifications(notifications: Partial<UserAppNotifications>): Promise<UserAppNotifications>;
|
|
15
17
|
notifications(): Promise<UserAppNotifications>;
|
|
16
18
|
userPublicKey(userId: string): Promise<string>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { SecrecyClient } from './index.js';
|
|
2
2
|
import { type SecrecyUserApp } from './types/index.js';
|
|
3
|
+
import { type DatabaseSchema } from './types/orm/core.js';
|
|
3
4
|
export declare function parseInfos(): SecrecyUserApp | null;
|
|
4
5
|
export declare const getUrl: ({ hash, path, }: {
|
|
5
6
|
hash: string;
|
|
@@ -18,8 +19,9 @@ export interface HashInfos {
|
|
|
18
19
|
export type UseSecrecyParams = Omit<HashInfos, 'appUrl'> & {
|
|
19
20
|
session?: boolean | undefined;
|
|
20
21
|
};
|
|
21
|
-
export
|
|
22
|
+
export declare function getSecrecyClient<Schema extends DatabaseSchema = DatabaseSchema>(session?: boolean | undefined): SecrecyClient<Schema> | null;
|
|
23
|
+
type LoginResponse<Params extends UseSecrecyParams, Schema extends DatabaseSchema> = Params extends {
|
|
22
24
|
redirect: true;
|
|
23
|
-
} ? SecrecyClient | null : SecrecyClient
|
|
24
|
-
export declare function
|
|
25
|
-
export
|
|
25
|
+
} ? SecrecyClient<Schema> | null : SecrecyClient<Schema>;
|
|
26
|
+
export declare function login<Params extends UseSecrecyParams, Schema extends DatabaseSchema = DatabaseSchema>({ appCode, path, redirect, scopes, backPath, session, }: Params): Promise<LoginResponse<Params, Schema>>;
|
|
27
|
+
export {};
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@secrecy/lib",
|
|
3
3
|
"author": "Anonymize <anonymize@gmail.com>",
|
|
4
4
|
"description": "Anonymize Secrecy Library",
|
|
5
|
-
"version": "1.7.0-integration-trpc-client.
|
|
5
|
+
"version": "1.7.0-integration-trpc-client.15",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
8
8
|
"url": "https://github.com/anonymize-org/lib.git"
|