how can I access a paragraph object in writer?

Where can I find documentation of the various object models?

There is the documentation of LibreOffice:

And about style templates for paragraphs and headings:

If you have detailed questions, feel free to contact. You can edit your question or leave a comment.