Commit Graph

515 Commits

Author SHA1 Message Date
NaN
257f246d1d Format the project with 'dotnet format' (#2551)
* Sync and Re-Format

* Fix Title string.

* Fix indentation.
2023-02-13 18:45:59 +01:00
Misha133
bb056dfec0 [Feature] Follow news channels (#2590)
* initial commit

* Apply suggestions from code review

---------

Co-authored-by: Casmir <68127614+csmir@users.noreply.github.com>
2023-02-09 16:45:04 +01:00
Misha133
b085621ca6 [Feature] Thread user member & thread members pagination (#2580)
* initial commit

* return & update old method

* mark old method as obsolete
2023-02-09 12:37:26 +01:00
Misha133
75f3c91f9a IIntegrationChannel & create webhooks in forums (#2582) 2023-02-09 12:36:35 +01:00
Misha133
0998285f83 [Feature] Rework Thread property of a message (#2579)
* move `Thread` property to `IUserMessage` & add one to `SocketUserMessage`

* get channel from cache instead of creating new object

* move the property back to IMessage
2023-02-06 18:35:09 +01:00
Misha133
e3da96fbf5 [Feature] Expose GetCurrentUser method & missing current user API methods (#2574)
* add stuff

* forgot to push

* docs

* Update DiscordRestClient.cs

* Apply suggestions from code review

* Update toc.yml

---------

Co-authored-by: Casmir <68127614+csmir@users.noreply.github.com>
2023-02-06 17:20:54 +01:00
Misha133
1e21a6ed4a [Feature] Add missing VoiceChannel properties (#2573)
* add missing properties

* forgot about `MockedVoiceChannel`
2023-02-06 13:25:59 +01:00
Misha133
91e208474d [Feature] add Thread property to RestMessage (#2575) 2023-01-27 21:16:12 +01:00
Misha133
37d868f934 [Feature] Application Role Connections Metadata support (#2530)
* models & internal methods

* moar stuff

* working `Get` & `ModifyRoleConnectionMetadata`

* comments & dots

* get & modify user's role connection

* Update src/Discord.Net.Core/Entities/ApplicationRoleConnection/RoleConnection.cs

* Update src/Discord.Net.Core/Entities/ApplicationRoleConnection/RoleConnection.cs

Co-authored-by: Casmir <68127614+csmir@users.noreply.github.com>
2023-01-26 01:20:58 +01:00
Misha133
7d8d6ec1a6 [Feature] Add support for Guild Member Flags (#2571)
* implement `GuildUserFlags`

Co-authored-by: Casmir <68127614+csmir@users.noreply.github.com>
2023-01-23 19:44:34 +01:00
Misha133
94996e7331 Remove outdated checks (#2561) 2023-01-21 11:54:25 +01:00
SaculRennorb
493f604bb1 [Bugfix] fixed an NRE when event was changed from in channel to external or vice versa (#2483)
* fixed an issue when event was cahnged from in channel to external or vice versa

* simplidied location field
2023-01-21 11:53:58 +01:00
Christopher Bonnell
e71faf7138 Repurpose reason field (#2540) 2023-01-21 11:53:23 +01:00
Misha133
a3ee8555c6 [Feature] Add new message types & error codes (#2562)
* Add new message types & error codes

* add role subscription system channel flags and message property
2023-01-21 11:50:57 +01:00
Christopher Bonnell
f224eb0523 Resolve inconsistencies (#2542)
This commit resolves inconsistencies in missing null coalescent operators in regards to clearing components using null.
2023-01-21 11:49:35 +01:00
Misha133
7c535b952a [Feature] add missing invite guild properties & welcome screen support (#2510)
* added models

* working getter for welcome screen

* <see langword="null"/>

* more changes

* modify welcome screen support

* fix some typos & remove `using` added by VS

* Working-ish state

* Resolve some reviews

* change access modifier

* forgot to add docs

* revert to InviteGuild & extend it

* resolve some reviews

* Apply suggestions from code review

Co-authored-by: Quin Lynch <49576606+quinchs@users.noreply.github.com>

Co-authored-by: Cenk Ergen <57065323+Cenngo@users.noreply.github.com>
Co-authored-by: Quin Lynch <49576606+quinchs@users.noreply.github.com>
2022-12-25 17:40:05 +03:00
Misha133
48fb1b5df4 [Feature] Selects v2 support (#2507)
* Initial support for new select types

* Merge branch 'dev' of https://github.com/discord-net/Discord.Net into dev

* some component&action row builder additions

* remove redundant code

* changes1

* maybe working rest part?

* working-ish state?

* fix some xml docs & small rework

* typos

* fix `ActionRowBuilder`

* update DefaultArrayComponentConverter to accomodate new select-v2 types

* now supports dm channels in channel selects

* add a note to IF docs

* add notes about nullable properties

* <see langword="null"/>

* update Modal.cs

Co-authored-by: cat <lumitydev@gmail.com>
Co-authored-by: Cenngo <cenk.ergen1@gmail.com>
2022-12-25 13:41:15 +01:00
Misha133
c67642acfa fix CreatePostError (#2546) 2022-12-25 13:36:33 +01:00
Misha133
a53f1dfa58 fix CreatePost methods for IForumChannel (#2541) 2022-12-23 14:56:00 +01:00
Misha133
56b1a930e7 [Feature] Age restricted (NSFW) application commands support (#2531)
* add `nsfw` to data model & internal methods; add missing property

* add `nsfw` prop to command builders

* add `NsfwCommandAttribute` to Interaction Framework

* working state

* docs?
2022-12-20 01:00:56 +03:00
BokuNoPasya
25cfb8822f Add SendFiles to UserExtensions (#2509)
* Add SendFiles to UserExtensions

* fix Build
2022-12-14 03:00:59 -04:00
Misha133
82b772ac03 [Feature] Add missing property & new stuff (#2521)
* add active developer badge support

* add `OwnerId` to threads

* add default forum layout support

* oops, forgot to update modifyasync

* add missing application flags

* Add `50155` error code
2022-12-14 02:57:06 -04:00
Misha133
bd2f719774 Fix GetActiveThreadsAsync & add it to ITextChannel (#2526)
* fix `GetActiveThreadsAsync` being sadge

* ah, forgot about mocked channel
2022-12-14 02:56:06 -04:00
Misha133
01ae904fe1 [Feature] Add missing properties in forum & thread channels (#2469)
* add `AppliedTags` property

* convert collections into immutable arrays

* remove "not supported" remark

* implement `ThreadChannelProperties`

* Add `DefaultSlowModeInterval` and `DefaultSlowModeInterval` properties to forum channels

* add `Moderated` property to `ForumTag``

* `ForumTag` inherits `ISnowflakeEntity`

* Fix `DiscordRestClient.GetChannelAsync` not getting forum channel

* a lot of changes

added:
- channel flags
- `ForumTagBuilder`
- imroved channel modification

* fixed a bug in forum tag emoji parsing

* inherit forum channel from `INesteeChannel`

* implement `INestedChannel` in forum channels

* Add `Flags` property to channels

* add iteraface for forum tags & add equality operators

* Add default reaction emoji property

* add support for modifing default reaction & some renaming

* add createForumChannelAsync to guild

* *fix resharper being a d... and moving code to next line*

* add a `ForumChannels` property

* Some fixes & add support for `default_sort_order`

* fix misleading comment

* fix #2502

* support creating post with applied tags

* fix xmldoc

* set category id on model update

* add limit checks for tag count
2022-11-07 17:25:49 +01:00
Misha133
ed3863597a [Feature] Add new discord stuff (#2501)
* changesss

- Added missing error code
- Moved region a bit
- Add new `guild feature`
- Add new `NitroBasic` subscription plan

* fix sending message in rest text-in-voice channels
2022-11-07 16:49:03 +01:00
SaculRennorb
3dec99f6df adding scheduled events to audit log (#2437)
* first draft

* made changes be actually optional. not everything always changes

* 'doc' text

* more 'doc' stuff

* more 'doc' stuff3

* 'doc' stuff
2022-09-02 21:56:19 +00:00
Cenk Ergen
fbc5ad414f fix BulkOverwriteCommands NRE (#2444) 2022-08-29 15:24:33 +03:00
Viktor Chernikov
9feb703a82 Wrong symbol fix (#2438) 2022-08-29 11:25:13 +02:00
Cenk Ergen
39bbd298c3 Interactions Command Localization (#2395)
* Request headers (#2394)

* add support for per-request headers

* remove unnecessary usings

* Revert "remove unnecessary usings"

This reverts commit 8d674fe4faf985b117f143fae3877a1698170ad2.

* remove nullable strings from RequestOptions

* Add Localization Support to Interaction Service (#2211)

* add json and resx localization managers

* add utils class for getting command paths

* update json regex to make langage code optional

* remove IServiceProvider from ILocalizationManager method params

* replace the command path method in command map

* add localization fields to rest and websocket application command entity implementations

* move deconstruct extensions method to extensions folder

* add withLocalizations parameter to rest methods

* fix build error

* add rest conversions to interaction service

* add localization to the rest methods

* add inline docs

* fix implementation bugs

* add missing inline docs

* inline docs correction (Name/Description Localized properties)

* add choice localization

* fix conflicts

* fix conflicts

* add missing command props fields to ToApplicationCommandProps methods

* add locale parameter to Get*ApplicationCommandsAsync methods for fetching localized command names/descriptions

* Apply suggestions from code review

Co-authored-by: Armano den Boef <68127614+Rozen4334@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Armano den Boef <68127614+Rozen4334@users.noreply.github.com>

* Update src/Discord.Net.Core/Entities/Guilds/IGuild.cs

Co-authored-by: Armano den Boef <68127614+Rozen4334@users.noreply.github.com>

* add inline docs to LocalizationTarget

* fix upstream merge errors

* fix command parsing for context command names with space char

* fix command parsing for context command names with space char

* fix failed to generate buket id

* fix get guild commands endpoint

* update rexs localization manager to use single-file pattern

* Upstream Merge Localization Branch (#2434)

* fix ci/cd error (#2428)

* Fix role icon & emoji assignment. (#2416)

* Fix IGuild.GetBansAsync() (#2424)

fix the problem of not being able to get more than 1000 bans

* [DOCS] Add a note about `DontAutoRegisterAttribute`  (#2430)

* add a note about `DontAutoRegisterAttribute`

* Remove "to to" and add punctuation

Co-authored-by: MrCakeSlayer <13650699+MrCakeSlayer@users.noreply.github.com>

* fix: Missing Fact attribute in ColorTests (#2425)

* feat: Embed comparison (#2347)

* Fix broken code snippet in dependency injection docs (#2420)

* Fixed markdown formatting to show code snippet

* Fixed constructor injection code snippet pointer

* Added support for lottie stickers (#2359)

Co-authored-by: Armano den Boef <68127614+Rozen4334@users.noreply.github.com>
Co-authored-by: BokuNoPasya <49203428+1NieR@users.noreply.github.com>
Co-authored-by: Misha133 <61027276+Misha-133@users.noreply.github.com>
Co-authored-by: MrCakeSlayer <13650699+MrCakeSlayer@users.noreply.github.com>
Co-authored-by: Ge <gehongyan1996@126.com>
Co-authored-by: Charlie U <52503242+cpurules@users.noreply.github.com>
Co-authored-by: Kuba_Z2 <77853483+KubaZ2@users.noreply.github.com>

* remove unnecassary fields from ResxLocalizationManager

* update int framework guides

* remove space character tokenization from ResxLocalizationManager

Co-authored-by: Armano den Boef <68127614+Rozen4334@users.noreply.github.com>
Co-authored-by: BokuNoPasya <49203428+1NieR@users.noreply.github.com>
Co-authored-by: Misha133 <61027276+Misha-133@users.noreply.github.com>
Co-authored-by: MrCakeSlayer <13650699+MrCakeSlayer@users.noreply.github.com>
Co-authored-by: Ge <gehongyan1996@126.com>
Co-authored-by: Charlie U <52503242+cpurules@users.noreply.github.com>
Co-authored-by: Kuba_Z2 <77853483+KubaZ2@users.noreply.github.com>
2022-08-26 18:45:27 +03:00
Kuba_Z2
32b03c8063 Added support for lottie stickers (#2359) 2022-08-21 10:14:55 -04:00
BokuNoPasya
b7b7964de9 Fix IGuild.GetBansAsync() (#2424)
fix the problem of not being able to get more than 1000 bans
2022-08-21 13:54:19 +02:00
Armano den Boef
b6b5e95f48 Fix role icon & emoji assignment. (#2416) 2022-08-21 13:53:14 +02:00
Armano den Boef
02bc3b7977 Fix NRE on commandbase data assignment (#2414) 2022-08-04 11:05:22 +02:00
Cenk Ergen
e551431d72 Max/Min length fields for ApplicationCommandOption (#2379)
* implement max/min length fields for ApplicationCommandOption

* fix badly formed xml comments
2022-08-03 16:44:30 +03:00
Alex Thomson
ba02416421 fix: DisconnectAsync not disconnecting users (#2346) 2022-08-02 11:26:34 +02:00
Pusheon
f17866085e fix: Add DeleteMessagesAsync to IVoiceChannel (#2367)
Also adds remaining rate-limit information to client log.
2022-08-02 11:24:37 +02:00
Armano den Boef
902326d1f3 fix: Range of issues presented by analyzer (#2404) 2022-08-01 18:53:22 +02:00
Armano den Boef
a890de9304 feature: better call control in ParseHttpInteraction (#2330)
* Init

* Fix channelid xmldoc
2022-05-27 08:25:49 -03:00
d4n
d3a693ab67 feature: Add missing interaction properties (#2325) 2022-05-25 06:12:03 -03:00
Quin Lynch
7a07fd62e4 feature: Forum channels (#2316)
* initial implementation

* Update SocketForumChannel.cs

* rest forum channel and remove message builder for 4.x

* Update src/Discord.Net.Core/DiscordConfig.cs

Co-authored-by: Jared L <48422312+lhjt@users.noreply.github.com>

* Update src/Discord.Net.Core/Entities/Channels/IForumChannel.cs

Co-authored-by: Jared L <48422312+lhjt@users.noreply.github.com>

* Update src/Discord.Net.Core/DiscordConfig.cs

Co-authored-by: Jared L <48422312+lhjt@users.noreply.github.com>

* Update src/Discord.Net.Core/Entities/Channels/IForumChannel.cs

Co-authored-by: Jared L <48422312+lhjt@users.noreply.github.com>

* Update src/Discord.Net.Core/Entities/Channels/IForumChannel.cs

Co-authored-by: Jared L <48422312+lhjt@users.noreply.github.com>

* Update src/Discord.Net.Core/Entities/Channels/IForumChannel.cs

Co-authored-by: Jared L <48422312+lhjt@users.noreply.github.com>

Co-authored-by: Jared L <48422312+lhjt@users.noreply.github.com>
2022-05-24 02:30:25 -03:00
Tripletri
54a5af7db4 fix: Upload file size limit (#2313) 2022-05-23 03:43:38 -03:00
Armano den Boef
cea59b55ba feature: Add Parse & TryParse to EmbedBuilder & Add ToJsonString extension (#2284)
* Add parse & tryparse to embedbuilder.

* Add tostring extension for embeds

* Modify comments

* Resolve suggestions

* Update src/Discord.Net.Rest/Extensions/StringExtensions.cs

Co-authored-by: Quin Lynch <49576606+quinchs@users.noreply.github.com>
2022-05-18 04:57:37 -03:00
Armano den Boef
a24dde4b19 feature: optional API calling to RestInteraction (#2281)
* Take 2

* Expose channel & guild Id for manual calling

* Make api calling optional at runtime

* Resolve build errors

* Bind runtime option to interaction type

* Expose methods to get channel & guild from API

* Patch out NRE's, test on all int types
2022-05-18 04:56:57 -03:00
Armano den Boef
1f01881beb feature: Add DefaultArchiveDuration to ITextChannel (#2295) 2022-05-18 04:51:37 -03:00
Armano den Boef
725d2557dd fix: close-stage bucketId being null (#2299) 2022-05-18 04:48:34 -03:00
Armano den Boef
94a37156f3 Resolve NRE at get audit for Deleted User (#2304) 2022-05-18 04:47:23 -03:00
openmilk
b0a3b65bc0 feature: Webhook support for threads (#2291)
* Added thread support to webhooks

Added thread support to delete/send messages for webhooks

* Revert "Added thread support to webhooks"

This reverts commit c45ef389c5df6a924b6ea5d46d5507386904f965.

* read added threads as im a dummy

* fixed formating

* Fixed modify EmbedMessage
2022-05-13 19:28:46 -03:00
Quin Lynch
23656e844e feature: Text-In-Voice (#2269)
* Initial implementation

* Remove blocking webhooks

* add safeguard for tiv

* fix tests
2022-05-09 22:57:28 -03:00
Quin Lynch
e136759073 feature: Treat warnings as errors and set warning level to 5 (#2270) 2022-05-09 22:56:22 -03:00
moiph
0ec8938a67 feature: Support FailIfNotExists on MessageReference (#2283)
Fixes #2282
2022-05-09 22:55:17 -03:00