- 
          
- 
                Notifications
    You must be signed in to change notification settings 
- Fork 22
API Reference
This is an API reference for Pepperminty Wiki. It details all the different kinds of requests that you can make, how you should make them, and what you can expect to get back.
The Pepperminty Wiki is based on the action GET parameter. The following headings detail each action that Pepperminty Wiki currently understands.
This is the default action. If you don't specify an action, this action will be performed. Displays the content of a page.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| page | GET | Yes | (set in the settings) | The name of the page you want to view. | 
| printable | GET | Yes | no | Determines whether the output is 'printable'. May be set to either yesorno.yescauses Pepperminty Wiki to miss out the top navbar and add a special footer to the bottom of the page. | 
Presents you with a page that you can use to edit your wiki.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| page | GET | Yes | (set in the settings) | The name of the page you want to edit. | 
| newpage | GET | Yes | (not set) | Whether a new page is being created. All this does is change the title of the page and blank the edit box. | 
Saves the edits you made on the page outputted by the edit action.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| page | GET | Yes | (set in the settings) | The name of the page you want to save to. | 
| content | POST | No | n/a | The new content of the page to save to disk. | 
Lists all the pages on your wiki.
(no parameters may be used with this action)
Deletes a page. You must be logged into an admin account in order to use this action.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| page | GET | Yes | (set in the settings) | The name of the page you want to delete. | 
| delete | GET | Yes | no | Set this to yesif you really want to delete a page. Otherwise, you get a confirmation page with a link that includesdelete=yes. | 
Moves a page from one name to another. You must be logged into an admin account to use this action.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| page | GET | Yes | (set in the settings) | The name of the page you want to move. | 
| new_name | GET | Yes | n/a | The new name for the page you want to move. Omitting this causes Pepperminty WIki to output a page that asks you for the new name. | 
Gives you some help on how to use Pepperminty Wiki. Includes some basic instructions on how to navigate and edit, and also a quick markdown editing reference.
(no parameters may be used with this action)
Updates your wiki. Requesting this action without any parameters returns a webpage that you can use to update your wiki.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| do | GET | yes | n/a | Set this to trueto actually go ahead and update the wiki. | 
| secret | GET | yes | n/a | Set this to the wiki's site secret in order to be allowed to update it. | 
Gives you a page that you can use to login.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| failed | GET | Yes | no | Setting failedtoyescauses a message to appear above the input boxes saying something along the lines of "Login Failed". | 
Actually performs the login. Uses PHP sessions to remember whether you logged in or not. Once you are logged in, Pepperminty Wiki will remember you for 30 days, or until you log out.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| user | POST | No | n/a | Your username. | 
| pass | POST | No | n/a | Your password. | 
Causes Pepperminty Wiki to delete your session information, logging you out.
(no parameters may be used with this action)
Gives you a page containing the Pepperminty Wiki credits.
(no parameters may be used with this action)
Utility action that hashes a given string so you can set your password more easily. It is strongly recommended that if you use this action, you do so in an incognito or private browsing window so that your password is not present in your browsing history.
| Parameter | Method | Optional? | Default Value | Meaning | 
|---|---|---|---|---|
| string | GET | No | n/a | The string you want to hash. |