eyaltoledano/claude-task-master · error · TaskMasterError
MISSING_CONFIGURATION
MISSING_CONFIGURATION
Error message
Organization ID is required for export. Use "tm context org" to select one.
What it means
exportTasks() resolves the target organization from options.orgId or the current context (context?.orgId). If neither is set, it throws TaskMasterError with code MISSING_CONFIGURATION because the export API needs to know which organization owns the brief. The message points to `tm context org` as the remediation command.
Source
Thrown at packages/tm-core/src/modules/integration/services/export.service.ts:399
const isAuthenticated = await this.authManager.hasValidSession();
// Validate authentication
if (!isAuthenticated) {
throw new TaskMasterError(
'Authentication required for export',
ERROR_CODES.AUTHENTICATION_ERROR
);
}
// Get current context
const context = await this.authManager.getContext();
// Determine org and brief IDs
const orgId = options.orgId || context?.orgId;
const briefId = options.briefId || context?.briefId;
// Validate we have necessary IDs
if (!orgId) {
throw new TaskMasterError(
'Organization ID is required for export. Use "tm context org" to select one.',
ERROR_CODES.MISSING_CONFIGURATION
);
}
if (!briefId) {
throw new TaskMasterError(
'Brief ID is required for export. Use "tm context brief" or provide --brief flag.',
ERROR_CODES.MISSING_CONFIGURATION
);
}
// Get tasks from the specified or active tag
const activeTag = this.configManager.getActiveTag();
const tag = options.tag || activeTag;
// Always read tasks from local file storage for export
// (we're exporting local tasks to a remote brief)View on GitHub (pinned to c0c98d367c)
Solutions
- Run `tm context org` to select an organization, then retry the export.
- Pass orgId explicitly: exportTasks({ orgId: '<org-id>', briefId, ... }).
- Verify the current context (`tm context show`) — it may have been reset after logout or config deletion.
- If exporting via a brief ID/URL, use exportFromBriefInput() which resolves the org from the brief automatically.
Example fix
// before
await exportService.exportTasks({ briefId: 'b-123' });
// after
await exportService.exportTasks({ orgId: 'org-456', briefId: 'b-123' });
// or select once via CLI: tm context org Defensive patterns
Strategy: validation
Validate before calling
const context = await tmCore.context.get();
const orgId = options.orgId ?? context?.orgId;
if (!orgId) {
throw new Error('No org selected — run `tm context org` or pass orgId');
}
await exportService.exportTasks({ ...options, orgId }); Try / catch
try {
await exportService.exportTasks(options);
} catch (e) {
if (e instanceof TaskMasterError && e.code === ERROR_CODES.MISSING_CONFIGURATION) {
console.error(e.message); // includes the `tm context org` remediation hint
return;
}
throw e;
} Prevention
- Select org and brief once per workspace with `tm context org` / `tm context brief`
- Inspect context with `tm context show` before scripted exports
- Pass orgId/briefId explicitly in scripts instead of relying on ambient context
- Prefer exportFromBriefInput() when you have a brief ID/URL, since it resolves the org automatically
When it happens
Trigger: Calling exportTasks() without options.orgId while the current context has no orgId selected (never ran `tm context org`, or context was cleared/reset).
Common situations: New machine or fresh clone where context was never initialized; multiple organizations and none selected; scripting the export programmatically and omitting orgId in the options object.
Related errors
- Export API endpoint not configured. Please set TM_PUBLIC_BAS
- NO_ORGANIZATIONS
- MISSING_ACCOUNT
- Model "${model}" is not available for provider "${this.getNa
- AUTHENTICATION_ERROR
AI-assisted analysis of eyaltoledano/claude-task-master@c0c98d367c (2026-08-29).
Data as JSON: /api/errors/a33e7c718748dc28.
Report an issue: GitHub.