The Basics

cmd=listWikis

Parameters
None.
Example
https://kakapo.fogbugz.com/api.asp?cmd=listWikis&token=04t6193822pekbba09nt74ninuihk2
Returns
A list of wikis for the account.  

cmd=newWiki

Parameters
Requires s (the title of the new wiki) and sTagLineHTML. 
Example
https://kakapo.fogbugz.com/api.asp?cmd=newWiki&s=Customer%20Service&sTagLineHTML=Kakapo%20resources%20for%20our%20customer-facing%20staff.&token=04t6193822pekbba09nt74ninuihk2
Returns
Details of the newly created wiki. 

cmd=editWiki

Parameters
Requires ixWiki, and optionally takes s, sTagLineHTML, and ixTemplate.
Example
https://kakapo.fogbugz.com/api.asp?api.asp?cmd=editWiki&ixWiki=2&sTagLineHTML=Kakapo%20resources%20for%20our%20sales%20and%20support%20team%20members.&ixTemplate=3&token=04t6193822pekbba09nt74ninuihk2
Returns
Updated wiki data.

cmd=deleteWiki

Parameters
Requires ixWiki.
Example
https://kakapo.fogbugz.com/api.asp?api.asp?cmd=deleteWiki&ixWiki=2&token=04t6193822pekbba09nt74ninuihk2
Returns
Empty response.

cmd=undeleteWiki

Parameters
Requires ixWiki.
Example
https://kakapo.fogbugz.com/api.asp?api.asp?cmd=undeleteWiki&ixWiki=2&token=04t6193822pekbba09nt74ninuihk2
Returns
Empty response.

cmd=wikiFileUpload

Parameters
Requires ixWiki and File1 (multipart/form-data).
Example
Note: This command must be POSTed and encoded as multipart/form-data. Please see our FogBugzPy example, below.
Returns
ixAttachment value for new attachment.

List Wikis (cmd=listWikis)

URL
https://kakapo.fogbugz.com/api.asp?cmd=listWikis&token=04t6193822pekbba09nt74ninuihk2
fogbugz.py
fb.listWikis()

Successful Response

For the sake of space, the sample below includes only one user. This command will return the details for all users between the <person> tags.

XML
<response>
  <wikis>
    <wiki>
      <ixWiki>1</ixWiki>
      <sWiki>
        <![CDATA[ Customer Service ]]>
      </sWiki>
      <sTagLineHTML>
        <![CDATA[ Kakapo resources for our customer-facing staff. ]]>
      </sTagLineHTML>
      <ixWikiPageRoot>1</ixWikiPageRoot>
      <ixTemplate>1</ixTemplate>
      <fDeleted>false</fDeleted>
    </wiki>
  </wikis>
</response>

Create a New Wiki (cmd=newWiki)

URL
https://kakapo.fogbugz.com/api.asp?cmd=newWiki&s=Customer%20Service&sTagLineHTML=Kakapo%20resources%20for%20our%20customer-facing%20staff.&token=04t6193822pekbba09nt74ninuihk2
fogbugz.py
fb.newWiki(s="Customer Service", 
				sTagLineHTML="Kakapo resources for our customer-facing staff.")

Parameters

Requires s (the title of the new wiki) and sTagLineHTML.

Possible Responses

Successful Response
XML
<response>
  <wiki>
    <ixWiki>3</ixWiki>
    <ixWikiPageRoot>10</ixWikiPageRoot>
    <ixTemplate>2</ixTemplate>
  </wiki>
</response>
Wiki Already Exists
XML
<response>
  <error code="16">
    <![CDATA[ A Wiki already exists with this name. ]]>
  </error>
  <wiki>
<ixWiki>-1</ixWiki>
    <ixWikiPageRoot>-1</ixWikiPageRoot>
    <ixTemplate>3</ixTemplate>
  </wiki>
</response>

Edit an Existing Wiki (cmd=editWiki)

URL
https://kakapo.fogbugz.com/api.asp?api.asp?cmd=editWiki&ixWiki=2&sTagLineHTML=Kakapo%20resources%20for%20our%20sales%20and%20support%20team%20members.&ixTemplate=3&token=04t6193822pekbba09nt74ninuihk2
fogbugz.py
fb.editWiki(ixWiki=1,
        sTagLineHTML="Kakapo resources for our sales and support staff.",
        isTemplate=3
        )

Parameters

Requires ixWiki, and optionally takes s, sTagLineHTML, and ixTemplate.

Possible Responses

Successful Response

The call will return the updated information for the wiki. The example below reflects the changes made by the example code above.

XML
<response>
  <wiki>
    <sTagLineHTML>
      <![CDATA[
        Kakapo resources for our sales and support team members.
      ]]>
    </sTagLineHTML>
    <ixTemplate>3</ixTemplate>
  </wiki>
</response>
No Such Wiki
XML
<response>
  <error code="4">
    <![CDATA[ Argument is required:ixWiki ]]>
  </error>
</response>

Delete a Wiki (cmd=deleteWiki)

URL
https://kakapo.fogbugz.com/api.asp?api.asp?cmd=deleteWiki&ixWiki=2&token=04t6193822pekbba09nt74ninuihk2
fogbugz.py
fb.deleteWiki(ixWiki=2)

Successful Response

XML
</response>

Undelete a Wiki (cmd=undeleteWiki)

URL
https://kakapo.fogbugz.com/api.asp?api.asp?cmd=undeleteWiki&ixWiki=2&token=04t6193822pekbba09nt74ninuihk2
fogbugz.py
fb.undeleteWiki(ixWiki=2)

Successful Response

XML
</response>

Upload a file to a Wiki (cmd=wikiFileUpload)

URL
Note: This command must be POSTed and encoded as multipart/form-data. Please see our FogBugzPy example.
fogbugz.py
file = open('/Users/kakapoadmin/Pictures/silly cats.jpg', 'r')
fb.wikiFileUpload(ixWiki=1, Files={ 'silly cats.jpg': f})

Successful Response

XML
<response>
  <upfiles>
    <upfile>
      <ixattachment>9</ixattachment>
    </upfile>
  </upfiles>
</response>