mirror of
https://github.com/Sea-Haven-Industries/open-swe.git
synced 2026-09-30 22:03:14 +00:00
24 lines
695 B
Python
24 lines
695 B
Python
|
|
from typing import Any
|
||
|
|
|
||
|
|
from ..utils.confluence import create_page
|
||
|
|
|
||
|
|
|
||
|
|
async def confluence_create_page(
|
||
|
|
space_key: str,
|
||
|
|
title: str,
|
||
|
|
body: str,
|
||
|
|
parent_id: str | None = None,
|
||
|
|
) -> dict[str, Any]:
|
||
|
|
"""Create a new Confluence page.
|
||
|
|
|
||
|
|
Args:
|
||
|
|
space_key: The Confluence space key to create the page in (e.g. IT).
|
||
|
|
title: The page title.
|
||
|
|
body: Plain-text page body (blank-line-separated blocks become paragraphs).
|
||
|
|
parent_id: Optional parent page id to nest this page under.
|
||
|
|
|
||
|
|
Returns:
|
||
|
|
Dictionary with 'success' (bool) and 'page' (id, title, url), or 'error'.
|
||
|
|
"""
|
||
|
|
return await create_page(space_key, title, body, parent_id=parent_id)
|