Overview
The Prompts API allows you to store prompts that users have submitted to AI providers and retrieve them for analysis. Prompts are the foundation of OneGlance’s brand tracking capabilities.Endpoints
store
Store one or more prompts for a workspace. These prompts will be analyzed for brand mentions. Type: Mutation (Authorized Workspace) Rate Limit: 20 requests per minuteID of the workspace to store prompts for
Array of prompt strings to store. Each prompt must be 1-500 characters. Minimum 1 prompt, maximum 100 prompts per request.
Number of prompts successfully stored
Array of stored prompt objects
Validation Rules
- Minimum 1 prompt per request
- Maximum 100 prompts per request
- Each prompt must be between 1-500 characters
- All prompts must be non-empty strings
fetchPromptSources
Retrieve aggregated statistics about prompt sources for the workspace. Type: Query (Authorized Workspace)ID of the workspace
Array of prompt sources with counts and metadata
fetchUserPrompts
Retrieve all user-submitted prompts for the workspace. Type: Query (Authorized Workspace)ID of the workspace
Array of prompt objects submitted by users (excludes agent-collected prompts)
Prompt Sources
Prompts in OneGlance can come from two sources:- user: Manually submitted by workspace members
- agent: Automatically collected by OneGlance agents from AI provider responses
Use Cases
Manual Prompt Submission
Use thestore endpoint when you want to track specific prompts that users have encountered:
Batch Import
Import multiple prompts at once (up to 100 per request):Analyzing Stored Prompts
After storing prompts, use the Analysis API to extract brand mentions:Related Resources
Analysis API
Analyze prompts for brand mentions
Agent API
Automate prompt collection
Workspace API
Manage workspace settings