Releases: discord-php/DiscordPHP
Version 7.0.9
Fix for retrieveBans
after breaking change with API discord/discord-api-docs@808d94b
Also fixed the retrieveBans
not properly given discriminator and guild data
Full Changelog: v7.0.8...v7.0.9
Version 7.0.8
Hotfix #776 for direct message crash to the previous fix #775
Full Changelog: v7.0.7...v7.0.8
Version 7.0.6
What's Changed
- Fix resolved members data exception by @jocafamaka in #765
- Fix invites by @key2peace in #768
- BPM vs BPS by @key2peace in #769
- Patch Version 7.0.6 by @SQKo in #773
Full Changelog: v7.0.5...v7.0.6
Version 7.0.5
What's Changed
VoiceClient::isSpeaking()
without$id
returns the current bot speaking status by @key2peace in #754- Fix
PresenceUpdate::guild
nullable by @SQKo in #758 VoiceClient
updates and fix by @key2peace in #752- Fix
getPermissions()
onThreads
to inherit permissions from the channel in which they were created by @valzargaming in #759 SelectMenu::placeholder
limit 150 chars,guild_scheduled_event
id for stage instance,Permission::start_embedded_activities
is soon to be renamed asPermission::use_embedded_activities
by @SQKo in #760
Full Changelog: v7.0.4...v7.0.5
Version 7.0.4
What's Changed
- Fixed
Option::addChoice()
null pointer exception. by @shehi in #739 - Changed
custom_id
argument as optional fornew Button()
. by @shehi in #740 - Added
MessageBuilder
forMessage::reply()
andMessage::delayedReply()
functions by @SQKo in #741 - Fixed
Channel::setOverwrite()
fatal error to ignore permission check if guild does not exist or channel not yet created by @SQKo in #743 - Added
Channel::getBotPermissions()
helper function by @key2peace in #744 - Changed
Interaction::sendFollowUpMessage()
to be usable forInteractionType::MESSAGE_COMPONENT
by @SQKo in #748 - Fixed sub command options (credits Discord user idkmanm#3642) in #749
Full Changelog: v7.0.3...v7.0.4
Version 7.0.3
What's Changed
- Fix embed description limit, remove duplicated happy eyeballs option by @SQKo in #732
- Add Member::setRoles() and Fix to ignore potential null guild on events by @SQKo in #734
- Tweak deleteMessages(), add Collection::last() @key2peace in #736
Full Changelog: v7.0.2...v7.0.3
Version 7.0.2
What's Changed
- Bumped version
- Deprecated
Invite::stage_instance
- Fixed phpdoc regarding
$channel
parameter inMember::moveMember()
can be nullable - Added
Thread::getUpdateableAttributes()
, the following functions are separate to be used by Bot withoutMANAGE_THREAD
permissions but owns the thread:- Added
Thread::rename()
- Added
Thread::setAutoArchiveDuration()
- Added audit log
$reason
parameters forThread::archive()
andThread::unarchive()
- Added
Thread
attributesarchived
,locked
,auto_archive_duration
can be now set shorter without accessingthread_metadata
, e.g.$thread->archived = true;
- Added
MessageBuilder::addAttachment()
,MessageBuilder::getAttachments()
,MessageBuilder::clearAttachments()
- Updated
Discord::close(false)
to send OP Code 1000 (normal close), if you want to close your bot gracefully (as if you do not want to restart soon) and make it offline from discord, you can use the following code:
$discord->close(false);
$loop = $discord->getLoop();
$loop->futureTick([$loop, 'stop']);
Full Changelog: v7.0.1...v7.0.2
Version 7.0.1
- Fixed
TextInput::setRequired()
default value false to true - Added
dnsConfig
Discord options, makeVoiceClient
to use system configuration DNS resolver first before Google Public DNS
Full Changelog: v7.0.0...v7.0.1
Version 7.0.0
New API:
- Thread
- Interactions: Application Commands (slash, message, user context menu), Message Components, Autocomplete, Modal
- Guild: Template, Stage Instance, Scheduled Event, Template, Welcome Screen, Integration events, Webhook events
- Role: Icon
- Member: Avatar, Timeout
New features:
- Message Builder
- Command Builder
- Components Builder
- Create & Manage Emoji
- Manage Stickers
- Audit log reason
Read the RC-stage release notes for more details: https://github.com/discord-php/DiscordPHP/releases/tag/v7.0.0-RC4
Conversion guide: https://github.com/discord-php/DiscordPHP/blob/master/V7_CONVERSION.md
Full Changelog: v6.0.2...v7.0.0
Version 7.0.0 Release Candidate
This is a major update with up to date features from Discord API
Read the migration guide here: https://github.com/discord-php/DiscordPHP/blob/master/V7_CONVERSION.md
Version 7.0.0 Release Candidate 4
This is expected to be final stage of the Release Candidate before going full v7.0.0 release.
- Added
Interaction::getFollowUpMessage()
andInteraction::deleteFollowUpMessage()
(#696) - Added Widget, which can be retrieved from
Guild::getWidget()
andGuild::getWidgetSettings()
, also can be updated withGuild::updateWidgetSettings()
(#695) - Added
system_channel_flags
Guild attribute as createable and updateable (#695) - Added
description
Guild attribute as updateable (#695) - Added cove
image
Scheduled Event attribute (#695) - Added
User
repository caching from event (#694) - Added
ActionRow::clearComponents()
(#699) - Fixed
status
Scheduled event attribute mistakenly made for createable as it was meant for updateable (#695) - Fixed Components builder (ActionRow, Button, SelectMenu) not allowing zero value (#699)
Version 7.0.0 Release Candidate 3
- Added Guild Integration
$guild->integrations
(#692) - Added
Event::INTEGRATION_CREATE
,Event::INTEGRATION_UPDATE
,Event::INTEGRATION_DELETE
,Event::WEBHOOKS_UPDATE
, andEvent::USER_UPDATE
(only for the current bot user) (#692) - Added
User::displayname
andMember::displayname
string for discord user nickname or username with discriminator tag, e.g. D.PHP#6809 (#683) - Added
Thread::archive()
andThread::unarchive()
(#682) - Added
ephemeral
argument forInteraction::acknowledgeWithSource()
(#679) - Added many missing attributes:
- Added back
Guild::welcome_screen
attribute, but this will be only filled afterGuild::getWelcomeScreen()
- Added
Message
attributes:interaction
andcomponents
, flag attributes:has_thread
,ephemeral
, andloading
- Added
Webhook
attributes:source_guild
,source_channel
, andurl
- Added
Role
attributetags
- Added
Application
attributesicon
,primary_sku_id
,slug
,summary
,cover_image
, useful to retrieve your bot information without going through Developers Portal page
- Added back
- Bump DiscordPHP-Http to version 9.0.9 marked to 4.0.10 (for docs)
- Changed
Event::MESSAGE_REACTION_REMOVE_EMOJI
first callback argument to aMessageReaction
Part (#692) - Changed
Invite::guild_scheduled_event
to return GuildScheduledEvent
Part - Changed end point for the bot self
Member::setNickname()
fromtoEndpoint::GUILD_MEMBER_SELF_NICK
Endpoint::GUILD_MEMBER_SELF
- Overhaul with the SPL Exception to use correct and closest meaningful exception
- Fixed and changed
Option::removeOption()
to accept option name, as wellOption::removeChoice()
to accept choice name. - Fixed
Member::getPermissions()
on channel overwrites (#680). - Fixed
AbstractRepository::freshen()
not clearing the old Parts - Some code minor optimization
Breaking Changes
$message->author
is now only return anUser
object and no longer return aMember
object.$message->user
is removed in favour of$message->author
(#663)- Changed
Interaction
promise functions to usereject()
instead of throwing exceptions - Removed leftover first argument
Part
on Guild CommandssetOverwrite()
however the function is now deprecated as discord is replacing the application command permissions system.
Version 7.0.0 Release Candidate 2
- Added auto complete callback in
listenCommand()
or$command->setAutoCompleteCallback()
(#676) - Added missing
Application
attributesbot_public
,bot_require_code_grant
,terms_of_service_url
,privacy_policy_url
,verify_key
,team
(#672) - Added
Channel
attributepermissions
for interactions, and constants (#672) - Added
Guild
attributeicon_hash
for template (#672) - Added
Message
attributesapplication_id
,components
for interactions (#672) - Added missing
Invite
attributes and constants (#672) - Added missing
Video
attributeproxy_url
(#672) - Fixed wrong
Message::ACTIVITY_JOIN_REQUEST
constant value (#672) - Fixed permission errors (#675)
- Fixed crash with Guild Welcome Screen attribute (#672)
- Updated some phpdoc comment (#672)
Breaking Changes
- Sticker
use Discord\Parts\Channel\Sticker
is nowuse Discord\Parts\Guild\Sticker
(#673) - Application Command
$discord->registerCommand()
is now$discord->listenCommand()
(#671)
Version 7.0.0 Release Candidate 1
- Discord Gateway and REST API versions changed to Version 9
- Compatibility update for PHP 8.1 (#599)
- New Message Builder
- Added Threads
- Added Message Components (Buttons & Select Menu)
- Added Stage Instance (#643)
- Added Guild Scheduled Event (#648)
- Added Guild Template (#647)
- Added Guild Welcome Screen (#637)
- Added Guild nsfw level & premium progress bar (#635)
- Added Role icon (#619)
- Added User banner & accent color (#608)
- Added Member avatar (#618)
- Added Member Timeout (#650)
- Added Application Command for slash, context menu (user/message), and auto complete (#597)
- If you previously linked DiscordPHP with DiscordPHP-Slash, you will no longer need DiscordPHP-Slash since it is now integrated, so you can start migrating your codes to DiscordPHP and enjoy the new features upgrade
- Includes new Command Builder
- Added
Guild::createEmoji()
, emoji update method, and emoji update events (#665) - Added Sticker update method, and sticker update events (#642)
- Added
Guild::searchMembers()
(#614) - Added
MessageReaction::delete()
(#603) - Added audit log
$reason
parameter in some endpoint method where possible (#656) - Added example back (#659), check out the examples folder if you are beginner with DiscordPHP
- Various fix with Voice Client, Audit Log, Command Client help embed, Guild splash, and many more
- Code optimization & clean up
Documentation will be updated soon to cover the new features. Meanwhile check out the Official Discord API docs or ask us in the DiscordPHP server.
Breaking Changes
- x86 (32 bit) PHP now requires
ext-gmp
for Permissions to work correctly (#661)- If your Bot currently does not deal with permissions, it will still work without the extension and a warning will show up, however please note that future changes with the API may enforce 32-bit PHP with GMP extension enabled for the Bot to run. It's recommended that you upgrade to 64-bit PHP.
Message::channel
now returnChannel|Thread
(check out the conversion guide)Message::stickers
is nowMessage::sticker_items
(#642)- The
User
/Member
/Role
::getAvatarAttribute()
/getBannerAttribute()
/getIconAttribute()
parameter$format
is now default tonull
and will detect the default format & type (i.e. animated) (#657) - Deprecated old permission names: (#661)
use_slash_commands
is nowuse_application_commands
use_public_threads
is nowcreate_public_threads
use_private_threads
is nowcreate_private_threads
manage_emojis
is nowmanage_emojis_and_stickers
Guild::region
is deprecated and may be removed in future release (#630)
Notes:
- Expect breaking changes in this RC stage, with
$message->author
only return anUser
object and no longer return aMember
object.$message->user
will be removed in favour of$message->author
(#663) - Expect a voice client refactor in a future release
Thank you to the following for contributions to this release: