page_properties = {
'type': {"id": "page"},
'title': title,
"space": {"id": "593470626", "key": "Information Security"},
'ancestors': [{ 'id': parent_id }],
'body': { 'storage': { 'value': body, 'representation': 'storage' } }
}
payload = json.dumps(page_properties)
headers = { 'Content-Type': 'application/json' }
auth = (username, password)
response = requests.post(api_url, data=payload, headers=headers, auth=auth)
if response.status_code == 200:
print('New child page created successfully.')