Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update and rename RadarBotList.ts to Radarcord.ts #741

Merged
merged 3 commits into from
Mar 1, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions src/Interface/ListIndex.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import FatesList from './Lists/FatesList'
import InfinityBotList from './Lists/InfinityBotList'
import Listcord from './Lists/Listcord'
import MotionBotList from './Lists/MotionBotList'
import RadarBotList from './Lists/RadarBotList'
import Radarcord from './Lists/Radarcord'
import SpaceBotsList from './Lists/SpaceBotsList'
import TopCord from './Lists/TopCord'
import TopGG from './Lists/TopGG'
Expand Down Expand Up @@ -89,9 +89,11 @@ export const serviceList = {
'motiondevelopment': MotionBotList,
'motionbotlist': MotionBotList,
'motiondevelopment.top': MotionBotList,
'radar': RadarBotList,
'radarbots': RadarBotList,
'radarbotdirectory.xyz': RadarBotList,
'radar': Radarcord,
'radarbots': Radarcord,
'radarbotdirectory.xyz': Radarcord,
'radarcord': Radarcord,
'radarcord.net': Radarcord,
'spacebotslist': SpaceBotsList,
'space-bot-list.xyz': SpaceBotsList,
'topcord': TopCord,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,33 +2,39 @@ import { Service, ServicePostOptions } from '../Service'
import { Util, IDResolvable } from '../../Utils/Util'

/**
* Represents the Radar Bot Directory service.
* @see https://docs.radarbotdirectory.xyz/
* Represents the Radarcord service (formerly Radar Bot Directory).
* @see https://docs.radarcord.net/
*/
export default class RadarBotDirectory extends Service {
export default class Radarcord extends Service {
/** The values that can be used to select the service. */
static get aliases() {
return ['radar', 'radarbots', 'radarbotdirectory.xyz']
return [
'radar',
'radarbots',
'radarbotdirectory.xyz',
'radarcord',
'radarcord.net'
]
}

/** The logo URL. */
static get logoURL() {
return 'https://theoverlook.xyz/Images/RBD/botlistlogo.png'
return 'https://radarcord.net/static/logo.png'
}

/** Service's name. */
static get serviceName() {
return 'Radar Bot Directory'
return 'Radarcord'
}

/** The website URL. */
static get websiteURL() {
return 'https://radarbotdirectory.xyz'
return 'https://radarcord.net/'
}

/** The base URL of the service's API. */
static get baseURL() {
return 'https://radarbotdirectory.xyz/api'
return 'https://api.radarcord.net'
}

/**
Expand All @@ -38,7 +44,7 @@ export default class RadarBotDirectory extends Service {
static post(options: ServicePostOptions) {
const { token, clientID, serverCount, shard } = options
return super._post({
method: 'patch',
method: 'post',
url: `/bot/${Util.resolveID(clientID)}/stats/`,
headers: { Authorization: token },
data: shard
Expand Down Expand Up @@ -74,4 +80,12 @@ export default class RadarBotDirectory extends Service {
}
)
}

/**
* Gets the bot's reviews on this service.
* @param id The bot's ID
*/
getBotReviews(id: IDResolvable) {
return this._request({ url: `/bot/${Util.resolveID(id)}/reviews` })
}
}
Loading