Updating a wiki
Added by IBM contributorIBM | Edited by IBM contributorPaul Bastide on December 21, 2015
Rate this article 1 starsRate this article 2 starsRate this article 3 starsRate this article 4 starsRate this article 5 stars

To update a wiki, send a replacement wiki definition entry document in Atom format to the existing wiki's edit web address.

All existing wiki information will be replaced with the new data. To avoid deleting all existing data, retrieve any data you want to retain first, and send it back with this request. For example, if you want to add a new tag to a wiki definition entry, retrieve the existing tags, and send them all back with the new tag in the update request.

To update a wiki, complete the following steps:


1. Retrieve the existing wiki definition using a GET request. See Retrieving a wiki for more details.
2. Edit the wiki definition Atom document to include the information that you want to change.
3. Send the updated document using a PUT request to the following URI:

You can use one or more of these input parameters with the PUT request. Separate multiple parameters with an ampersand (&).

Input
Method URI Description
PUT /wikis/{auth}/api/wiki/{wiki-label}/entry Determine the resource URI in either of the following ways:
The value of the href attribute of the <link rel="edit"> or <link rel="self"> elements in the wiki definition Atom entry of the wiki, which is available from the available wikis collection or my wikis feed.
You can construct the URI using the following syntax: /{auth}/api/wiki/{wiki-label}/entry where {wiki-label} is the value of the <td:label> element in the wiki definition Atom entry document.
Content Type: application/atom+xml
Name Type Optional Description
wiki-label
string No You can construct the URI using the following syntax: /basic/api/wiki/{wiki-label}/entry where {wiki-label} is the value of the <td:label> element in the wiki definition Atom entry document.
The label is also the Community Uuid
auth
enumerated No The authorization protocol being used by your application to access Connections Cloud.
Authorized values:
  • basic
  • oauth
Name Type Optional Description
removeTag
string Yes Removes the tag that is specified as a string from the wiki definition document. Specify this parameter multiple times to remove multiple tags or leave the value empty to remove all tags.
tag
string Yes Adds a tag that is specified as a string to the wiki. Specify this parameter multiple times to add multiple tags. If the tag parameter and removeTag parameter are both specified and pass the same tag string, the removeTag parameter is given higher priority.
Name Type Optional Description
Authorization
enumerated No The authentication mechanism selected by your application to access the API.
Basic is the Base64 encoding of the IBM Connections Cloud username and password: Base64(username:password). For example, Base64(twatson@us.ibm.com:password).
Bearer is the oauth 2.0 access token that is generated when the user grants your application access to IBM Connections Cloud services.
See the reference topic "OAuth 2.0 APIs for web server flow" for more information.
Authorized values:
  • bearer
  • basic
Output
Code Description
200
OK. Indicates that the request was received successfully.
401
Unauthorized. Returned when no authenticated user or no userid, email, or key parameter are provided on the request.
404
Page was not found