[Confluence]: Method to obtain page content

See original GitHub issue

It would be nice to have a method to obtain the body of a given page. You could then update a page, making modifications to its body. This method will have as an input the page_id and return the page body content formatted as html. I will soon submit a PR to fix this issue.

(If I am not mistaken, the current update_or_create() method replaces the content of the page.)

Kind regards, Argyris

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
gonchikcommented, Jun 4, 2019

@kierun Well, you can do in different ways i.e. old_content = confluence.get_page_by_id(123).expand='storage.view' body = (((result.get('body') or {}).get('view') or {}).get('value') or {}) body.replace("oldvalue", "new_value") confluence.updade_page(old_content.get('id'), body=body)

https://github.com/atlassian-api/atlassian-python-api/blob/master/atlassian/confluence.py#L505 https://github.com/atlassian-api/atlassian-python-api/blob/master/atlassian/confluence.py#L541

0reactions
gonchikcommented, Aug 7, 2019
Read more comments on GitHub >

github_iconTop Results From Across the Web

how to get full content body (html) using confluence REST API
If you want the page ID, go to Tools --> Page Information on the particular page you are interested in. You should see...
Read more >
Get Content of a Confluence page with Apps Script and parse ...
Is this the best approach to get Confluence page content in order to parse it?, for example using the option: expand=body.storage or on ......
Read more >
Confluence module - Atlassian Python API's documentation!
Check page exists # type of the page, 'page' or 'blogpost'. ... Get the page (content) properties confluence.get_page_properties(page_id) # Get page ...
Read more >
Confluence REST API: Features, Types, Examples - Hevo Data
How to call a Confluence REST API? ... Using the Product Fetch API from the @forge/api package, you'll get the comments on a...
Read more >
How to collect from Confluence - Onna Help Center
Integration Features · HTML content of the page · Comments on pages · Attachments for the page · Labels for attachments and pages...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found