It's possible it's trying to add a widget to the page template, not to the page itself. You can add "widgets" to a page template (which when you create a NEW page, it will add that widget in there, but won't effect existing pages).
Does your page template itself have the widget being added by your API?
Otherwise like i said, so far i've only had success with building the DocumentWebPart's via xml and saving it to the document value.
Saving pages can be complex with things like Publish/Unpublish/Versions, checking/checkout, etc.
I would start by changing a document field (not widget) and make sure you have your document saving correct, then move onto trying to add the DocumentWebParts.