You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1. Create a RestConfig instance: `RestConfig restConfig = new RestConfig();`
45
-
2. Use RestConfig#setBaseUrl to tell JDA what your Rest URI is (this NEEDS to include /api/<apiver>, because it's the api **base** url for all requests): `restConfig.setBaseUrl("https://{REPLACE HERE WITH YOUR API SERVER URL}/api/v9");`
53
+
2. Use RestConfig#setBaseUrl to tell JDA what your Rest URI is: `restConfig.setBaseUrl("https://api.{{ project.domain }}/api/v9");`
46
54
3. Create another class, and extend ConcurrentSessionController, e.g. `public class SpacebarSessionController extends ConcurrentSessionController`
47
55
4. Override the ConcurrentSessionController#getGateway method:
48
56
```java
49
-
@NotNull
50
-
@Override
51
-
publicString getGateway() {
52
-
return"wss://{REPLACE HERE WITH YOUR GATEWAY SERVER URL}/?encoding=json&v=9&compress=zlib-stream";
53
-
}
57
+
@NotNull
58
+
@Override
59
+
publicString getGateway() {
60
+
return"wss://{REPLACE HERE WITH YOUR GATEWAY SERVER URL}/?encoding=json&v=9&compress=zlib-stream";
61
+
}
54
62
```
55
63
5. Finally, configure JDA to use your RestConfig & SpacebarSessionController, like this:
0 commit comments