Update a wiki page
Update a wiki page programmatically.See Authenticating requests for information about how to authenticate the request.
To update a wiki page...
- Retrieve the existing wiki page Atom document. See Retrieve a wiki page for more details.
- Edit the wiki page Atom document to include the information you want to change.
- Send the updated Atom document using the following request:
Table 1. Atom API GET request details
Method URI Input representation PUT Determine the resource URI in either of the following ways:
- Value of the href attribute of the rel="edit" <link> element for each wiki page Atom entry, which are provided in the wiki pages collection.
- You can construct the URI using the following syntax: /basic/api/wiki/{wiki-label}/page/{page-label}/entry where {wiki-label} is the value of the <td:label> element in the wiki definition Atom entry document and {page-label} is the value of the <td:label> element in the wiki page Atom document.
wiki page
You can use one or more of these input parameters with the PUT request. Separate multiple parameters with an ampersand (&).
Table 2. Input parameters
Parameter Description createVersion Specify "true" to create a new version of the page or "false" overwrite the current version. draft Specify "true" to mark the page as a draft, or "false" otherwise. includeNotification Specify "true" to request the metadata on notification (edit or comment added) to be included for the document entry. sendNotification Specify "true" if you want to send edit or comment notifications.
Input
Provide an updated wiki page Atom entry document.Note: The content type of the Atom entry document must be application/atom+xml.
Output
None.Returned HTTP headers
HTTP/1.1 200 OK
Indicates that the wiki page entry was successfully updated. If an error occurs, this header contains one of the error codes.
- HTTP/1.1 401 Unauthorized
- HTTP/1.1 404 Not Found
Parent topic
Work with wiki pagesRelated reference
Wiki page content
});