Update enrichment
/enrichments/{id}Edit an enrichment in place: name, prompt, input_columns (the headers its rows must carry; [] = any), budget and budget_locked, only_tools / additional_tools, and output columns by name. Inside output, a name not yet on the enrichment adds a column (typed from the prompts when it has no output_schema and its value is one plain value); { "prompt", "output_schema" } change one; { "tool": "linkedin_person_profile" } pins a tool to it — one call of it per row is the cell, the agent choosing the call's arguments (the ColumnToolPin; "tool": null unpins); { "rename": "New name" } renames one (cells keep their values); { "delete": true } removes one. Every call is one write: version goes up by one and every added or changed column takes it, so cells filled under the old prompt, schema, or pin read stale on datasets bound to this enrichment and are re-run by their next fill. A rename changes nothing on the cells.
The budget follows the columns: adding a column raises budget_credits_per_row by 1.5, removing one lowers it by 1.5 (within 0.1–100), unless budget_locked is true or the same call sets budget. Set budget_locked: true to keep the budget as set from then on.
Refused with 409 enrichment_in_use while a fill runs on it (the fill reads the recipe as it goes): wait for the run or stop it. To edit the columns of one dataset without touching other datasets on the same enrichment, use PATCH /datasets/{id}, which copies a shared enrichment first.
Path parameters
idstringrequiredThe enrichment id (enr_...)
Request bodyrequired
namestringDisplay name. An empty string clears it.
promptstringThe task prompt the row agent reads for every row.
input_columnsarray of stringThe headers rows must carry when this enrichment runs (replaces the list; [] = any headers). Names only; no row data.
budgetnumberCredits the row agent may spend per row. Sent with column changes, it wins over the per-column adjustment.
budget_lockedbooleantrue keeps the budget as set when output columns are added or removed; false lets it move by 1.5 per column again.
only_toolsarray of stringExactly these tools (names from GET /tools). Replaces the default set.
additional_toolsarray of stringThe default tools plus these (e.g. linkedin_person_contact; custom_apollo_people_search once enabled on the account and your Apollo key is linked). See GET /v1/tools.
outputOutputColumnOperationsOutput column edits keyed by column name. A name not on the enrichment adds a column; prompt / output_schema / tool change one (its filled cells read stale); rename renames it (cells kept); delete: true removes it.
Attributes
promptstringWhat to find for this column, one value. Leave sources out; the agent records the URLs it cited on the cell's sources.
output_schemaobjectA JSON Schema for the cell value (help with output_schema). Leave it out on an added column: the type is inferred from the prompt, caveats included. Send one only for an enum, a list, or an object.
A tool name from GET /tools. The row agent makes one call of it per row — arguments it works out from the row, the known values, and its research; the column prompt says what to call it on — and the call's result is the cell. null unpins. help with pinned_columns.
renamestringThe column's new name
deletebooleanRemove the column
Responses
200The enrichment after the edit (its version went up)
idstringenr_...
namestringnullablepromptstringThe task prompt the row agent reads for every row
input_columnsarray of stringThe headers rows must carry (empty = any)
outputarray of OutputColumnSpecAttributes
namestringrequiredThe column name; the handle in every later call
promptstringWhat to find for this column, one value, on top of the enrichment's task prompt; on a pinned column, what to call the tool on. Leave sources out; the agent records the URLs it cited on the cell's sources.
output_schemaobjectA JSON Schema for the cell value (help with output_schema). Leave it out: the type is inferred from the prompt, caveats included. Send one only for an enum, a list, or an object. Does not apply to a pinned column.
A tool name from GET /tools. The row agent makes one call of it per row — arguments it works out from the row, the known values, and its research; the column prompt says what to call it on — and the call's result is the cell. null unpins. help with pinned_columns.
toolsarray of stringThe tools the row agent may call (names from GET /tools)
budget_credits_per_rownumberThe most the row agent may spend on one row. Moves by 1.5 per output column added or removed unless budget_locked
budget_lockedbooleantrue when the budget stays as set through column changes
versionintegerGoes up by one on every column change; a cell filled under an older version reads stale
created_atstring date-timeupdated_atstring date-time400The request is malformed or names a conflicting parameter combination
errorobjectrequiredAttributes
typestringrequiredMachine-readable error type (bad_request, not_found, forbidden, feature_not_enabled, duplicate_run_key, insufficient_credits, credit_cap_exceeded, validation, not_implemented, ...)
messagestringrequiredHuman-readable explanation
detailsanyOptional extra context (e.g. per-field validation errors)
credit_detailCreditDetailThe estimate made at kickoff next to what has been charged so far. estimate is null for runs
started before estimates existed. Estimates and credit errors add credits_remaining and sufficient_credits.
Attributes
estimateone ofrequiredAttributes
CreditEstimate model →
minimumnumberrequiredLeast the run can cost
expectednumberLikely cost from past runs of the same config; absent without history
typicalobjectRecent p25–p75 settled range for builds of this size; absent without a dataset build estimate
Attributes
lownumberrequiredhighnumberrequiredmaximumnumberrequiredMost the run can cost
upfrontnumberCredits taken at kickoff when charged_upfront is true; 0 when the charge accrues as work completes
charged_upfrontbooleanrequiredtrue when a deposit is taken at kickoff (dataset builds, extractions); false when credits accrue as work completes
- null
credits_usednumberrequiredCredits charged so far (same value as the top-level credits_used)
credits_remainingnumberAccount balance. Only on estimates and credit errors.
sufficient_creditsbooleanWhether the balance covers estimate.maximum. Only on estimates and credit errors.
401Missing or invalid API key (request_status body — see the AuthError schema)
request_statusstringmessagestringerror_typestring403The API key's account may not access this resource or endpoint (forbidden), or the account has not migrated to Datasets yet (feature_not_enabled — open Datasets in the app and click "Migrate to Datasets")
errorobjectrequiredAttributes
typestringrequiredMachine-readable error type (bad_request, not_found, forbidden, feature_not_enabled, duplicate_run_key, insufficient_credits, credit_cap_exceeded, validation, not_implemented, ...)
messagestringrequiredHuman-readable explanation
detailsanyOptional extra context (e.g. per-field validation errors)
credit_detailCreditDetailThe estimate made at kickoff next to what has been charged so far. estimate is null for runs
started before estimates existed. Estimates and credit errors add credits_remaining and sufficient_credits.
Attributes
estimateone ofrequiredAttributes
CreditEstimate model →
minimumnumberrequiredLeast the run can cost
expectednumberLikely cost from past runs of the same config; absent without history
typicalobjectRecent p25–p75 settled range for builds of this size; absent without a dataset build estimate
Attributes
lownumberrequiredhighnumberrequiredmaximumnumberrequiredMost the run can cost
upfrontnumberCredits taken at kickoff when charged_upfront is true; 0 when the charge accrues as work completes
charged_upfrontbooleanrequiredtrue when a deposit is taken at kickoff (dataset builds, extractions); false when credits accrue as work completes
- null
credits_usednumberrequiredCredits charged so far (same value as the top-level credits_used)
credits_remainingnumberAccount balance. Only on estimates and credit errors.
sufficient_creditsbooleanWhether the balance covers estimate.maximum. Only on estimates and credit errors.
404No resource with that id on this account
errorobjectrequiredAttributes
typestringrequiredMachine-readable error type (bad_request, not_found, forbidden, feature_not_enabled, duplicate_run_key, insufficient_credits, credit_cap_exceeded, validation, not_implemented, ...)
messagestringrequiredHuman-readable explanation
detailsanyOptional extra context (e.g. per-field validation errors)
credit_detailCreditDetailThe estimate made at kickoff next to what has been charged so far. estimate is null for runs
started before estimates existed. Estimates and credit errors add credits_remaining and sufficient_credits.
Attributes
estimateone ofrequiredAttributes
CreditEstimate model →
minimumnumberrequiredLeast the run can cost
expectednumberLikely cost from past runs of the same config; absent without history
typicalobjectRecent p25–p75 settled range for builds of this size; absent without a dataset build estimate
Attributes
lownumberrequiredhighnumberrequiredmaximumnumberrequiredMost the run can cost
upfrontnumberCredits taken at kickoff when charged_upfront is true; 0 when the charge accrues as work completes
charged_upfrontbooleanrequiredtrue when a deposit is taken at kickoff (dataset builds, extractions); false when credits accrue as work completes
- null
credits_usednumberrequiredCredits charged so far (same value as the top-level credits_used)
credits_remainingnumberAccount balance. Only on estimates and credit errors.
sufficient_creditsbooleanWhether the balance covers estimate.maximum. Only on estimates and credit errors.
409Duplicate run_key or a run already in progress
errorobjectrequiredAttributes
typestringrequiredMachine-readable error type (bad_request, not_found, forbidden, feature_not_enabled, duplicate_run_key, insufficient_credits, credit_cap_exceeded, validation, not_implemented, ...)
messagestringrequiredHuman-readable explanation
detailsanyOptional extra context (e.g. per-field validation errors)
credit_detailCreditDetailThe estimate made at kickoff next to what has been charged so far. estimate is null for runs
started before estimates existed. Estimates and credit errors add credits_remaining and sufficient_credits.
Attributes
estimateone ofrequiredAttributes
CreditEstimate model →
minimumnumberrequiredLeast the run can cost
expectednumberLikely cost from past runs of the same config; absent without history
typicalobjectRecent p25–p75 settled range for builds of this size; absent without a dataset build estimate
Attributes
lownumberrequiredhighnumberrequiredmaximumnumberrequiredMost the run can cost
upfrontnumberCredits taken at kickoff when charged_upfront is true; 0 when the charge accrues as work completes
charged_upfrontbooleanrequiredtrue when a deposit is taken at kickoff (dataset builds, extractions); false when credits accrue as work completes
- null
credits_usednumberrequiredCredits charged so far (same value as the top-level credits_used)
credits_remainingnumberAccount balance. Only on estimates and credit errors.
sufficient_creditsbooleanWhether the balance covers estimate.maximum. Only on estimates and credit errors.
422The request is valid but can't be executed (e.g. insufficient_credits, credit_cap_exceeded when max_credits is set, validation failure)
errorobjectrequiredAttributes
typestringrequiredMachine-readable error type (bad_request, not_found, forbidden, feature_not_enabled, duplicate_run_key, insufficient_credits, credit_cap_exceeded, validation, not_implemented, ...)
messagestringrequiredHuman-readable explanation
detailsanyOptional extra context (e.g. per-field validation errors)
credit_detailCreditDetailThe estimate made at kickoff next to what has been charged so far. estimate is null for runs
started before estimates existed. Estimates and credit errors add credits_remaining and sufficient_credits.
Attributes
estimateone ofrequiredAttributes
CreditEstimate model →
minimumnumberrequiredLeast the run can cost
expectednumberLikely cost from past runs of the same config; absent without history
typicalobjectRecent p25–p75 settled range for builds of this size; absent without a dataset build estimate
Attributes
lownumberrequiredhighnumberrequiredmaximumnumberrequiredMost the run can cost
upfrontnumberCredits taken at kickoff when charged_upfront is true; 0 when the charge accrues as work completes
charged_upfrontbooleanrequiredtrue when a deposit is taken at kickoff (dataset builds, extractions); false when credits accrue as work completes
- null
credits_usednumberrequiredCredits charged so far (same value as the top-level credits_used)
credits_remainingnumberAccount balance. Only on estimates and credit errors.
sufficient_creditsbooleanWhether the balance covers estimate.maximum. Only on estimates and credit errors.