Button API V2 Docs! (support mode)


Simple accounting.

Account Creation (disabled)

A GET request to /api/v2/createaccount/ with password and name as params should create an account. Here's an example:

    GET /api/v2/createaccount/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b> HTTP/1.1
    >>> Account created successfully!

If an account exists, it should return Account exists!
If something went wrong on the server side, it should return Something went wrong!
- Go there

Account Login Check

A GET request to /api/v2/login/ with password and name as params should check if the account exists and if the password is correct. Here's an example:

    GET /api/v2/login/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b> HTTP/1.1
    >>> Logged in!

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return Something went wrong!
- Go there

Delete Account

A GET request to /api/v2/deleteaccount/ with password and name as params should delete your account. Here's an example:

    GET /api/v2/deleteaccount/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b> HTTP/1.1
    >>> Deleted account!

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return Something went wrong!
- Go there

Change Password

A GET request to /api/v2/changepassword/ with password, newpassword, and name as params should update your password. Here's an example:

    GET /api/v2/changepassword/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b>&newpassword=<b>Your new chosen password</b> HTTP/1.1
    >>> Changed password!

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return Something went wrong!
- Go there

Sending Messages

Send Messages with Account

A GET request to /api/v2/sendmessagewithaccount/ with password, content, and name as params should return the response code. Here's an example:

    GET /api/v2/sendmessagewithaccount/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b>&content=<b>Content of the message</b> HTTP/1.1
    >>> 204 *status code*

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return Something went wrong!
- Go there

Send Messages with Account (Custom Hook)

A GET request to /api/v2/sendmessagewithaccountcustomhook/ with password, content, name, and hook as params should return the response code. Here's an example:

    GET /api/v2/sendmessagewithaccountcustomhook/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b>&content=<b>Content of the message</b>&  hook=<b>Hook url</b> HTTP/1.1
    >>> 204 *status code*

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return - Go there

Reading messages

Read Messages without Clearing

A GET request to /api/v2/readmessageswithaccount/ with password and name as params should return the waiting messages. Here's an example:

    GET /api/v2/readmessageswithaccount/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b> HTTP/1.1
    >>>*Messages split by carriage returns and newlines*

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return Something went wrong!
- Go there

Read Messages with Clearing

A GET request to /api/v2/readmessageswithaccountandclear/ with password and name as params should return the waiting messages. Here's an example:

    GET /api/v2/readmessageswithaccountandclear/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b> HTTP/1.1
    >>> *Messages split by lines*

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return Something went wrong!
- Go there

Read Waiting Message Count

A GET request to /api/v2/readmessagecount/ with password and name as params should return the waiting messages number. Here's an example:

    GET /api/v2/readmessagecount/?password=<b>Your chosen password</b>&name=<b>Your chosen name</b> HTTP/1.1
    >>> *Number of messages waiting*

If the password is wrong, it should return Wrong password!
If an account does not exist, it should return Account does not exist!
If something went wrong on the server side, it should return Something went wrong!
- Go there


Discord Bot Docs

Change Bot Status

A GET request to /api/v2/changestatus/ with status as a param should change the status and return Changed!. Here's an example:

    GET /api/v2/changestatus/?status=<b>[online,offline,idle,dnd,invisible]</b> HTTP/1.1
    >>> Changed!

If something went wrong on the server side, it should return Something went wrong!
- Go there

Change Bot Game

A GET request to /api/v2/changegame/ with game as a param should change the game and return Changed!. Here's an example:

    GET /api/v2/changegame/?game=<b>name to change to</b> HTTP/1.1
    >>> Changed!

If something went wrong on the server side, it should return Something went wrong!
- Go there