CoreStory Pre Ingestion API
The pre_ingestion API from CoreStory — 10 operation(s) for pre_ingestion.
The pre_ingestion API from CoreStory — 10 operation(s) for pre_ingestion.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/corestory-pre-ingestion-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Crowdbotics API Documentation Pre Ingestion API
description: '# CoreStory API Overview
The CoreStory API provides programmatic access to structured insights derived from software source code.'
version: 1.26.2
servers:
- url: /
description: Current server
security:
- BearerAuth: []
tags:
- name: pre_ingestion
paths:
/api/pre-ingestion/start:
post:
tags:
- pre_ingestion
summary: Start Pre-Ingestion Process
description: 'Start the pre-ingestion process for a specific repository. This process
will analyze the repository and return a summary of the supported files.
Args:
request (PreIngestionRequest): The incoming request object.
user (ClerkUser): The authenticated user.
organization (Organization): The organization context.
db (Session): The database session.
Returns:
PreIngestionResponse: Details about the initiated pre-ingestion process.'
operationId: start_pre_ingestion
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/StartPreIngestionRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PreIngestionResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/start/upload-repository:
post:
tags:
- pre_ingestion
summary: Upload repository files and run the pre-ingestion analysis
description: Upload a single zipped repository file to Azure Blob Storage or Local directory,create a new project, and trigger pre-ingestion analysis.
operationId: start_pre_ingestion_from_upload
requestBody:
content:
multipart/form-data:
schema:
$ref: '#/components/schemas/Body_start_pre_ingestion_from_upload'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PreIngestionResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/upload-url:
post:
tags:
- pre_ingestion
summary: Get a pre-signed URL for direct file upload
description: Returns a time-limited pre-signed URL that allows the client to upload a file directly to storage, bypassing server-side proxying and Cloudflare's upload size limits.
operationId: get_upload_url
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UploadUrlRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/UploadUrlResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/start/from-storage:
post:
tags:
- pre_ingestion
summary: Start pre-ingestion from an already-uploaded file
description: Triggers the pre-ingestion analysis for a file that was uploaded directly to storage via a pre-signed URL obtained from the /upload-url endpoint.
operationId: start_pre_ingestion_from_storage
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/StartFromStorageRequest'
required: true
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PreIngestionResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/{job_id}/status:
get:
tags:
- pre_ingestion
summary: Get Pre-Ingestion Job Status
description: 'Get the status of a pre-ingestion job by its ID.
Args:
job_id (int): The ID of the pre-ingestion job.
user (ClerkUser): The authenticated user.
organization (Organization): The organization context.
db (Session): The database session.
Returns:
PreIngestionResponse: Details about the pre-ingestion job status.'
operationId: get_pre_ingestion_status
parameters:
- name: job_id
in: path
required: true
schema:
type: integer
title: Job Id
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PreIngestionResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/{job_id}/coverage:
get:
tags:
- pre_ingestion
summary: Get Pre-Ingestion Job Results
description: 'Get the coverage results of a pre-ingestion job by its ID.
Args:
job_id (int): The ID of the pre-ingestion job.
user (ClerkUser): The authenticated user.
organization (Organization): The organization context.
db (Session): The database session.
Returns:
PreIngestionCoverageResponse: Coverage details of the pre-ingestion job.'
operationId: get_pre_ingestion_coverage
parameters:
- name: job_id
in: path
required: true
schema:
type: integer
title: Job Id
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PreIngestionCoverageResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/{job_id}/excluded-files:
get:
tags:
- pre_ingestion
summary: Get Excluded File Paths from Pre-Ingestion Job
description: 'Get the list of excluded file paths from a pre-ingestion job by its ID.
Args:
job_id (int): The ID of the pre-ingestion job.
user (ClerkUser): The authenticated user.
organization (Organization): The organization context.
db (Session): The database session.
file_name (str, optional): Filter files by name.
Returns:
list[str]: List of excluded file paths.'
operationId: get_pre_ingestion_excluded_files
parameters:
- name: job_id
in: path
required: true
schema:
type: integer
title: Job Id
- name: page
in: query
required: false
schema:
type: integer
minimum: 1
description: Page number (1-based)
default: 1
title: Page
description: Page number (1-based)
- name: size
in: query
required: false
schema:
type: integer
maximum: 1000
minimum: 1
description: Items per page
default: 100
title: Size
description: Items per page
- name: file_name
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: File Name
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PaginatedFilePathResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/{job_id}/included-files:
get:
tags:
- pre_ingestion
summary: Get Included File Paths from Pre-Ingestion Job
description: 'Get the list of included file paths from a pre-ingestion job by its ID.
Args:
job_id (int): The ID of the pre-ingestion job.
user (ClerkUser): The authenticated user.
organization (Organization): The organization context.
db (Session): The database session.
file_name (str, optional): Filter files by name.
Returns:
list[str]: Paginated list of included file paths.'
operationId: get_pre_ingestion_included_files
parameters:
- name: job_id
in: path
required: true
schema:
type: integer
title: Job Id
- name: page
in: query
required: false
schema:
type: integer
minimum: 1
description: Page number (1-based)
default: 1
title: Page
description: Page number (1-based)
- name: size
in: query
required: false
schema:
type: integer
maximum: 1000
minimum: 1
description: Items per page
default: 100
title: Size
description: Items per page
- name: file_name
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: File Name
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PaginatedFilePathResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/{job_id}:
delete:
tags:
- pre_ingestion
summary: Delete Pre-Ingestion Job
description: 'Delete a pre-ingestion job by its ID.
Args:
job_id (int): The ID of the pre-ingestion job.
user (ClerkUser): The authenticated user.
organization (Organization): The organization context.
db (Session): The database session.
storage (StorageBackend): Storage backend for artifact cleanup.
Returns:
dict: Confirmation message upon successful deletion.'
operationId: delete_pre_ingestion_job
parameters:
- name: job_id
in: path
required: true
schema:
type: integer
title: Job Id
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Delete Pre Ingestion Job
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
patch:
tags:
- pre_ingestion
summary: Update Pre-Ingestion Job
description: 'Update a pre-ingestion job by its ID.
Args:
job_id (int): The ID of the pre-ingestion job.
user (ClerkUser): The authenticated user.
organization (Organization): The organization context.
application_context (str, optional): New application context.
db (Session): The database session.
Returns:
PreIngestionResponse: Updated details of the pre-ingestion job.'
operationId: update_pre_ingestion_job
parameters:
- name: job_id
in: path
required: true
schema:
type: integer
title: Job Id
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/PreIngestionUpdateRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PreIngestionResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
/api/pre-ingestion/{pre_ingestion_id}/estimate-ingestion:
get:
tags:
- pre_ingestion
summary: Estimate CIU cost for a number of LOC and files count
description: Estimate the CIU cost for ingesting a codebase based on the number of lines of code and files.
operationId: estimate_ciu_cost_for_ingestion
parameters:
- name: pre_ingestion_id
in: path
required: true
schema:
type: integer
title: Pre Ingestion Id
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/EstimateIngestionResponse'
default:
description: Error
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorSchema'
components:
schemas:
PreIngestionCoverageResponse:
properties:
project_id:
anyOf:
- type: integer
- type: 'null'
title: Project Id
repository_url:
anyOf:
- type: string
- type: 'null'
title: Repository Url
branch:
anyOf:
- type: string
- type: 'null'
title: Branch
total_files:
type: integer
title: Total Files
default: 0
total_directories:
type: integer
title: Total Directories
default: 0
code_analysis:
additionalProperties: true
type: object
title: Code Analysis
description: Dict with ingestion files analysis and detections.
file_coverage:
type: number
title: File Coverage
description: Coverage percentage from 0.0 to 100.0
default: 0.0
included_count:
additionalProperties: true
type: object
title: Included Count
description: List of objects representing file type and its count
excluded_count:
additionalProperties: true
type: object
title: Excluded Count
description: List of objects representing file type and its count
exclusion_reasons:
additionalProperties: true
type: object
title: Exclusion Reasons
description: Breakdown of files by exclusion reason (e.g., minified, third_party_vendored)
type: object
required:
- repository_url
- branch
- included_count
- excluded_count
title: PreIngestionCoverageResponse
ErrorSchema:
properties:
error:
$ref: '#/components/schemas/ErrorBody'
type: object
required:
- error
title: ErrorSchema
StartFromStorageRequest:
properties:
storage_key:
type: string
minLength: 1
title: Storage Key
description: Storage key returned by the upload-url endpoint
app_custom_name:
type: string
minLength: 1
title: App Custom Name
description: Custom application name for the project
context:
type: string
title: Context
description: Application context for the project
default: ''
type: object
required:
- storage_key
- app_custom_name
title: StartFromStorageRequest
PaginatedFilePathResponse:
properties:
results:
items:
type: string
type: array
title: Results
description: List of filepaths in pre-ingestion job
pagination:
anyOf:
- additionalProperties: true
type: object
- type: 'null'
title: Pagination
type: object
required:
- results
- pagination
title: PaginatedFilePathResponse
PreIngestionResponse:
properties:
id:
type: integer
title: Id
project_id:
anyOf:
- type: integer
- type: 'null'
title: Project Id
status:
$ref: '#/components/schemas/PreIngestionStatus'
created_at:
type: string
format: date-time
title: Created At
updated_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Updated At
progress:
type: number
title: Progress
description: Progress percentage from 0.0 to 100.0
default: 0.0
application_context:
anyOf:
- type: string
- type: 'null'
title: Application Context
type: object
required:
- id
- status
- created_at
- updated_at
title: PreIngestionResponse
EstimateIngestionResponse:
properties:
estimated_ciu_cost:
type: number
title: Estimated Ciu Cost
description: Estimated CIU cost for ingesting the codebase
remaining_ciu_balance:
anyOf:
- type: number
- type: 'null'
title: Remaining Ciu Balance
description: Remaining CIU balance for the organization after the estimated cost is deducted
type: object
required:
- estimated_ciu_cost
title: EstimateIngestionResponse
UploadUrlResponse:
properties:
upload_url:
type: string
title: Upload Url
description: Pre-signed URL for direct upload to storage
storage_key:
type: string
title: Storage Key
description: Storage key to reference when starting ingestion
expires_at:
type: string
format: date-time
title: Expires At
description: UTC timestamp when the upload URL expires
type: object
required:
- upload_url
- storage_key
- expires_at
title: UploadUrlResponse
PreIngestionStatus:
type: string
enum:
- started
- cloning
- parsing
- analyzed
- completed
- failed
title: PreIngestionStatus
description: PreIngestion status enumeration
UploadUrlRequest:
properties:
filename:
type: string
minLength: 1
title: Filename
description: Name of the file to upload (e.g. 'codebase.zip')
file_size_bytes:
type: integer
exclusiveMinimum: 0.0
title: File Size Bytes
description: Size of the file in bytes
content_type:
type: string
title: Content Type
description: MIME type of the file
default: application/octet-stream
type: object
required:
- filename
- file_size_bytes
title: UploadUrlRequest
StartPreIngestionRequest:
properties:
public_repo_url:
anyOf:
- type: string
- type: 'null'
title: Public Repo Url
description: Full GitHub repository URL (format 1)
repo_full_name:
anyOf:
- type: string
- type: 'null'
title: Repo Full Name
description: Repository full name like 'owner/repo' (format 2)
repo_branch:
type: string
title: Repo Branch
description: Branch name
default: main
github_app_installation_id:
anyOf:
- type: integer
- type: 'null'
title: Github App Installation Id
description: GitHub App installation ID for private repository access
app_custom_name:
type: string
minLength: 1
title: App Custom Name
description: Custom application name for the project
type: object
required:
- app_custom_name
title: StartPreIngestionRequest
description: Body schema for POST /api/pre-ingestion/start.
PreIngestionUpdateRequest:
properties:
application_context:
anyOf:
- type: string
- type: 'null'
title: Application Context
type: object
title: PreIngestionUpdateRequest
ErrorBody:
properties:
message:
type: string
title: Message
type:
type: string
title: Type
details:
additionalProperties: true
type: object
title: Details
description: Optional extra context for the error.
type: object
required:
- message
- type
title: ErrorBody
Body_start_pre_ingestion_from_upload:
properties:
app_custom_name:
type: string
title: App Custom Name
description: Custom application name for the project
context:
type: string
title: Context
description: Application context for the project
default: ''
file:
type: string
contentMediaType: application/octet-stream
title: File
description: Zipped repository file to upload
type: object
required:
- app_custom_name
- file
title: Body_start_pre_ingestion_from_upload
securitySchemes:
BearerAuth:
type: http
scheme: bearer
bearerFormat: JWT
description: Enter the Bearer token from Clerk authentication
x-tagGroups:
- name: Ingest Your Codebase
tags:
- vector_store
- projects
- pre_ingestion
- reingestion
- name: Generate Code Intelligence
tags:
- documents
- document_generation
- document_formatters
- prd
- prd_version
- tech_spec
- quality_metrics
- sample_projects
- name: Query Your Codebase
tags:
- conversations
- workflows
- discovery
- context
- artifacts
- name: Manage and Inspect Intelligence
tags:
- api_debugging
- events
- version
- files
- cache
- token_tracking
- name: Authenticate and Manage Access
tags:
- clerk_authentication
- github_webhooks
- github_integration
- organizations
- api_key_management
- mcp_token_management
- user
- name: (Advanced) Prompt Tuning
tags:
- prompts
- name: MCP Protocol
tags:
- mcp_protocol
- name: Administration
tags:
- admin