More rewrites

This commit is contained in:
hydrabolt
2015-10-31 18:03:35 +00:00
parent beab032811
commit 6064888f21
26 changed files with 737 additions and 24 deletions

View File

@@ -2,7 +2,6 @@
var API = "https://discordapp.com/api";
var Endpoints = {
// general endpoints
LOGIN: API + "/auth/login",
LOGOUT: API + "/auth/logout",
@@ -11,6 +10,9 @@ var Endpoints = {
USER_CHANNELS: function USER_CHANNELS(userID) {
return API + "/users/" + userID + "/channels";
},
AVATAR: function AVATAR(userID, avatar) {
return API + "/users/" + userID + "/avatars/" + avatar + ".jpg";
},
// servers
SERVERS: API + "/guilds",
@@ -62,8 +64,12 @@ var Endpoints = {
CHANNEL_PERMISSIONS: function CHANNEL_PERMISSIONS(channelID) {
return Endpoints.CHANNEL(channelID) + "/permissions";
}
};
var PacketType = {
READY: "READY"
};
exports.API_ENDPOINT = API;
exports.Endpoints = Endpoints;
exports.Endpoints = Endpoints;
exports.PacketType = PacketType;