@nucypher/taco
Version:
### [`nucypher/taco-web`](../../README.md)
29 lines (28 loc) • 1.38 kB
TypeScript
import { ThresholdMessageKit } from '@nucypher/nucypher-core';
import { AuthProvider, AuthSignature } from '@nucypher/taco-auth';
import { CoreContext } from '../../types';
import { Condition } from '../condition';
export type CustomContextParam = string | number | boolean | bigint | Uint8Array;
export type ContextParam = CustomContextParam | AuthSignature;
export declare const RESERVED_CONTEXT_PARAMS: string[];
export declare class ConditionContext {
requestedContextParameters: Set<string>;
private customContextParameters;
private authProviders;
constructor(condition: Condition);
private static validateCoreConditions;
private validateNoMissingContextParameters;
private fillContextParameters;
private validateAuthProviders;
private fillAuthContextParameters;
private validateCustomContextParameter;
private static isContextParameter;
private static findContextParameter;
private static findContextParameters;
addCustomContextParameterValues(customContextParameters: Record<string, CustomContextParam>): void;
addAuthProvider(contextParam: string, authProvider: AuthProvider): void;
toJson(): Promise<string>;
toCoreContext(): Promise<CoreContext>;
toContextParameters: () => Promise<Record<string, ContextParam>>;
static fromMessageKit(messageKit: ThresholdMessageKit): ConditionContext;
}