API Reference
Available Packages
Overseer provides two SDK packages:
@overseerai/sdk
- Node.js SDK@overseerai/sdk-typescript
- TypeScript SDK with type safety
Installation
Overseer Class
The main class for interacting with the Overseer SDK.
Constructor
Parameters
Parameter | Type | Required | Description |
---|---|---|---|
apiKey | string | Yes | Your system-specific API key from the connections page in the dashboard |
Methods
validate
Validates the safety of a piece of content.
ValidationResult
Property | Type | Description |
---|---|---|
isAllowed | boolean | Whether the content is safe |
text | string | The validated content |
details | object | Additional details about validation result |
details.reason | string | Reason for rejection if content is not allowed |
Example Usage
Installation
Overseer Class
The main class for interacting with the Overseer SDK with full type safety.
Constructor
Parameters
Parameter | Type | Required | Description |
---|---|---|---|
apiKey | string | Yes | Your system-specific API key from the connections page in the dashboard |
Methods
validate
Validates the safety of a piece of content.
ValidationResult
Property | Type | Description |
---|---|---|
valid | boolean | Whether the content is safe |
content | string | The validated content |
issues | string[] | List of issues found if content is not valid |
Example Usage
Environment Variables
Name | Required | Description |
---|---|---|
API_KEY | Yes | Your system-specific API key from the connections page in the dashboard |