Reports
Create Report
API Reference
Table Management
Company Search
AI Web Search
Reports
Create Report
Create a new report with the specified agent columns and inputs.
POST
/
v1
/
reports
curl --request POST \
--url https://api.extruct.ai/v1/reports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"column_configs": [
{
"kind": "agent",
"name": "Company Description",
"key": "description",
"value": {
"agent_type": "research_pro",
"prompt": "Research the company {company_name} ({company_website}) and provide a short description.",
"output_format": "text"
}
}
],
"inputs": {
"company_name": "Extruct",
"company_website": "https://extruct.ai"
}
}'
{
"id": "<string>",
"name": "<string>",
"status": "created",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"column_configs": [
{
"kind": "input",
"name": "<string>",
"key": "<string>"
}
],
"inputs": {},
"results": {}
}
Examples
Single Data Point Example
This example shows how to create a report that extracts a single piece of information about a company:
{
"name": "Company Revenue",
"inputs": {
"company_name": "Stripe",
"company_website": "https://stripe.com"
},
"column_configs": [
{
"key": "annual_revenue",
"name": "Annual Revenue",
"description": "Company's annual revenue for the latest fiscal year",
"value": {
"agent_type": "research_pro",
"prompt": "What is {company_name}'s annual revenue for the most recent fiscal year? Return just the number in millions USD.",
"output_format": "number"
}
}
]
}
Basic Company Research Report
This example shows how to create a report with different output formats:
{
"name": "Company Research Report",
"inputs": {
"company_name": "Stripe",
"company_website": "https://stripe.com"
},
"column_configs": [
{
"key": "company_description",
"name": "Company Description",
"description": "Brief overview of the company",
"value": {
"agent_type": "research_pro",
"prompt": "Provide a concise overview of {company_name}, including their main products/services and target market.",
"output_format": "text"
}
},
{
"key": "linkedin_url",
"name": "LinkedIn URL",
"description": "Company's LinkedIn profile",
"value": {
"agent_type": "research_pro",
"prompt": "Find the official LinkedIn company page URL for {company_name}.",
"output_format": "url"
}
},
{
"key": "key_metrics",
"name": "Key Metrics",
"description": "Basic company metrics",
"value": {
"agent_type": "research_pro",
"prompt": "Find the following metrics for {company_name}: number of employees, year founded, headquarters location.",
"output_format": "json",
"output_schema": {
"type": "object",
"properties": {
"employees": {
"type": "number"
},
"founded": {
"type": "number"
},
"headquarters": {
"type": "string"
}
}
}
}
}
]
}
Detailed Company Analysis Report
This example shows how to combine multiple simple data points:
{
"name": "Detailed Company Analysis",
"inputs": {
"company_name": "Figma",
"company_website": "https://figma.com"
},
"column_configs": [
{
"key": "ceo_name",
"name": "CEO Name",
"description": "Name of the current CEO",
"value": {
"agent_type": "research_pro",
"prompt": "Who is the current CEO of {company_name}?",
"output_format": "text"
}
},
{
"key": "competitors",
"name": "Main Competitors",
"description": "List of main competitors",
"value": {
"agent_type": "research_pro",
"prompt": "List the main competitors of {company_name}. For each competitor, provide their name and main product.",
"output_format": "json",
"output_schema": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"product": {
"type": "string"
}
}
}
}
}
},
{
"key": "recent_news",
"name": "Recent News",
"description": "Latest significant news about the company",
"value": {
"agent_type": "research_pro",
"prompt": "What are the most significant news or announcements about {company_name} in the last 3 months?",
"output_format": "text"
}
},
{
"key": "valuation",
"name": "Company Valuation",
"description": "Current company valuation",
"value": {
"agent_type": "research_pro",
"prompt": "What is the current valuation of {company_name}? For public companies, use market cap. For private companies, use the latest valuation from funding rounds. Return just the number in billions USD.",
"output_format": "number"
}
}
]
}
These examples demonstrate key features of the Reports API:
- Simple output formats: text, number, url
- Basic JSON schemas for structured data
- Single company focus with specific data points
- Clear, focused prompts for each data point
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
Response
200
application/json
Successful Response
Available options:
created
, in_progress
, done
, failed
curl --request POST \
--url https://api.extruct.ai/v1/reports \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"column_configs": [
{
"kind": "agent",
"name": "Company Description",
"key": "description",
"value": {
"agent_type": "research_pro",
"prompt": "Research the company {company_name} ({company_website}) and provide a short description.",
"output_format": "text"
}
}
],
"inputs": {
"company_name": "Extruct",
"company_website": "https://extruct.ai"
}
}'
{
"id": "<string>",
"name": "<string>",
"status": "created",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"column_configs": [
{
"kind": "input",
"name": "<string>",
"key": "<string>"
}
],
"inputs": {},
"results": {}
}