phacility/phabricator · error · ConduitException
API Method "%s" does not define these parameters: %s.
Error message
API Method "%s" does not define these parameters: %s.
What it means
ConduitCall performs strict parameter checking: any key in the request params that the method did not declare in defineParamTypes() is rejected with this message listing the offending names. This surfaces typos and client/server API drift immediately instead of silently ignoring unknown parameters.
Source
Thrown at src/applications/conduit/call/ConduitCall.php:37
$this->method = $method;
$this->handler = $this->buildMethodHandler($method);
$param_types = $this->handler->getParamTypes();
foreach ($param_types as $key => $spec) {
if (ConduitAPIMethod::getParameterMetadataKey($key) !== null) {
throw new ConduitException(
pht(
'API Method "%s" defines a disallowed parameter, "%s". This '.
'parameter name is reserved.',
$method,
$key));
}
}
$invalid_params = array_diff_key($params, $param_types);
if ($invalid_params) {
throw new ConduitException(
pht(
'API Method "%s" does not define these parameters: %s.',
$method,
"'".implode("', '", array_keys($invalid_params))."'"));
}
$this->request = new ConduitAPIRequest($params, $strictly_typed);
}
public function getAPIRequest() {
return $this->request;
}
public function setUser(PhabricatorUser $user) {
$this->user = $user;
return $this;
}
View on GitHub (pinned to 5720a38cfe)
Solutions
- Remove or correct the extra parameters to match the method's defineParamTypes() (check the method class or conduit.query docs on the instance)
- Align client and server versions — upgrade the Phabricator instance or pin the client to the deployed API
- When writing wrappers, validate param keys against ConduitAPIMethod::getConduitMethod($name)->getParamTypes() before issuing the call
Example fix
// before
$params = array('project' => 'PHID-PROJ-xyz');
$conduit->callMethod('project.query', $params);
// after
$params = array('projects' => array('PHID-PROJ-xyz'));
$conduit->callMethod('project.query', $params); Defensive patterns
Strategy: validation
Validate before calling
$method = ConduitAPIMethod::getConduitMethod($method_name);
$param_types = $method->getParamTypes();
$unknown = array_diff_key($params, $param_types);
if ($unknown) {
throw new Exception(
'Unknown parameters for '.$method_name.': '.implode(', ', array_keys($unknown)));
}
$response = id(new ConduitCall($method_name, $params))->execute(); Try / catch
try {
$result = $conduit->callMethod($method_name, $params);
} catch (ConduitException $ex) {
if (strpos($ex->getMessage(), 'does not define these parameters') !== false) {
// Strip the listed params and retry once with only declared keys.
}
} Prevention
- Pin client scripts to the API of the deployed server version; check conduit.query for the live spec
- Diff your params against the method's defineParamTypes() during development
- Treat parameter renames across upgrades as breaking changes and update all callers in the same change
When it happens
Trigger: Calling a conduit method with a misspelled or extra parameter, e.g. passing 'project' to a method that declares 'projects', or passing 'limit' to a method with no such parameter; A newer client (or arc/libphutil wrapper) using parameters an older server build does not define yet
Common situations: Script drift after a Phabricator upgrade renames parameters; copy-pasted conduit calls between methods; typed client stubs generated from newer API docs than the deployed server.
Related errors
- API Method "%s" defines a disallowed parameter, "%s". This p
- Conduit API method "%s" does not exist.
- When creating a new Drydock blueprint via the Conduit API, y
- ERR-UNKNOWN-TYPE
- ERR_BAD_TASK
AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21).
Data as JSON: /api/errors/87f4ceae89c8fda2.
Report an issue: GitHub.