Interfaces
SandboxAdminApp
Properties
| Property | Modifier | Type |
|---|---|---|
[ADMIN_APP_TARGET] | readonly | "sandbox" |
name | readonly | string |
sandbox | readonly | Sandbox |
Type Aliases
InitializeAdminAppConfig
type InitializeAdminAppConfig = {
sandbox: Sandbox;
};
Properties
| Property | Type |
|---|---|
sandbox | Sandbox |
PyricAdminApp
type PyricAdminApp = SandboxAdminApp;
PyricAdminAppTarget
type PyricAdminAppTarget = "sandbox";
Variables
ADMIN_APP_TARGET
const ADMIN_APP_TARGET: unique symbol;
Brand carried by every sandbox admin app.
DEFAULT_APP_NAME
const DEFAULT_APP_NAME: "[DEFAULT]" = "[DEFAULT]";
firebase-admin’s default app name.
Functions
applicationDefault()
function applicationDefault(): never;
Firebase Functions’ ESM runtime statically imports this credential factory while linking its database provider. Pyric initializes the sandbox app before that provider executes, so the factory is not used by supported Functions flows. Keep the named export link-compatible, but fail clearly if application code asks the development sandbox for production credentials.
Returns
never
cert()
function cert(serviceAccountPathOrObject: unknown): object;
Link-compatible mirror of firebase-admin/app’s cert(serviceAccountPathOrObject).
Returns an inert sandbox credential token so unchanged application setup code
can assign appOptions.credential = cert(...) under @pyric/cli/register.
Parameters
| Parameter | Type |
|---|---|
serviceAccountPathOrObject | unknown |
Returns
object
deleteApp()
function deleteApp(app: SandboxAdminApp): Promise<void>;
Remove a sandbox app from the registry.
Parameters
| Parameter | Type |
|---|---|
app | SandboxAdminApp |
Returns
Promise<void>
getApp()
function getApp(name?: string): SandboxAdminApp;
Return the registered app for name.
Parameters
| Parameter | Type |
|---|---|
name? | string |
Returns
getApps()
function getApps(): SandboxAdminApp[];
Return a copy of the app registry.
Returns
initializeApp()
function initializeApp(config?:
| Record<string, unknown>
| InitializeAdminAppConfig, name?: string): SandboxAdminApp;
Initialize a sandbox admin app.
An explicit { sandbox } config binds an in-process or remote sandbox.
A bare call resolves the remote sandbox factory installed by
@pyric/cli/register. Production callers must import firebase-admin/app
without Pyric activation instead of passing production options here.
Parameters
| Parameter | Type |
|---|---|
config? | | Record<string, unknown> | InitializeAdminAppConfig |
name? | string |
Returns
isSandboxAdminApp()
function isSandboxAdminApp(app: SandboxAdminApp): app is SandboxAdminApp;
Parameters
| Parameter | Type |
|---|---|
app | SandboxAdminApp |
Returns
app is SandboxAdminApp