Skip to Content
Atlassian Confluenceacp2mdv1.0.0Configuration

Configuration

This configuration model applies to Atlassian Confluence Cloud only. acp2md does not support Confluence Server or Confluence Data Center.

acp2md applies configuration from four sources, in order of increasing priority:

PrioritySourceExample
1 (lowest)Built-in defaults
2Config file(see below)
3Environment variablesACP2MD_CONFLUENCE_DOMAIN
4 (highest)CLI flags--log-level debug

In practice, this means you can keep stable workstation settings in the config file, inject secrets through environment variables, and override behavior per run with CLI flags.

Config file location

The default config file location depends on your operating system. Run:

acp2md config where

Recommended use:

  • keep non-secret defaults in the config file
  • inject secrets through environment variables when possible
  • reserve CLI flags for per-run overrides and debugging

To create a config file with all defaults filled in:

acp2md config create

~/Library/Application Support/acp2md/

          • config.yaml
          • license.bin

Full config file reference

# Confluence connection confluence: domain: mycompany.atlassian.net # Your Confluence instance domain username: you@example.com # Your Atlassian account email api_token: YOUR_API_TOKEN # API token from id.atlassian.com # HTTP client behaviour http: client: max_retries: 3 # Number of retry attempts on failure base_timeout: 10ms # Initial request timeout max_timeout: 100ms # Maximum request timeout after retries proxy: "" # HTTP proxy URL (e.g. http://proxy.corp:8080) # Logging log: level: info # debug | info | warn | error format: text # text | json file: "" # Path to log file; stdout | stderr | /path/to/file.log # Each run truncates the file # Debug mode debug: enabled: false # Enables verbose debug output dir: debug # Directory for debug artefacts # Image handling image: cache_dir: "" # Directory to cache downloaded images max_size_bytes: 10485760 # Maximum size per image (default 10 MB)

Environment variables

Every config key can be set with an environment variable by prefixing ACP2MD_ and replacing . with _:

Environment variableConfig keyDescription
ACP2MD_CONFLUENCE_DOMAINconfluence.domainConfluence instance domain
ACP2MD_CONFLUENCE_USERNAMEconfluence.usernameAtlassian account email
ACP2MD_CONFLUENCE_API_TOKENconfluence.api_tokenConfluence API token
ACP2MD_HTTP_CLIENT_MAX_RETRIEShttp.client.max_retriesRetry count
ACP2MD_HTTP_CLIENT_BASE_TIMEOUThttp.client.base_timeoutBase request timeout
ACP2MD_HTTP_CLIENT_MAX_TIMEOUThttp.client.max_timeoutMax request timeout
ACP2MD_HTTP_CLIENT_PROXYhttp.client.proxyHTTP proxy URL
ACP2MD_LOG_LEVELlog.levelLog level
ACP2MD_LOG_FORMATlog.formatLog format
ACP2MD_LOG_FILElog.fileLog output file
ACP2MD_DEBUG_ENABLEDdebug.enabledEnable debug mode
ACP2MD_IMAGE_CACHE_DIRimage.cache_dirImage cache directory
ACP2MD_IMAGE_MAX_SIZE_BYTESimage.max_size_bytesMax image size

Global CLI flags

These flags are available on every command:

FlagDefaultDescription
--config-file(see config where)Path to a custom config file
--log-levelinfoLog verbosity: debug, info, warn, error
--log-formattextLog format: text or json
--log-file(discard)Write logs to stdout, stderr, or a file path
--debugfalseShorthand for --log-level=debug
--image-cache-dir(none)Directory for caching downloaded images
--image-max-size-bytes10485760Max size in bytes for cached images

Secure configuration practices

  • Prefer environment variables for API tokens on shared or managed systems.
  • Use config create to establish the expected file shape before editing manually.
  • Run doctor after configuration changes so license, credentials, and connectivity are validated together.
  • Use a custom --config-file when you need isolated test and production configurations on the same machine.

Behind a corporate proxy

acp2md config set http.client.proxy "http://proxy.corp.example.com:8080"

With authentication:

acp2md config set http.client.proxy "http://user:password@proxy.corp.example.com:8080"

Avoid storing proxy credentials in the config file if it is shared or version-controlled. Use the ACP2MD_HTTP_CLIENT_PROXY environment variable instead.

Logging to a file

acp2md page convert by-id 123456 --log-file app.log

Each run truncates the log file, so it always contains only the output of the most recent run. Use stdout or stderr to stream logs to your terminal:

acp2md page convert by-id 123456 --log-file stdout
Last updated on