confluence-cli 1.27.2 → 1.27.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -65,7 +65,7 @@ export CONFLUENCE_API_TOKEN="your-scoped-token"
65
65
  ```
66
66
 
67
67
  Required classic scopes for scoped tokens:
68
- - Read-only: `read:confluence-content.all`, `read:confluence-space.summary`, `search:confluence`
68
+ - Read-only: `read:confluence-content.all`, `read:confluence-content.summary`, `read:confluence-space.summary`, `search:confluence`
69
69
  - Write: add `write:confluence-content`, `write:confluence-file`, `write:confluence-space`
70
70
  - Attachments: `readonly:content.attachment:confluence` (download), `write:confluence-file` (upload)
71
71
 
package/README.md CHANGED
@@ -200,6 +200,7 @@ When creating a scoped token, select the following [classic scopes](https://deve
200
200
  | Scope | Required for |
201
201
  |-------|-------------|
202
202
  | `read:confluence-content.all` | Reading pages and blog posts (`read`, `info`) |
203
+ | `read:confluence-content.summary` | Reading content summaries and metadata (`read`, `info`) |
203
204
  | `read:confluence-space.summary` | Listing spaces (`spaces`) |
204
205
  | `search:confluence` | Searching content (`search`) |
205
206
  | `readonly:content.attachment:confluence` | Downloading attachments (`attachments --download`) |
@@ -207,7 +208,7 @@ When creating a scoped token, select the following [classic scopes](https://deve
207
208
  | `write:confluence-file` | Uploading attachments (`attachments --upload`) |
208
209
  | `write:confluence-space` | Managing spaces |
209
210
 
210
- For **read-only** usage, select at minimum: `read:confluence-content.all`, `read:confluence-space.summary`, and `search:confluence`.
211
+ For **read-only** usage, select at minimum: `read:confluence-content.all`, `read:confluence-content.summary`, `read:confluence-space.summary`, and `search:confluence`.
211
212
 
212
213
  **On-premise / Data Center:** Use your Confluence username and password for basic authentication.
213
214
 
@@ -57,7 +57,7 @@ class ConfluenceClient {
57
57
  if (this.isScopedToken()) {
58
58
  hints.push(
59
59
  'You are using a scoped API token (api.atlassian.com). Please verify:',
60
- ' - Your token has the required scopes (e.g., read:confluence-content.all, read:confluence-space.summary)',
60
+ ' - Your token has the required scopes (e.g., read:confluence-content.all, read:confluence-content.summary, read:confluence-space.summary)',
61
61
  ' - Your Cloud ID in the API path is correct',
62
62
  ' - Your email matches the account that created the token',
63
63
  'See: https://developer.atlassian.com/cloud/confluence/scopes-for-oauth-2-3LO-and-forge-apps/'
@@ -1293,12 +1293,12 @@ class ConfluenceClient {
1293
1293
 
1294
1294
  // Convert Confluence code macros to markdown
1295
1295
  markdown = markdown.replace(/<ac:structured-macro ac:name="code"[^>]*>[\s\S]*?<ac:parameter ac:name="language">([^<]*)<\/ac:parameter>[\s\S]*?<ac:plain-text-body><!\[CDATA\[([\s\S]*?)\]\]><\/ac:plain-text-body>[\s\S]*?<\/ac:structured-macro>/g, (_, lang, code) => {
1296
- return `\`\`\`${lang}\n${code}\n\`\`\``;
1296
+ return `\n\`\`\`${lang}\n${code}\n\`\`\`\n`;
1297
1297
  });
1298
1298
 
1299
1299
  // Convert code macros without language parameter
1300
1300
  markdown = markdown.replace(/<ac:structured-macro ac:name="code"[^>]*>[\s\S]*?<ac:plain-text-body><!\[CDATA\[([\s\S]*?)\]\]><\/ac:plain-text-body>[\s\S]*?<\/ac:structured-macro>/g, (_, code) => {
1301
- return `\`\`\`\n${code}\n\`\`\``;
1301
+ return `\n\`\`\`\n${code}\n\`\`\`\n`;
1302
1302
  });
1303
1303
 
1304
1304
  // Convert info macro to admonition
@@ -1515,8 +1515,8 @@ class ConfluenceClient {
1515
1515
  });
1516
1516
 
1517
1517
  // Convert paragraphs (after lists and tables)
1518
- markdown = markdown.replace(/<p>(.*?)<\/p>/g, (_, content) => {
1519
- return content.trim() + '\n';
1518
+ markdown = markdown.replace(/<p>(.*?)<\/p>/gs, (_, content) => {
1519
+ return '\n' + content.trim() + '\n';
1520
1520
  });
1521
1521
 
1522
1522
  // Convert line breaks
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "confluence-cli",
3
- "version": "1.27.2",
3
+ "version": "1.27.4",
4
4
  "description": "A command-line interface for Atlassian Confluence with page creation and editing capabilities",
5
5
  "main": "index.js",
6
6
  "bin": {