@shopify/cli-kit
Version:
A set of utilities, interfaces, and models that are common across all the platform features
1,117 lines (1,116 loc) • 34.9 kB
TypeScript
import { zod } from '../../../public/node/schema.js';
/**
* The schema represents an Identity token.
*/
declare const IdentityTokenSchema: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
/**
* The schema represents an application token.
*/
declare const ApplicationTokenSchema: zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>;
declare const SessionSchema: zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>;
/**
* This schema represents the format of the session
* that we cache in the system to avoid unnecessary
* token exchanges.
*
* @example
* ```
* {
* "accounts.shopify.com": {
* "user-123": {
* "identity": { ... }, // IdentityTokenSchema
* "applications": {
* "mystore.myshopify.com-admin": { // ApplicationTokenSchema
* "accessToken": "...",
* "expiresAt": "...",
* "scopes": ["..."],
* },
* "partners": { ... },
* }
* },
* "8765-4321": { ... }
* },
* "identity.spin.com": {
* "user-345": { ... }
* }
* }
* ```
*/
export declare const SessionsSchema: zod.ZodObject<{}, "strip", zod.ZodObject<{}, "strip", zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, zod.objectOutputType<{}, zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, "strip">>, zod.objectOutputType<{}, zod.ZodObject<{}, "strip", zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, zod.objectOutputType<{}, zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, "strip">>, "strip">, zod.objectInputType<{}, zod.ZodObject<{}, "strip", zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, zod.objectOutputType<{}, zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
identity: zod.ZodObject<{
accessToken: zod.ZodString;
refreshToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
userId: zod.ZodString;
alias: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
}, {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
}>;
applications: zod.ZodObject<{}, "strip", zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, zod.objectOutputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">, zod.objectInputType<{}, zod.ZodObject<{
accessToken: zod.ZodString;
expiresAt: zod.ZodEffects<zod.ZodDate, Date, unknown>;
scopes: zod.ZodArray<zod.ZodString, "many">;
storeFqdn: zod.ZodOptional<zod.ZodString>;
}, "strip", zod.ZodTypeAny, {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
}, {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
}>, "strip">>;
}, "strip", zod.ZodTypeAny, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
expiresAt: Date;
userId: string;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt: Date;
storeFqdn?: string | undefined;
};
};
}, {
identity: {
accessToken: string;
refreshToken: string;
scopes: string[];
userId: string;
expiresAt?: unknown;
alias?: string | undefined;
};
applications: {} & {
[k: string]: {
accessToken: string;
scopes: string[];
expiresAt?: unknown;
storeFqdn?: string | undefined;
};
};
}>, "strip">>, "strip">>;
export type Sessions = zod.infer<typeof SessionsSchema>;
export type Session = zod.infer<typeof SessionSchema>;
export type IdentityToken = zod.infer<typeof IdentityTokenSchema>;
export type ApplicationToken = zod.infer<typeof ApplicationTokenSchema>;
/**
* Confirms that a given identity token structure matches what the schema currently defines.
*
* A full re-auth is the expectation if this validation fails.
*/
export declare function validateCachedIdentityTokenStructure(identityToken: unknown): boolean;
export {};