Lime Web Components API Documentation - v6.24.0
    Preparing search index...

    Interface UserCoworker

    Reference to a user's associated coworker business object.

    In Lime CRM, user accounts (for authentication) are often separate from coworker/employee records (business objects with additional data). This interface provides the link between the two, allowing you to load the full coworker record when needed.

    // Load full coworker details
    const user = appRepo.getCurrentUser();
    if (user.coworker) {
    const repo = platform.get(PlatformServiceName.LimeObjectRepository);
    const coworker = await repo.loadObject(
    user.coworker.limetype, // Usually 'coworker' or 'employee'
    user.coworker.id
    );

    // Access additional properties
    console.log(`Phone: ${coworker.properties.phone}`);
    console.log(`Department: ${coworker.properties.department}`);
    }
    interface UserCoworker {
        id: number;
        limetype: string;
    }
    Index

    Properties

    Properties

    id: number

    The ID of the coworker LimeObject.

    Use this with LimeObjectRepository to load the full coworker record.

    limetype: string

    The name of the Limetype used for coworker records.

    Typically "coworker" or "employee", but can vary by configuration. Use this as the limetype parameter when loading the object.