Having trouble updating page content via confluence REST API

I am trying to update the content of a page on confluence using the Update content endpoint PUT /wiki/rest/api/content/{id}; via forge but receiving Response: 400 Bad Request. Details are below.

In the documentation (https://developer.atlassian.com/cloud/confluence/rest/api-group-content/#api-wiki-rest-api-content-id-put) under the body parameters category and under body, it says that if you are unsure about the format of the body you can look it up via get content endpoint. So did I.

"body": {
        "storage": {
            "value": "<p>abcd</p>",
            "representation": "storage",
            "embeddedContent": [],
            "_expandable": {
            }
        },
        "editor": {
            "value": "<p>abcd</p>",
            "representation": "editor",
            "_expandable": {
            }
        },
        "view": {
            "value": "<p>abcd</p>",
            "representation": "view",
            "_expandable": {
            }
        }, 

and so on

But in the update content documentation there is a difference in the “representation” part. Here is an excerpt from the actual documentation example;

"body": {
    "view": {
      "value": "<string>",
      "representation": "view"
    },
    "export_view": {
      "value": "<string>",
      "representation": "view"
    },
    "styled_view": {
      "value": "<string>",
      "representation": "view"
    },
    "storage": {
      "value": "<string>",
      "representation": "storage"
    },
    "editor": {
      "value": "<string>",
      "representation": "view" 

and so on
In all parts except storage, the representation is set to “view”, unlike what we saw in the get content output. This is the first part I am confused about.

When I tried using the update content endpoint with the format i got from the get content endpoint, I got the error below.

Response: 500 Internal Server Error
INFO    20:40:48.049  67721ed93daae8fe  {
  statusCode: 500,
  message: 'org.codehaus.jackson.JsonParseException: Illegal unquoted character ((CTRL-CHAR, code 10)): has to be escaped using backslash to be included in string value\n' +
    ' at [Source: com.atlassian.plugins.rest.common.limitrequest.jersey.LimitingRequestFilter$1@675334fd; line: 18, column: 88]'
}

After some tinkering I realized that if I remove the “styled_view”: {… part, the error is not the same anymore. The new error I got is below.

Response: 400 Bad Request
INFO    20:45:13.681  d676d1834d54488c  {
  statusCode: 400,
  data: {
    authorized: true,
    valid: false,
    errors: [ [Object] ],
    successful: false
  },
  message: 'com.atlassian.confluence.api.service.exceptions.BadRequestException: Could not update Content of type : class com.atlassian.confluence.pages.Page with id 1277953'
}

I am more than eager to provide additional information. How can I make it work?