Edit PDF Bookmark using C# REST API

This article describes how to edit PDF bookmark using C# REST API. You will learn to develop a PDF bookmark editor online using C# REST Interface with the help of a .NET-based Cloud SDK. Various criteria are discussed to select the target bookmark for editing.

Prerequisite

Steps to Edit Bookmark PDF Online using C# RESTful Service

  1. For request authentication, create the PdfApi client with your client key and client ID
  2. Set local input/output file paths and the remote folder/file name used in the Cloud storage
  3. Upload the local PDF to the remote storage for editing the bookmarks in it
  4. Fetch the collection of bookmarks from the document
  5. Select the target bookmark using the title
  6. Parse the self-link of the bookmark to build the bookmarkPath for the API
  7. Set desired title, style, destination page and view settings for the new Bookmark
  8. Execute the PutBookmarkAsync request, verify the success, then download and save the updated PDF locally

These steps summarize the process to create an online PDF bookmark editor using C# Low Code API. Set up the PDF Cloud API authentication, set paths for the local and remote files, upload the PDF file to the Cloud Storage, and retrieve the bookmarks collection for selecting the target bookmark. Finally, build the bookmark with new updated values, send the call to the API, and download the resultant PDF file.

Code to Edit PDF Bookmarks Online using C# .NET-based API

This code demonstrates the development of an online PDF bookmark editor. For updating a bookmark, you need to create the path as /bookmarks/bookmark/{bookmarkPath} for accessing and updating it. The title of the bookmark is used for the selection of the target bookmark; you may use the page number, page display or action for searching.

This article has taught us the process to update a bookmark. To add a new bookmark, refer to the article Add bookmark to PDF using C# REST API.