Skip to content

Instantly share code, notes, and snippets.

@Fabricio20
Last active June 21, 2017 22:51
Show Gist options
  • Save Fabricio20/8d570b18d4313a595cf29e82c5cca339 to your computer and use it in GitHub Desktop.
Save Fabricio20/8d570b18d4313a595cf29e82c5cca339 to your computer and use it in GitHub Desktop.
DiscordBans RESTful Responses

PATH: /users/{id}
METHOD: GET
Description: Returns a user profile (with all info).

{
    "heat": 10,
    "names": [
        {
            "name": "LewdBot",
            "time": {
                "text": "2017-06-22 07:04:53.0",
                "millis": 1498082693000
            }
        }
    ],
    "name": "LewdBot",
    "bans": [
        {
            "guild": {
                "trusted": false,
                "name": "LewdBot-guild",
                "id": 141555945586163712
            },
            "reason": "Testing",
            "status": "TRUSTED",
            "timestamp": {
                "text": "2017-06-22 06:29:00.0",
                "millis": 1498080540000
            }
        }
    ],
    "id": 119482224713269248,
    "avatar": "https://cdn.discordapp.com/119482224713269248/c3d388d7fe60ed44f8ae7dfd3a06cbd3.png"
}

**PATH**: `/users/{id}/bans`
**METHOD**: `GET`
**Description**: Returns a ban history for a user.
```json [ { "guild": { "trusted": false, "name": "LewdBot-guild", "id": 141555945586163712 }, "reason": "Testing", "status": "TRUSTED", "timestamp": { "text": "2017-06-22 06:29:00.0", "millis": 1498080540000 } } ] ```
**PATH**: `/users/{id}/names`
**METHOD**: `GET`
**Description**: Returns a name history for a user.
```json [ { "name": "LewdBot", "time": { "text": "2017-06-22 07:04:53.0", "millis": 1498082693000 } } ] ```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment