Atlassian Confluence REST API Making request and keep the session (Eng)

In this topic I’ll show you how to make session to Atlassian Confluence with python requests and keep it in memory. Based on: http://docs.python-requests.org/en/master/ https://docs.python.org/2.7/library/json.html https://confluence.atlassian.com/confkb/confluence-url-list-317949394.html https://developer.atlassian.com/confdev/confluence-server-rest-api/confluence-rest-api-examples For someone who found this topic by “search machines”, there is some more detailed how-to – probably can help you: https://www.guru99.com/restful-web-services.html Python requests module: At first you should know and understand how requests works, basically. Check how your confluence works: Next – you should know the point, where is your Confluence server make authorisation, in my situation it lies here (this is looks cozy, but this is our company’s way. In your situation it can be simpler, as documented in links above): https://docs.YOURCOMPANYMAME.com/docs/dashboard.action?os_username=configipedia_service_account&os_password=PASSWORD Then you compose a request like:

This will executeShort Read more…

Atlassian Confluence REST API Logic structure (Eng)

Read this article after you know how to make REST API request to Atlassian Confluence! This topic will show you some part of internal scheme of Confluence API and hierarchy. Based on: https://developer.atlassian.com/confdev/confluence-server-rest-api/confluence-rest-api-examples https://confluence.atlassian.com/doc/confluence-wiki-markup-251003035.html https://docs.atlassian.com/atlassian-confluence/REST/latest/ So, looking on the Confluence docs all this scheme looks like well-structured logical system, but it has some difficulties, just as for me. Before you POST of GET something will be better if you make a probing GET request to see the whole structure in your organisation. In this example you will get those arguments:

  # Confluence stats space_page = This is the page of your Confluence account. Check if was created, sometimes new account have no space. space_root_page = This is theShort Read more…

Atlassian Confluence REST API (Eng)

How to work with REST API Confluence. Rus What is this topic about? API structure in Atlassian Confluence. Objects, files, relations etc. How to compose API request in Atlassian Confluence? How to open session and hold it on – ! Making headers with requests and – json ! Send a file or file content with wiki markup on Confluence – ! Interpret server answers. What is the difference between “representation“:”storage” and “markup” in Atlassian Confluence? Macro and markup About “Atlassian Confluence” you can read here. https://www.atlassian.com/software/confluence https://wikipedia.org/wiki/Confluence Who need this? For those, who wants to automate documentation stage of DEV. For those, who wants to understand how does python requests working? For my own – to not forger this lesson. When IShort Read more…

Atlassian Confluence REST API

Как работать с REST API Confluence. Eng  О чем этот топик? Структура API в системе Confluence. Объекты, файлы, статьи, родство и проч. Формирование запроса(адреса) в API Confluence Открытие сессии и удержание её в памяти – ! Формирование заголовков при помощи модуля requests и – json ! Отправка файла, содержания файла, вики-разметки на сервер Confluence – ! Интерпретируем ответы от сервера Что такое Atlassian Confluence вы можете почитать здесь: https://www.atlassian.com/software/confluence https://ru.wikipedia.org/wiki/Confluence Кому нужен этот топик? Тем мученикам, которые хотят автоматизировать процесс написания/отправки документации в разработке. Тем мученикам, которые как и я, по очевидным примерам не могут разобраться в модуле requests касаемо работе с заголовками. Мне самому, чтобы не забыть свой “подвиг” и все его наработки, так как память имеет свойство “стираться”.   В тот момент, когдаShort Read more…

I’m WORDPRESS I’ve made REST look at me!

Thanks, for UTF-8 support!

Read more…