Skip to main content

Interface: RoadmapPluginOptions

Plugin options interface

These options can be configured in config/plugins/robojs/roadmap.* files to customize the roadmap plugin behavior.

Examples​

Basic configuration with Jira provider:

// config/plugins/robojs/roadmap.ts
export default {
provider: {
type: 'jira',
options: {
url: process.env.JIRA_URL,
email: process.env.JIRA_EMAIL,
apiToken: process.env.JIRA_API_TOKEN,
jql: '(issuetype = Epic AND (labels NOT IN ("Private") OR labels IS EMPTY)) OR labels IN ("Public")'
}
}
}

Advanced configuration with pre-instantiated provider:

import { JiraProvider } from '@robojs/roadmap'

const customProvider = new JiraProvider({
type: 'jira',
options: {
url: 'https://company.atlassian.net',
email: '[email protected]',
apiToken: 'secret-token',
jql: 'project = MYPROJECT'
}
})

export default {
provider: customProvider,
autoSync: true,
autocompleteCacheTtl: 600000 // 10 minutes
}

Properties​

autocompleteCacheTtl?​

optional autocompleteCacheTtl: number;

Time-to-live in milliseconds for autocomplete cache entries (issue types, columns, labels).

Controls how long autocomplete suggestions are cached before being refreshed from the provider. Lower values provide fresher data but increase API calls; higher values reduce API load but may show stale data.

Default Value​

300000 (5 minutes)

Remarks​

This setting affects all autocomplete handlers in roadmap commands. The cache is per-guild and shared across all autocomplete options.

Example​

export default {
autocompleteCacheTtl: 600000 // 10 minutes
}

autoSync?​

optional autoSync: boolean;

Whether to automatically sync on startup.

Default Value​

false

Remarks​

Currently not implemented - reserved for future enhancement


ephemeralCommands?​

optional ephemeralCommands: boolean;

Whether roadmap command responses (e.g., /roadmap add, /roadmap edit) should be ephemeral.

When true, command replies are only visible to the invoking user. When false, results are posted visibly in the channel so project teams can see card creation and edit activity.

Default Value​

true

Example​

export default {
ephemeralCommands: false // share add/edit results with the whole channel
}

provider?​

optional provider: ProviderConfig | RoadmapProvider<ProviderConfig>;

Provider configuration or pre-instantiated provider instance.

Can be either:

  • A ProviderConfig object with type and options
  • A pre-instantiated RoadmapProvider instance (for advanced customization)

If not provided, falls back to environment variables (JIRA_URL, JIRA_EMAIL, JIRA_API_TOKEN).


syncInterval?​

optional syncInterval: number;

Interval in milliseconds for automatic syncing.

Remarks​

Reserved for future implementation


threadTitleTemplate?​

optional threadTitleTemplate: string;

Default template string for formatting Discord thread titles.

Supports placeholders: {id} for the card ID and {title} for the card title. This serves as a default that can be overridden per-guild via guild settings. If not provided, thread titles will use just the card title.

Default Value​

undefined (uses just the title)

Example​

export default {
threadTitleTemplate: "[{id}] {title}" // Default format for all guilds
}