---
title: "openvibe-sdk/vip · OpenVibe.Services"
canonical: "https://openvibe.services/docs/sdk/vip"
updated: null
---

# openvibe-sdk/vip · OpenVibe.Services

HTML: [openvibe-sdk/vip · OpenVibe.Services](https://openvibe.services/docs/sdk/vip)

# `openvibe-sdk/vip`

Generated at 2026-12-01 05:42:00 UTC from [`openvibe-contracts v0.454.0`](https://github.com/OpenVibers/OpenVibe.Contracts/tree/v0.454.0) and [`openvibe-sdk v0.193.0`](https://github.com/OpenVibers/OpenVibe.SDK/tree/v0.193.0).

From `types/vip.d.ts` (server only). Declarations are shown verbatim.

## interface VipTokenClient

openvibe-sdk/vip: the consumer seam for products that honour OpenVibe.VIP memberships (server-side).

~~~~
export interface VipTokenClient { authHeaders(): Promise<Record<string, string>>; invalidate?(): void }
~~~~

## interface VipClientOptions

~~~~
export interface VipClientOptions {
    baseUrl?: string;
    tokenClient?: VipTokenClient | null;
    getToken?: (() => Promise<string>) | null;
    fetch?: typeof fetch;
    timeoutMs?: number;
    log?: { warn(...a: unknown[]): void } | null;
}
~~~~

## interface VipRef

~~~~
export interface VipRef { service: string; type: string; id: string }
~~~~

## interface VipDecision

~~~~
export interface VipDecision { allow: boolean; reason: string; [k: string]: unknown }
~~~~

## interface VipEntitlement

~~~~
export interface VipEntitlement { status: 'active' | 'inactive' | 'unknown' | string; active: boolean; product_perks?: unknown[]; [k: string]: unknown }
~~~~

## interface VipClient

~~~~
export interface VipClient {
    evaluate(input: { subject?: string | null; resource: VipRef; owner?: string | null; ruleId?: string; mode?: 'projection' | 'authoritative'; fallback?: { requirement: string; binding?: string } }): Promise<VipDecision>;
    checkEntitlement(input: { subject: string; creator: string; mode?: 'projection' | 'authoritative'; product?: string }): Promise<VipEntitlement>;
    isMember(subject: string, creator: string, opts?: { mode?: 'projection' | 'authoritative' }): Promise<boolean>;
    [k: string]: unknown;
}
~~~~

## interface VipCache

~~~~
export interface VipCache {
    entitlement(input: { subject: string; creator: string; product?: string }): Promise<VipEntitlement>;
    peekEntitlement(input: { subject: string; creator: string; product?: string }): VipEntitlement | undefined;
    evaluate(input: { subject?: string | null; resource: VipRef; owner?: string | null; fallback?: { requirement: string; binding?: string }; mode?: string }): Promise<VipDecision>;
    invalidate(input: { member: string; creator: string }): void;
    handleEvent(envelope: unknown): boolean;
    clear(): void;
    readonly bounds: Record<string, number>;
}
~~~~

## export export function createVipClient(options?: VipClientOptions):

~~~~
export function createVipClient(options?: VipClientOptions): VipClient;
~~~~

## export export function createVipCache(options: { vip: VipClient; tt

~~~~
export function createVipCache(options: { vip: VipClient; ttlMs?: number; denyTtlMs?: number; unavailableTtlMs?: number; maxEntries?: number; now?: () => number }): VipCache;
~~~~
