@cdp-forge/types
v1.2.0
Published
TypeScript types for @cdp-forge
Readme
@cdp-forge/types
TypeScript type definitions for the CDP Forge Plugin Pipeline SDK.
📦 Installation
npm install @cdp-forge/types🚀 Usage
import {
Log,
Product,
GoogleTopic,
ConfigMessage,
Config
} from '@cdp-forge/types';
// Use the types in your plugin
const log: Log = {
client: 1,
date: "2024-01-01T00:00:00Z",
device: {
id: "device-123"
},
event: "page_view",
instance: 1,
page: {
title: "Homepage"
},
session: "session-123"
};
// Type your configuration
const config: Config = {
kafkaConfig: {
brokers: ['localhost:9092']
},
manager: {
url: 'https://manager.example.com',
config_topic: 'config'
},
plugin: {
name: 'myPlugin',
priority: 1,
type: 'blocking'
}
};📋 Available Types
Core Types
Log- Main log object structureProduct- Product informationGoogleTopic- Google topics dataConfigMessage- Configuration messagesConfig- Complete configuration structure
Google Topics
GoogleTopicsMap- Map of Google topics with their names
🔗 Related
- @cdp-forge/core - Main CDP Forge package
�� License
GPL-3.0
