SAP Help Home SAP Intelligent RPA Help Portal SAP Intelligent RPA Community

Module - OneNote

Set of activities to be used to interact with MS OneNote.

Activities

Get Notebook List

Get a list of notebooks for the user that is currently authenticated


Technical Name Type Minimal Agent Version
notebook.listNotebooks asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
filter Array.<irpa_365online.notebookFilter> optional Items to filter

Output Parameters:

Name Type Description
notebooks Array.<irpa_365online.notebook> List of Notebooks

Errors:

Error Class Package Description
RequestError irpa_core Error getting the notebook list.


Create Notebook

Create a notebook


Technical Name Type Minimal Agent Version
notebook.createNotebook asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
name string mandatory Name of Notebook

Output Parameters:

Name Type Description
notebook irpa_365online.notebook Information About Notebook

Errors:

Error Class Package Description
RequestError irpa_core Error while creating a notebook.


Delete Notebook

Delete a Notebook


Technical Name Type Minimal Agent Version
notebook.deleteNotebook asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
notebookId string mandatory ID of the Notebook

Errors:

Error Class Package Description
RequestError irpa_core Error while deleting the notebook.
NotFound irpa_core Notebook not found.


Get Section List

Get a list of sections of a notebook


Technical Name Type Minimal Agent Version
section.listSections asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
notebookId string optional ID of the Notebook
filter Array.<irpa_365online.sectionFilter> optional Items to filter

Output Parameters:

Name Type Description
sections Array.<irpa_365online.section> List of sections

Errors:

Error Class Package Description
RequestError irpa_core Error getting the section list.


Create Section

Create a section


Technical Name Type Minimal Agent Version
section.createSection asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
notebookId string mandatory ID of the Notebook
name string mandatory Name of Section

Output Parameters:

Name Type Description
sectionId string ID of section

Errors:

Error Class Package Description
RequestError irpa_core Error while creating a section.


Get Page List

Get a list of pages of a section


Technical Name Type Minimal Agent Version
page.listPages asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
sectionId string optional ID of Section
filter Array.<irpa_365online.pageFilter> optional Items to filter

Output Parameters:

Name Type Description
pages Array.<irpa_365online.page> List of Pages

Errors:

Error Class Package Description
RequestError irpa_core Error getting the page list.


Get Page Content

Get Page Content


Technical Name Type Minimal Agent Version
page.getPageContent asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
pageId string mandatory Page ID
format irpa_365online.enums.oneNote.format optional html Page Format

Output Parameters:

Name Type Description
content string Raw Content of Page

Errors:

Error Class Package Description
RequestError irpa_core Error while getting the page.
NotFound irpa_core Notebook not found.


Create Page

Create a Page


Technical Name Type Minimal Agent Version
page.createPage asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
sectionId string mandatory ID of Section
title string mandatory Page Title
body string mandatory Body of Page
attachments Array.<irpa_365online.oneNoteAttachment> optional Page Attachments

Output Parameters:

Name Type Description
page irpa_365online.page Page Information

Sample Code:

await irpa_365online.onenote.page.createPage("1-d6b516d3-a15a-4a66-bbbd-7c43eae51338", "MyPage", '<div><span>beforebegin</span><div data-id="target"><span>afterbegin</span><p>Some text</p><span>beforeend</span></div><span>afterend</span></div>');

Note:

Microsoft can modify the provided body. For example if you add an id to a tag it will become a data-id (and erase any data-id, if present).

Note:

To upload an image and display it use "<img src='name:imageBlock1' alt='an image on the page' />" with "imageBlock1" the name of the referenced image in the attachments.

Note:

To upload a file and display it use "<object data-attachment="FileName.pdf" data="name:fileBlock1" type="application/pdf" />" with "fileBlock1" the name of the referenced file in the attachments.

Note:

The following types of file are supported "application/pdf", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", "application/vnd.openxmlformats-officedocument.presentationml.presentation", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "image/png", "image/jpeg", "image/gif", "audio/wav", "video/mp4", "application/msword" and "application/mspowerpoint", "application/excel".

Errors:

Error Class Package Description
RequestError irpa_core Error while creating a page.


Update Page

Update a page with given HTML tags to update the target. And attachments to upload.


Technical Name Type Minimal Agent Version
page.updatePage asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
pageId string mandatory Page ID
appendElements Array.<irpa_365online.oneNoteUpdateElement> mandatory Elements to be updated in the page body
attachments Array.<irpa_365online.oneNoteAttachment> optional Page Attachments

Errors:

Error Class Package Description
RequestError irpa_core Error while creating a page.


Delete Page

Delete a Page


Technical Name Type Minimal Agent Version
page.deletePage asynchronous WIN-3.24, MAC-3.24, CLOUD-3.34

Input Parameters:

Name Type Attributes Default Description
pageId string mandatory Page ID

Errors:

Error Class Package Description
RequestError irpa_core Error while deleting the page.
NotFound irpa_core Ressource not found.