@api-buddy/types
Version:
Shared types for API Buddy
810 lines (803 loc) • 27 kB
JavaScript
import { z } from 'zod';
export { z } from 'zod';
import { EventEmitter } from 'events';
import { v4 } from 'uuid';
var __create = Object.create;
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __knownSymbol = (name, symbol) => (symbol = Symbol[name]) ? symbol : Symbol.for("Symbol." + name);
var __typeError = (msg) => {
throw TypeError(msg);
};
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
var __decoratorStart = (base) => [, , , __create(null)];
var __decoratorStrings = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"];
var __expectFn = (fn) => fn !== void 0 && typeof fn !== "function" ? __typeError("Function expected") : fn;
var __decoratorContext = (kind, name, done, metadata, fns) => ({ kind: __decoratorStrings[kind], name, metadata, addInitializer: (fn) => done._ ? __typeError("Already initialized") : fns.push(__expectFn(fn || null)) });
var __decoratorMetadata = (array, target) => __defNormalProp(target, __knownSymbol("metadata"), array[3]);
var __runInitializers = (array, flags, self, value) => {
for (var i = 0, fns = array[flags >> 1], n = fns && fns.length; i < n; i++) fns[i].call(self) ;
return value;
};
var __decorateElement = (array, flags, name, decorators, target, extra) => {
var it, done, ctx, k = flags & 7, p = false;
var j = 0;
var extraInitializers = array[j] || (array[j] = []);
var desc = k && ((target = target.prototype), k < 5 && (k > 3 || !p) && __getOwnPropDesc(target , name));
__name(target, name);
for (var i = decorators.length - 1; i >= 0; i--) {
ctx = __decoratorContext(k, name, done = {}, array[3], extraInitializers);
it = (0, decorators[i])(target, ctx), done._ = 1;
__expectFn(it) && (target = it);
}
return __decoratorMetadata(array, target), desc && __defProp(target, name, desc), p ? k ^ 4 ? extra : desc : target;
};
var fieldTypeSchema = z.enum([
"String",
"Number",
"Boolean",
"Date",
"JSON",
"ID",
"Relation"
]);
var userProfileSchema = z.object({
id: z.string(),
email: z.string().email().optional(),
emailVerified: z.boolean().optional(),
name: z.string().optional(),
avatar: z.string().url().optional()
// Allow additional properties
}).passthrough();
var authSessionSchema = z.object({
user: userProfileSchema,
accessToken: z.string(),
refreshToken: z.string().optional(),
expiresAt: z.date().or(z.string().datetime()).optional()
});
var emailPasswordCredentialsSchema = z.object({
email: z.string().email(),
password: z.string().min(6)
});
var socialProviderConfigSchema = z.object({
clientId: z.string().min(1, "Client ID is required"),
clientSecret: z.string().optional(),
scopes: z.array(z.string()).default([]),
redirectUri: z.string().url("Invalid redirect URI").optional(),
params: z.record(z.string()).optional()
});
function isUserProfile(value) {
try {
userProfileSchema.parse(value);
return true;
} catch {
return false;
}
}
function isAuthSession(value) {
try {
authSessionSchema.parse(value);
return true;
} catch {
return false;
}
}
function isEmailPasswordCredentials(value) {
try {
emailPasswordCredentialsSchema.parse(value);
return true;
} catch {
return false;
}
}
var operatorSchema = z.union([
z.literal("=="),
z.literal("!="),
z.literal("<"),
z.literal("<="),
z.literal(">"),
z.literal(">="),
z.literal("in"),
z.literal("not-in"),
z.literal("array-contains"),
z.literal("array-contains-any")
]);
var queryFilterSchema = z.object({
field: z.string().min(1, "Field name is required"),
operator: operatorSchema,
value: z.any()
});
var databaseQueryOptionsSchema = z.object({
where: z.array(queryFilterSchema).optional(),
orderBy: z.tuple([z.string(), z.enum(["asc", "desc"])]).optional(),
limit: z.number().int().positive().optional(),
startAfter: z.any().optional(),
endBefore: z.any().optional(),
select: z.array(z.any()).optional(),
offset: z.number().int().nonnegative().optional()
}).strict();
var transactionOptionsSchema = z.object({
maxAttempts: z.number().int().positive().optional(),
readOnly: z.boolean().optional(),
timeout: z.number().int().positive().optional()
}).strict();
var fileMetadataSchema = z.object({
/** Name of the file */
name: z.string().min(1, "File name is required"),
/** Size of the file in bytes */
size: z.number().int().nonnegative("File size must be a non-negative number"),
/** MIME type of the file */
type: z.string().min(1, "File type is required"),
/** Last modified timestamp */
lastModified: z.number().int().positive().optional(),
/** Custom metadata key-value pairs */
customMetadata: z.record(z.string()).optional()
}).strict();
var storedFileSchema = fileMetadataSchema.extend({
path: z.string().min(1, "File path is required"),
url: z.string().url("Invalid URL"),
createdAt: z.date(),
updatedAt: z.date()
}).strict();
var uploadOptionsSchema = z.object({
public: z.boolean().default(false),
metadata: fileMetadataSchema.omit({ name: true, size: true, type: true }).optional(),
contentType: z.string().optional(),
cacheControl: z.string().optional(),
contentEncoding: z.string().optional(),
contentDisposition: z.string().optional()
}).strict();
var downloadOptionsSchema = z.object({
temporary: z.boolean().default(false),
expiresIn: z.number().int().positive().optional(),
responseContentType: z.string().optional(),
responseContentDisposition: z.string().optional()
}).strict();
var listOptionsSchema = z.object({
maxResults: z.number().int().positive().optional(),
pageToken: z.string().optional(),
includeMetadata: z.boolean().default(false)
}).strict();
var listResultSchema = z.object({
items: z.array(z.union([z.string(), storedFileSchema])),
nextPageToken: z.string().optional(),
hasMore: z.boolean()
}).strict();
// src/adapters/base.ts
var AdapterEventType = /* @__PURE__ */ ((AdapterEventType2) => {
AdapterEventType2["INITIALIZED"] = "initialized";
AdapterEventType2["DESTROYED"] = "destroyed";
AdapterEventType2["ERROR"] = "error";
AdapterEventType2["CONFIG_UPDATED"] = "config_updated";
AdapterEventType2["STATE_CHANGED"] = "state_changed";
AdapterEventType2["DATA_CHANGED"] = "data_changed";
AdapterEventType2["AUTH_STATE_CHANGED"] = "auth_state_changed";
AdapterEventType2["ID_TOKEN_CHANGED"] = "id_token_changed";
return AdapterEventType2;
})(AdapterEventType || {});
// src/adapters/types.ts
var AdapterType = /* @__PURE__ */ ((AdapterType3) => {
AdapterType3["AUTH"] = "auth";
AdapterType3["DATABASE"] = "database";
AdapterType3["STORAGE"] = "storage";
AdapterType3["PAYMENT"] = "payment";
return AdapterType3;
})(AdapterType || {});
var BaseAuthAdapter = class {
constructor(options) {
//@ts-ignore
this.type = "auth";
this.state = { user: null, isInitialized: false };
this.providers = {};
this.listeners = /* @__PURE__ */ new Map();
this.wrappedListeners = /* @__PURE__ */ new WeakMap();
/**
* Internal initialization state
*/
this._isInitialized = false;
/**
* The current user, if any
*/
this.currentUser = null;
/**
* The current authentication session, if any
*/
this.currentSession = null;
var _a;
this.id = options.id || `auth-${v4()}`;
this.eventEmitter = new EventEmitter();
this.eventEmitter.setMaxListeners(100);
const customEmitter = this.eventEmitter;
const originalEmit = this.eventEmitter.emit.bind(this.eventEmitter);
const originalOn = this.eventEmitter.on.bind(this.eventEmitter);
const originalOff = ((_a = this.eventEmitter.off) == null ? void 0 : _a.bind(this.eventEmitter)) || ((event, listener) => {
this.eventEmitter.removeListener(event, listener);
return this;
});
customEmitter.emit = (event, ...args) => {
if (typeof event === "string" && Object.values(AdapterEventType).includes(event)) {
const eventType = event;
const listeners = this.listeners.get(eventType);
if (listeners) {
const eventPayload = args[0] || {};
const eventData = {
...eventPayload,
adapter: this,
type: eventType,
timestamp: /* @__PURE__ */ new Date()
};
for (const listener of listeners) {
try {
listener(eventData);
} catch (error) {
console.error(`Error in ${event} listener:`, error);
}
}
}
}
return originalEmit(event, ...args);
};
customEmitter.on = (event, listener) => {
var _a2;
if (typeof event === "string" && Object.values(AdapterEventType).includes(event)) {
const eventType = event;
if (!this.listeners.has(eventType)) {
this.listeners.set(eventType, /* @__PURE__ */ new Set());
}
const wrappedListener = (e) => {
const eventWithTimestamp = {
...e,
adapter: this,
type: eventType,
timestamp: /* @__PURE__ */ new Date()
};
listener(eventWithTimestamp);
};
(_a2 = this.listeners.get(eventType)) == null ? void 0 : _a2.add(wrappedListener);
this.wrappedListeners.set(listener, wrappedListener);
return originalOn(event, wrappedListener);
}
return originalOn(event, listener);
};
customEmitter.off = (event, listener) => {
var _a2;
if (typeof event === "string" && Object.values(AdapterEventType).includes(event)) {
const eventType = event;
const wrappedListener = this.wrappedListeners.get(listener);
if (wrappedListener) {
(_a2 = this.listeners.get(eventType)) == null ? void 0 : _a2.delete(wrappedListener);
this.wrappedListeners.delete(listener);
return originalOff(event, wrappedListener);
}
}
return originalOff(event, listener);
};
}
/**
* Whether the adapter has been initialized
*/
isInitialized() {
return this.state.isInitialized;
}
// ==========================================
// Event Emitter Implementation
// ==========================================
// Implement on/off methods to satisfy AuthAdapter interface
// These methods use the custom event emitter we set up in the constructor
on(event, listener) {
var _a;
if (typeof event === "string" && Object.values(AdapterEventType).includes(event)) {
const eventType = event;
if (!this.listeners.has(eventType)) {
this.listeners.set(eventType, /* @__PURE__ */ new Set());
}
const wrappedListener = (e) => {
const eventWithTimestamp = {
...e,
adapter: this,
type: eventType,
timestamp: Date.now()
};
listener(eventWithTimestamp);
};
(_a = this.listeners.get(eventType)) == null ? void 0 : _a.add(wrappedListener);
this.wrappedListeners.set(listener, wrappedListener);
this.eventEmitter.on(eventType, wrappedListener);
} else {
this.eventEmitter.on(event, listener);
}
}
off(event, listener) {
var _a;
if (typeof event === "string" && Object.values(AdapterEventType).includes(event)) {
const eventType = event;
const wrappedListener = this.wrappedListeners.get(listener);
if (wrappedListener) {
(_a = this.listeners.get(eventType)) == null ? void 0 : _a.delete(wrappedListener);
this.wrappedListeners.delete(listener);
this.eventEmitter.off(eventType, wrappedListener);
}
} else {
this.eventEmitter.off(event, listener);
}
}
emit(event) {
const eventType = event.type;
const eventPayload = {
...event,
adapter: this,
timestamp: event.timestamp || /* @__PURE__ */ new Date()
};
if (this.listeners.has(eventType)) {
const listeners = this.listeners.get(eventType);
for (const listener of listeners) {
try {
listener(eventPayload);
} catch (error) {
console.error(`Error in ${eventType} listener:`, error);
}
}
}
const eventName = eventType;
return this.eventEmitter.emit(eventName, eventPayload);
}
/**
* Helper method to emit events with proper typing
*/
emitEvent(type, data, error) {
const event = {
type,
adapter: this,
data,
timestamp: /* @__PURE__ */ new Date(),
error
};
const eventName = type;
this.eventEmitter.emit(eventName, event);
if (this.listeners.has(type)) {
const listeners = this.listeners.get(type);
for (const listener of listeners) {
try {
listener(event);
} catch (err) {
console.error(`Error in ${type} listener:`, err);
}
}
}
}
removeAllListeners(event) {
var _a;
if (event) {
(_a = this.listeners.get(event)) == null ? void 0 : _a.clear();
this.eventEmitter.removeAllListeners(event);
} else {
this.listeners.clear();
this.eventEmitter.removeAllListeners();
}
return this;
}
getProviderId() {
return Promise.resolve(this.id);
}
getTenantId() {
return Promise.resolve(null);
}
// Additional AuthAdapter methods with default implementations
async deleteAccount() {
throw new Error("deleteAccount not implemented");
}
async refreshToken(_forceRefresh = false) {
throw new Error("refreshToken not implemented");
}
async getIdToken(_forceRefresh = false) {
throw new Error("getIdToken not implemented");
}
async getIdTokenResult(_forceRefresh = false) {
throw new Error("getIdTokenResult not implemented");
}
async getRefreshToken() {
throw new Error("getRefreshToken not implemented");
}
onAuthStateChanged(_callback) {
throw new Error("onAuthStateChanged not implemented");
}
onIdTokenChanged(_callback) {
throw new Error("onIdTokenChanged not implemented");
}
async getCurrentUser() {
throw new Error("getCurrentUser not implemented");
}
async isEmailVerified() {
throw new Error("isEmailVerified not implemented");
}
async isAnonymous() {
throw new Error("isAnonymous not implemented");
}
async linkWithCredential(_credential) {
throw new Error("linkWithCredential not implemented");
}
async unlink(_providerId) {
throw new Error("unlink not implemented");
}
async reauthenticate(_credential) {
throw new Error("reauthenticate not implemented");
}
/**
* Helper method to emit auth state change events
*/
// Helper method to emit auth state change events
emitAuthStateChanged(user) {
this.emitEvent("auth_state_changed" /* AUTH_STATE_CHANGED */, { user });
}
emitTokenRefreshed(token) {
this.emitEvent("id_token_changed" /* ID_TOKEN_CHANGED */, { token });
}
/**
* Ensure the adapter is initialized
* @throws {Error} If the adapter is not initialized
*/
ensureInitialized() {
if (!this._isInitialized) {
throw new Error(`Auth adapter ${this.id} is not initialized`);
}
}
};
// src/adapters/core/registry.ts
function hasEventEmitterMethods(obj) {
return obj && typeof obj.on === "function" && typeof obj.off === "function" && typeof obj.emit === "function";
}
var RegistryEventTypes = {
// Adapter registration events
REGISTERED: "registered",
UNREGISTERED: "unregistered",
CLEARED: "cleared",
// Adapter instance events
CREATED: "created",
INITIALIZING: "initializing",
// Error event (redefined here to avoid circular dependency)
ERROR: "error"
};
function singleton(target, _context) {
let instance = null;
return class extends target {
constructor(...args) {
if (!instance) {
super(...args);
instance = this;
}
return instance;
}
};
}
var _AdapterRegistry_decorators, _init;
_AdapterRegistry_decorators = [singleton];
var AdapterRegistry = class {
constructor(options = {}) {
this.registry = /* @__PURE__ */ new Map();
this.instances = /* @__PURE__ */ new Map();
this.options = void 0;
this.eventListeners = /* @__PURE__ */ new Map();
this.options = {
autoInit: true,
throwOnError: true,
logger: console,
...options
};
}
/**
* Generate a unique key for an adapter registration or instance
*/
getRegistrationKey(id, type) {
return `${type}:${id}`;
}
/**
* Remove an event listener
*/
off(event, listener) {
var _a;
(_a = this.eventListeners.get(event)) == null ? void 0 : _a.delete(listener);
}
/**
* Emit an event to all listeners
*/
emit(event) {
const listeners = this.eventListeners.get(event.type);
if (listeners) {
for (const listener of listeners) {
try {
listener(event);
} catch (error) {
this.options.logger.error(`Error in ${event.type} event listener:`, error);
}
}
}
}
/**
* Emit an error event
*/
emitError(type, error, data = {}) {
const event = {
type: RegistryEventTypes.ERROR,
timestamp: Date.now(),
error,
data: { ...data, originalEventType: type },
adapter: null
};
this.emit(event);
if (this.options.throwOnError) {
throw error;
}
}
/**
* Register a new adapter factory
*/
register(registration) {
const key = this.getRegistrationKey(registration.id, registration.type);
if (this.registry.has(key)) {
const error = new Error(`Adapter with id '${registration.id}' and type '${registration.type}' is already registered`);
this.emitError(RegistryEventTypes.REGISTERED, error, { id: registration.id, type: registration.type });
throw error;
}
this.registry.set(key, registration);
const event = {
type: RegistryEventTypes.REGISTERED,
timestamp: Date.now(),
data: { id: registration.id, type: registration.type }
};
this.emit(event);
}
/**
* Create and initialize an adapter instance
*/
async createAdapter(id, type, config = {}, options) {
const key = this.getRegistrationKey(id, type);
const registration = this.registry.get(key);
if (!registration) {
const error = new Error(`No adapter registered for type: ${type} and id: ${id}`);
this.emitError(RegistryEventTypes.ERROR, error, { id, type });
throw error;
}
try {
const adapterOptions = {
...this.options,
...options || {}
};
const adapter = await registration.factory.create({
id,
type,
config,
options: adapterOptions
});
if (registration.singleton !== false) {
this.instances.set(`${type}:${id}`, adapter);
}
const eventEmitter = adapter;
if (hasEventEmitterMethods(eventEmitter)) {
Object.values(AdapterEventType).forEach((eventType) => {
eventEmitter.on(eventType, (event2) => {
this.emit({
...event2,
timestamp: Date.now(),
type: eventType,
adapter
});
});
});
}
const event = {
type: RegistryEventTypes.CREATED,
timestamp: Date.now(),
data: { id, type },
adapter
};
this.emit(event);
return adapter;
} catch (error) {
this.emitError(RegistryEventTypes.ERROR, error, { id, type });
throw error;
}
}
/**
* Get or create an adapter instance
*/
async getAdapter(id, type, config, options) {
const key = this.getRegistrationKey(id, type);
if (this.instances.has(key)) {
return this.instances.get(key);
}
return this.createAdapter(id, type, config, options);
}
/**
* Get all registered adapters of a specific type
*/
getRegisteredAdapters(type) {
const registrations = Array.from(this.registry.values());
return type ? registrations.filter((reg) => reg.type === type) : registrations;
}
/**
* Initialize an adapter with the given config
*/
async initializeAdapter(adapter, config) {
try {
const initializingEvent = {
type: RegistryEventTypes.INITIALIZING,
timestamp: Date.now(),
data: { id: adapter.id, type: adapter.type },
adapter
};
this.emit(initializingEvent);
await adapter.init(config);
} catch (error) {
this.emitError(RegistryEventTypes.ERROR, error, {
id: adapter.id,
type: adapter.type,
phase: "initialization"
});
throw error;
}
}
/**
* Remove an adapter registration and clean up its instance
*/
async unregister(id, type) {
const key = this.getRegistrationKey(id, type);
const registration = this.registry.get(key);
if (!registration) {
return false;
}
if (this.instances.has(key)) {
const instance = this.instances.get(key);
try {
await instance.destroy();
} catch (error) {
this.emitError(RegistryEventTypes.ERROR, error, { id, type, phase: "destruction" });
}
this.instances.delete(key);
}
this.registry.delete(key);
const event = {
type: RegistryEventTypes.UNREGISTERED,
timestamp: Date.now(),
data: { id, type }
};
this.emit(event);
return true;
}
/**
* Clear all adapter registrations and instances
*/
async clear() {
await Promise.all(
Array.from(this.instances.keys()).map(async (key) => {
const [id, type] = key.split("::");
await this.unregister(id, type);
})
);
this.registry.clear();
const event = {
type: RegistryEventTypes.CLEARED,
timestamp: Date.now(),
data: {}
};
this.emit(event);
}
/**
* Event handling
*/
on(event, listener) {
if (!this.eventListeners.has(event)) {
this.eventListeners.set(event, /* @__PURE__ */ new Set());
}
this.eventListeners.get(event).add(listener);
}
// Removed duplicate implementations of emitError and getRegistrationKey
};
_init = __decoratorStart();
AdapterRegistry = __decorateElement(_init, 0, "AdapterRegistry", _AdapterRegistry_decorators, AdapterRegistry);
__runInitializers(_init, 1, AdapterRegistry);
var adapterRegistry = new AdapterRegistry();
var baseAdapterConfigSchema = z.object({
id: z.string().min(1, "Adapter ID is required"),
type: z.nativeEnum(AdapterType, {
required_error: "Adapter type is required",
invalid_type_error: "Invalid adapter type"
}),
enabled: z.boolean().default(true),
debug: z.boolean().default(false)
});
var authConfigSchema = baseAdapterConfigSchema.extend({
type: z.literal("auth" /* AUTH */),
secret: z.string().min(32, "Secret must be at least 32 characters"),
session: z.object({
maxAge: z.number().int().positive().default(30 * 24 * 60 * 60),
// 30 days
updateAge: z.number().int().positive().default(24 * 60 * 60)
// 24 hours
}).optional()
});
var databaseConfigSchema = baseAdapterConfigSchema.extend({
type: z.literal("database" /* DATABASE */),
url: z.string().url("Invalid database URL"),
ssl: z.boolean().default(false),
pool: z.object({
min: z.number().int().nonnegative().default(2),
max: z.number().int().positive().default(10)
}).optional()
});
var storageConfigSchema = baseAdapterConfigSchema.extend({
type: z.literal("storage" /* STORAGE */),
bucket: z.string().min(1, "Bucket name is required"),
region: z.string().optional(),
endpoint: z.string().url().optional()
});
var adapterConfigSchema = z.discriminatedUnion("type", [
authConfigSchema,
databaseConfigSchema,
storageConfigSchema
]);
function isAuthConfig(config) {
return authConfigSchema.safeParse(config).success;
}
function isDatabaseConfig(config) {
return databaseConfigSchema.safeParse(config).success;
}
function isStorageConfig(config) {
return storageConfigSchema.safeParse(config).success;
}
function validateConfig(schema, config) {
return schema.parse(config);
}
// src/guards.ts
function isAuthAdapter(adapter) {
return typeof adapter === "object" && adapter !== null && "type" in adapter && adapter.type === "auth" /* AUTH */ && typeof adapter.signIn === "function" && typeof adapter.signOut === "function";
}
function isDatabaseAdapter(adapter) {
return typeof adapter === "object" && adapter !== null && "type" in adapter && adapter.type === "database" /* DATABASE */ && typeof adapter.find === "function" && typeof adapter.transaction === "function";
}
function isStorageAdapter(adapter) {
return typeof adapter === "object" && adapter !== null && "type" in adapter && adapter.type === "storage" /* STORAGE */ && typeof adapter.upload === "function" && typeof adapter.getDownloadUrl === "function";
}
function isBaseAdapter(adapter) {
return typeof adapter === "object" && adapter !== null && "id" in adapter && "type" in adapter && "init" in adapter && "destroy" in adapter && "isInitialized" in adapter;
}
// src/errors/index.ts
var BuddyError = class extends Error {
constructor(message, code, details) {
super(message);
this.code = code;
this.details = details;
this.name = "BuddyError";
}
};
var DatabaseError = class extends BuddyError {
constructor(message, code, details) {
super(message, `database/${code}`, details);
this.name = "DatabaseError";
}
};
var APIError = class extends Error {
constructor(code, message, status = 500, details) {
super(message);
this.code = code;
this.status = status;
this.details = details;
this.name = "APIError";
}
};
var AuthError = class extends APIError {
constructor(message, code = "AUTH_ERROR", status = 401) {
super(code, message, status);
this.name = "AuthError";
}
};
var ValidationError = class extends APIError {
constructor(message, fields) {
super("VALIDATION_ERROR", message, 400);
this.fields = fields;
this.name = "ValidationError";
}
};
export { APIError, AdapterEventType, AdapterRegistry, AdapterType, AuthError, BaseAuthAdapter, BuddyError, DatabaseError, RegistryEventTypes, ValidationError, adapterConfigSchema, adapterRegistry, authConfigSchema, authSessionSchema, baseAdapterConfigSchema, databaseConfigSchema, databaseQueryOptionsSchema, downloadOptionsSchema, emailPasswordCredentialsSchema, fieldTypeSchema, fileMetadataSchema, isAuthAdapter, isAuthConfig, isAuthSession, isBaseAdapter, isDatabaseAdapter, isDatabaseConfig, isEmailPasswordCredentials, isStorageAdapter, isStorageConfig, isUserProfile, listOptionsSchema, listResultSchema, operatorSchema, queryFilterSchema, socialProviderConfigSchema, storageConfigSchema, storedFileSchema, transactionOptionsSchema, uploadOptionsSchema, userProfileSchema, validateConfig };
//# sourceMappingURL=index.mjs.map
//# sourceMappingURL=index.mjs.map