datasquirel/index.d.ts

74 lines
2.8 KiB
TypeScript
Raw Normal View History

2024-12-12 06:08:28 +00:00
import get = require("./utils/get");
import post = require("./utils/post");
export namespace media {
export { uploadImage };
export { uploadFile };
export { deleteFile };
}
export namespace user {
export { createUser };
export let deleteUser: typeof import("./users/delete-user");
export { loginUser };
export { sendEmailCode };
export { logoutUser };
export { userAuth };
export { reAuthUser };
export { updateUser };
export { getUser };
export { getToken };
export { validateToken };
export let validateTempEmailCode: typeof import("./users/validate-temp-email-code");
export namespace social {
export { loginWithGoogle };
export { loginWithGithub };
}
}
import getSchema = require("./utils/get-schema");
import datasquirelClient = require("./client");
export namespace sql {
export { sqlGenerator };
export { sqlInsertGenerator };
export { sqlDeleteGenerator };
export { trimSql as trim };
}
2024-12-13 13:01:55 +00:00
import parseCookies = require("./package-shared/utils/backend/parseCookies");
2024-12-12 06:08:28 +00:00
import uploadImage = require("./utils/upload-image");
import uploadFile = require("./utils/upload-file");
import deleteFile = require("./utils/delete-file");
import createUser = require("./users/add-user");
import loginUser = require("./users/login-user");
import sendEmailCode = require("./users/send-email-code");
import logoutUser = require("./users/logout-user");
import userAuth = require("./users/user-auth");
import reAuthUser = require("./users/reauth-user");
import updateUser = require("./users/update-user");
import getUser = require("./users/get-user");
import getToken = require("./users/get-token");
import validateToken = require("./users/validate-token");
import loginWithGoogle = require("./users/social/google-auth");
import loginWithGithub = require("./users/social/github-auth");
import sqlGenerator = require("./package-shared/functions/dsql/sql/sql-generator");
import sqlInsertGenerator = require("./package-shared/functions/dsql/sql/sql-insert-generator");
import sqlDeleteGenerator = require("./package-shared/functions/dsql/sql/sql-delete-generator");
import trimSql = require("./package-shared/utils/trim-sql");
export declare namespace utils {
2024-12-13 13:01:55 +00:00
export namespace crypto {
2024-12-12 06:08:28 +00:00
let encrypt: ({ data, encryptionKey, encryptionSalt }: {
data: string;
encryptionKey?: string;
encryptionSalt?: string;
}) => string | null;
let decrypt: ({ encryptedString, encryptionKey, encryptionSalt }: {
encryptedString: string;
encryptionKey?: string;
encryptionSalt?: string;
}) => string;
let hash: ({ password, encryptionKey }: {
password: string;
encryptionKey?: string;
}) => string;
}
2024-12-13 13:01:55 +00:00
export { parseCookies };
2024-12-12 06:08:28 +00:00
}
export { get, post, getSchema, datasquirelClient as client };