Package Exports
- ugcinc
- ugcinc/dist/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (ugcinc) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
ugcinc
Official TypeScript/JavaScript client for the UGC Inc API.
Installation
npm install ugcinc
Quick Start
import { UGCClient } from 'ugcinc';
const client = new UGCClient({
apiKey: 'your-api-key-here'
});
// Example: Get accounts
const response = await client.accounts.getAccounts();
if (response.ok) {
console.log(response.data);
}
Get Your API Key
To get your API key:
- Visit ugc.inc
- Schedule a call with our team
- You'll receive your API key after the call
Important: Keep your API key secure! Never commit it to version control or expose it in client-side code.
Documentation
For complete API documentation, including all endpoints, parameters, and examples, visit:
API Features
Accounts
- Get accounts with filters
- Get account status
- Update account info (tags, groups)
- Update social profile (avatar, nickname, bio)
Posts
- Create video posts
- Create slideshow posts
- Get post status
- Get post statistics
Tasks
- Get scheduled tasks
- View task history
Statistics
- Get account statistics
- Get post statistics
- Refresh statistics
Organization
- Get API keys (metadata only, excludes key values for security)
- Delete API keys
- Edit API key names
Examples
Get your organization's API keys:
const response = await client.org.getApiKeys(); // POST /org/api-key
if (response.ok) {
console.log(response.data); // [{ id: "...", name: "...", created_at: "..." }]
}
Delete an API key:
const response = await client.org.deleteApiKey({
apiKeyId: 'api-key-uuid'
}); // POST /org/api-key/delete
if (response.ok) {
console.log('API key deleted:', response.data.id);
}
Edit an API key's name:
const response = await client.org.editApiKey({
apiKeyId: 'api-key-uuid',
name: 'New Key Name'
}); // POST /org/api-key/edit
if (response.ok) {
console.log('Updated API key:', response.data); // { id, name, created_at }
}
Create a video post:
const response = await client.posts.createVideo({
accountId: 'account-uuid',
videoUrl: 'https://example.com/video.mp4',
caption: 'Check out this video!',
});
TypeScript Support
This package is written in TypeScript and provides full type definitions:
import type { Account, Post, Task, ApiKey, ApiResponse } from 'ugcinc';
License
MIT