@memberjunction/ai-heygen 4.4.0 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +6 -4
- package/CHANGELOG.md +12 -0
- package/package.json +3 -3
- package/README.md +0 -93
package/.turbo/turbo-build.log
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @memberjunction/ai-heygen
|
|
2
2
|
|
|
3
|
+
## 5.0.0
|
|
4
|
+
|
|
5
|
+
### Major Changes
|
|
6
|
+
|
|
7
|
+
- 4aa1b54: breaking changes due to class name updates/approach
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [4aa1b54]
|
|
12
|
+
- @memberjunction/ai@5.0.0
|
|
13
|
+
- @memberjunction/global@5.0.0
|
|
14
|
+
|
|
3
15
|
## 4.4.0
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@memberjunction/ai-heygen",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "5.0.0",
|
|
5
5
|
"description": "MemberJunction Wrapper for HeyGen Video Generation",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"scripts": {
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
"typescript": "^5.9.3"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@memberjunction/ai": "
|
|
20
|
-
"@memberjunction/global": "
|
|
19
|
+
"@memberjunction/ai": "5.0.0",
|
|
20
|
+
"@memberjunction/global": "5.0.0",
|
|
21
21
|
"axios": "^1.13.4",
|
|
22
22
|
"@elevenlabs/elevenlabs-js": "^2.34.0"
|
|
23
23
|
},
|
package/README.md
DELETED
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
# @memberjunction/ai-heygen
|
|
2
|
-
|
|
3
|
-
MemberJunction AI provider for HeyGen's AI video generation platform. This package implements the `BaseVideoGenerator` interface to create avatar-based videos with customizable characters, voices, and backgrounds.
|
|
4
|
-
|
|
5
|
-
## Architecture
|
|
6
|
-
|
|
7
|
-
```mermaid
|
|
8
|
-
graph TD
|
|
9
|
-
A["HeyGenVideoGenerator<br/>(Provider)"] -->|extends| B["BaseVideoGenerator<br/>(@memberjunction/ai)"]
|
|
10
|
-
A -->|uses| C["Axios HTTP Client"]
|
|
11
|
-
A -->|calls| D["HeyGen Video API<br/>(api.heygen.com/v2)"]
|
|
12
|
-
D -->|generates| E["Avatar Videos"]
|
|
13
|
-
A -->|queries| F["HeyGen Avatars API"]
|
|
14
|
-
F -->|returns| G["Available Avatars"]
|
|
15
|
-
B -->|registered via| H["@RegisterClass"]
|
|
16
|
-
|
|
17
|
-
style A fill:#7c5295,stroke:#563a6b,color:#fff
|
|
18
|
-
style B fill:#2d6a9f,stroke:#1a4971,color:#fff
|
|
19
|
-
style C fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
20
|
-
style D fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
21
|
-
style E fill:#b8762f,stroke:#8a5722,color:#fff
|
|
22
|
-
style F fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
23
|
-
style G fill:#b8762f,stroke:#8a5722,color:#fff
|
|
24
|
-
style H fill:#b8762f,stroke:#8a5722,color:#fff
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
## Features
|
|
28
|
-
|
|
29
|
-
- **Avatar Video Generation**: Create videos with AI avatars synchronized to audio
|
|
30
|
-
- **Avatar Management**: Browse available avatars with preview images and videos
|
|
31
|
-
- **Customizable Layout**: Control avatar scale, position (offset X/Y), and style
|
|
32
|
-
- **Custom Backgrounds**: Use image assets as video backgrounds
|
|
33
|
-
- **Audio Integration**: Sync avatar lip movements with audio assets
|
|
34
|
-
- **Resolution Control**: Set custom output width and height
|
|
35
|
-
|
|
36
|
-
## Installation
|
|
37
|
-
|
|
38
|
-
```bash
|
|
39
|
-
npm install @memberjunction/ai-heygen
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
## Usage
|
|
43
|
-
|
|
44
|
-
### Create Avatar Video
|
|
45
|
-
|
|
46
|
-
```typescript
|
|
47
|
-
import { HeyGenVideoGenerator } from '@memberjunction/ai-heygen';
|
|
48
|
-
|
|
49
|
-
const generator = new HeyGenVideoGenerator('your-heygen-api-key');
|
|
50
|
-
|
|
51
|
-
const result = await generator.CreateAvatarVideo({
|
|
52
|
-
avatarId: 'avatar-id',
|
|
53
|
-
avatarStyle: 'normal',
|
|
54
|
-
scale: 1.0,
|
|
55
|
-
offsetX: 0,
|
|
56
|
-
offsetY: 0,
|
|
57
|
-
audioAssetId: 'audio-asset-id',
|
|
58
|
-
imageAssetId: 'background-asset-id',
|
|
59
|
-
outputWidth: 1920,
|
|
60
|
-
outputHeight: 1080
|
|
61
|
-
});
|
|
62
|
-
|
|
63
|
-
if (result.success) {
|
|
64
|
-
console.log('Video ID:', result.videoId);
|
|
65
|
-
}
|
|
66
|
-
```
|
|
67
|
-
|
|
68
|
-
### List Avatars
|
|
69
|
-
|
|
70
|
-
```typescript
|
|
71
|
-
const avatars = await generator.GetAvatars();
|
|
72
|
-
for (const avatar of avatars) {
|
|
73
|
-
console.log(`${avatar.name} (${avatar.gender}): ${avatar.previewImageUrl}`);
|
|
74
|
-
}
|
|
75
|
-
```
|
|
76
|
-
|
|
77
|
-
## Supported Methods
|
|
78
|
-
|
|
79
|
-
| Method | Description |
|
|
80
|
-
|--------|-------------|
|
|
81
|
-
| `CreateAvatarVideo` | Generate an avatar video with audio and background |
|
|
82
|
-
| `GetAvatars` | List available avatars with preview media |
|
|
83
|
-
| `CreateVideoTranslation` | Translate existing video (not yet implemented) |
|
|
84
|
-
|
|
85
|
-
## Class Registration
|
|
86
|
-
|
|
87
|
-
Registered as `HeyGenVideoGenerator` via `@RegisterClass(BaseVideoGenerator, 'HeyGenVideoGenerator')`.
|
|
88
|
-
|
|
89
|
-
## Dependencies
|
|
90
|
-
|
|
91
|
-
- `@memberjunction/ai` - Core AI abstractions (BaseVideoGenerator)
|
|
92
|
-
- `@memberjunction/global` - Class registration
|
|
93
|
-
- `axios` - HTTP client for API communication
|