-
-
Notifications
You must be signed in to change notification settings - Fork 147
Listing Websites Agreement
In the past, listing websites like BetterDocs gained a bad reputation due to bad practices; specifically listing plugins and themes without the owner consent, and listing unsafe and/or dangerous plugins.
Instead of following other client mods communities and blocking those websites on Discord, we're deciding to go with the following agreement: By listing any plugin or theme made for Powercord, the Powercord Staff will treat your website as described here regarding content posted on your website. We want to ensure the best experience for everyone, including listing websites. The following rules only apply for Powercord-related material.
Note: to simplify, we'll refer to plugins and themes as "Products".
Product developers still own the software, and they have the right to not let other websites list them. Consent is not implicit, which means that if a developer doesn't explicitly give permission to have their product listed on a/your website, no consent is granted.
We created our guidelines to ensure Powercord's ecosystem says as awesome as possible, and we expect listing websites to enforce this. You can read the Guidelines here.
You're not allowed to display a different name, description or image preview from what the product developer explicitly specified in their manifest. You are however allowed to add complementary data.
Original product data also includes the verified tickmark. We don't require listing websites to mention it, but if they do (or have their own verification program), please discern whether the verified tickmark comes from your website or Powercord. It is prohibited to mark a plugin as verified by Powercord if it isn't.
You can find official assets here. Please keep all assets in their original shape, ratio and color.
Try talking to the website owner(s). If things don't work out, talk to someone from the Powercord staff in our Discord server. We'll attempt to contact the website owner(s) and do what we can to protect your work.
Either a user or someone from the Powercord staff will try to get in touch first. We'll discuss about the issues people are encountering and try to find solutions to them.
We decided we won't deal with those kind of issues between users and listing websites. Users have the right to do whatever they want. Powercord itself won't attempt blocking your website if it's compliant. We'll keep a neutral position.
Note: As of now, most of this part is a work-in-progress. Most of the features we talk about are under development.
As part of the agreement, we worked on features designed for listing websites developers. This is what we currently have available:
- A listing endpoint. Our API can provide up to date data about plugins, with consent checking already handled for you.
-
New RPC events. With RPC, you can make Powercord gain focus and do actions, to form deep integrations with Powercord. Note: Any abuse might result in Powercord blocking your access to our RPC events.
- Fetch installed plugins. Useful to know which plugins the user has installed, to make the buttons in your interface look different for example. Note: you are not allowed to collect this data. It is meant for client-side fetching and usage only.
- Open install page. Let Discord take window focus and open the product install page. This won't install the plugin, the user will have to explicitly click the Install button.
- Open settings. If a product has a settings panel, Discord will take window focus and open the settings page for this specific product. You can for example replace the "Install" button by "Open Settings" in your interface.
Base URL: https://powercord.dev/api/v2
GET /plugins/listing?page=<page>
[
{
"_id": "ObjectId",
"id": "Plugin ID",
"name": "Plugin Name",
"description": "Plugin Description",
"author": "Plugin author",
"verified": false,
"tags": [ "Tweaks", "UX" ],
"votes": {
"up": 666,
"down": 3
}
}
]
GET /themes/listing?page=<page>
[
{
"_id": "ObjectId",
"id": "Theme ID",
"name": "Theme Name",
"description": "Theme Description",
"author": "Theme author",
"verified": false,
"previews": [],
"tags": [ "Customizable", "Dark" ],
"votes": {
"up": 666,
"down": 3
}
}
]
To make things easier for developers, we made a small PowercordRPC JavaScript library, available here under license MIT. The code is documented so you should be able to figure it out. Note: the library uses modern JS syntax, so you might have to reprocess it to get it working on older browsers.
Initializing an instance:
// I'm p sure you could've figured it out by yourself
const instance = new PowercordRPC();
Once your instance is initialized, you can check if there is an available RPC server by calling isRPCAvailable
.
console.log(await instance.isRPCAvailable()); // true if a RPC server is found, false otherwise.
Calling this method will also populate the metadata
property, with the following structure:
{
powercord: {
upstream: 'powercord-org/powercord',
revision: 'revision hash',
branch: 'v2'
},
plugins: [ 'plugin-ids' ],
themes: [ 'theme-ids' ]
}
Here is a list of available methods:
-
isRPCAvailable(): Promise<boolean>
- Checks if Powercord is installed and started.
-
installProduct(type: String, id: String): Promise<object>
- Opens Powercord's store page for a given product.
- Type must be either
plugin
ortheme.
-
openProductSettings(type: String, id: String): Promise<object>
- Opens settings page for a given product.
- Type must be either
plugin
ortheme
.
-
sendRaw(event: String, args: object): Promise<object>
- Sends a message to Discord's RPC server.
You can find documentation about connecting to the RPC server on the Discord Developer Portal. The only things that differ are:
- The Client ID will always be "powercord"
- You don't need to authenticate
- You won't have access to any of Discord's RPC features. Only Powercord commands will work.
Instructions on how to send commands can also be found on the Developer Portal.
To identify a Powercord-decorated RPC server, you can call http://127.0.0.1:port/powercord
. This will return a 401 if not decorated, or a 200 if handled by Powercord. You'll also notice the code
attribute is overridden. It'll always be 69 when handled by Powercord.
GET http://127.0.0.1:port/powercord
{
"code": 69,
"powercord": {
"upstream": "powercord-org/powercord",
"revision": "revision hash",
"branch": "v2"
},
"plugins": [ "plugin-ids" ],
"themes": [ "theme-ids" ]
}
{
"cmd": "POWERCORD_OPEN_STORE",
"args": { "type": "plugin", "id": "channel-typing" }
}
{
"cmd": "POWERCORD_OPEN_SETTINGS",
"args": { "type": "theme", "id": "Customa-Discord" }
}