We can also create notes. Let's add a new item to our "Web Security Checklist".
Add a new note
1234567
reptor.api.notes.create_note(title="Authorizations",parent_id="c052da53-0b2e-401e-973d-3c1c92255b77",checked=False,text="Check for authorization issues.")# Out: Note(title="Authorizations", id="dda820d2-57d7-4ff8-b4ac-99d102a5c8bf", parent="c052da53-0b2e-401e-973d-3c1c92255b77")
Use the write_note method to append text to your note, or to update properties like the title, checked or icon_emoji.
Update the note
123456
reptor.api.notes.write_note(id="dda820d2-57d7-4ff8-b4ac-99d102a5c8bf",title="Authorizations (Done)",text="Done by John Doe.",checked=True,)
We can also use the library to upload files or images.
Upload files and images
1 2 3 4 5 6 7 8 9101112
reptor.api.notes.upload_file(note_id="dda820d2-57d7-4ff8-b4ac-99d102a5c8bf",file=open("evidence.tar.gz","rb"),filename="evidence.tar.gz",caption="Evidence for authorization testing.",)reptor.api.notes.upload_file(note_id="dda820d2-57d7-4ff8-b4ac-99d102a5c8bf",file=open("reptor.png","rb"),filename="reptor.png",caption="Self Portrait.",)
Let's download the note as PDF and save it to a file.