Skip to content

Releases: line/line-bot-sdk-php

v12.4.0 Support new AudienceGroupType TRACKINGTAG_WEBTRAFFIC to Audience Group API

21 Jan 11:23
Immutable release. Only release title and notes can be modified.
97196e5

Choose a tag to compare

What's Changed

  • Add new AudienceGroupType TRACKINGTAG_WEBTRAFFIC to Audience Group API by @github-actions[bot] in #784

Add TRACKINGTAG_WEBTRAFFIC to AudienceGroupType Enum

We have supported for the new audience‑group type TRACKINGTAG_WEBTRAFFIC (Tracking Tag Webtraffic audience) to the OpenAPI schema.

Changes Made

  • Updated AudienceGroupType enumeration

    • New value: TRACKINGTAG_WEBTRAFFIC
    • Description: Audience groups generated from Tracking Tag Webtraffic.

Purpose

This update enables correct identification and handling of audience groups built from Tracking Tag Webtraffric.

Documents and Reference

For more information, please refer to the links provided above.

(original PR is line/line-openapi#118)

line-openapi updates

  • chore(deps): update line-openapi digest to f406009 by @renovate[bot] in #767
  • Codes are generated by openapi generator by @github-actions[bot] in #783

Dependency updates

  • chore(deps): update dependency squizlabs/php_codesniffer to v4.0.1 by @renovate[bot] in #758
  • chore(deps): update actions/checkout action to v5.0.1 by @renovate[bot] in #760
  • chore(deps): update actions/checkout action to v6 by @renovate[bot] in #761
  • chore(deps): update shivammathur/setup-php action to v2.36.0 by @renovate[bot] in #763
  • chore(deps): update actions/checkout action to v6.0.1 by @renovate[bot] in #764
  • chore(deps): update actions/stale action to v10.1.1 by @renovate[bot] in #765
  • chore(deps): update actions/setup-node action to v6.1.0 by @renovate[bot] in #766
  • chore(deps): update actions/cache action to v5 by @renovate[bot] in #768
  • chore(deps): update actions/upload-artifact action to v6 by @renovate[bot] in #770
  • chore(deps): update actions/cache action to v5.0.1 by @renovate[bot] in #769
  • chore(deps): update suzuki-shunsuke/pinact-action action to v1.0.1 by @renovate[bot] in #774
  • chore(deps): update suzuki-shunsuke/pinact-action action to v1.1.0 by @renovate[bot] in #776
  • chore(deps): update suzuki-shunsuke/pinact-action action to v1.2.0 by @renovate[bot] in #778
  • chore(deps): update suzuki-shunsuke/pinact-action action to v1.3.0 by @renovate[bot] in #780
  • chore(deps): update suzuki-shunsuke/pinact-action action to v1.3.1 by @renovate[bot] in #782

Other Changes

Full Changelog: v12.3.0...v12.4.0


This release is prepared by @eucyt

v12.3.0 Support mark as read by token API

07 Nov 08:14
Immutable release. Only release title and notes can be modified.
246ec41

Choose a tag to compare

What's Changed

  • Support mark as read by token API by @github-actions[bot] in #757

Support for "Mark as Read" by Token API

We have released a new Mark as Read API that allows developers to mark a user’s messages as read.
Previously, this functionality was available only to partners, but it is now publicly available.

When your server receives a user message via Webhook, the MessageContent will include a new field: markAsReadToken.
By calling the Mark as Read API with this token, all messages in the chat room up to and including that message will be marked as read.

Note: This feature assumes that your service uses the chat feature through Official Account Manager.
If chat is not enabled, messages from users are automatically marked as read, making this API unnecessary.

For more details, please refer to the release note: https://developers.line.biz/en/news/2025/11/05/mark-as-read/

(original PR is line/line-openapi#115)

Example

$bot->markAsReadByToken(new MarkAsReadByTokenRequest([
    'markAsReadToken' => $message->markAsReadToken,
]))

line-openapi updates

Dependency updates

  • chore(deps): update actions/upload-artifact action to v5 by @renovate[bot] in #753

Other Changes

  • Remove Things examples by @eucyt in #754
  • Update documents and examples to use the constructor which sets the discriminator value automatically by @eucyt in #755

Full Changelog: v12.2.0...v12.3.0


This release is prepared by @habara-k

v12.2.0 Make the constructor automatically set the discriminator value

31 Oct 06:13
Immutable release. Only release title and notes can be modified.
96e06a1

Choose a tag to compare

What's Changed

  • Make the constructor automatically set the discriminator value by @eucyt in #752

Previously, when creating a polymorphic model, you have to set the discriminator value manually each time, even though the value is obvious.

$message = (new TextMessage())
  ->setType(\LINE\Constants\MessageType::TEXT) // this is redundant.
  ->setText('hello!');

With this release, the discriminator value will be automatically set in the constructor.

$message = (new TextMessage())
  ->setText('hello!');

$this->assertEquals('text', $message->getType()); // Passed

Dependency updates

  • chore(deps): update dependency node to v24 by @renovate[bot] in #751

Full Changelog: v12.1.0...v12.2.0


This release is prepared by @eucyt

v12.1.0 Add forbidPartialDelivery option to the Narrowcast Limit Object

24 Oct 02:07
Immutable release. Only release title and notes can be modified.
7f7122f

Choose a tag to compare

What's Changed

  • Add forbidPartialDelivery option to the Narrowcast Limit Object by @github-actions[bot] in #750

Add forbidPartialDelivery option to the Narrowcast Limit Object

We add a new forbidPartialDelivery option to the Narrowcast Limit Object.

When set to true, this option prevents messages from being delivered to only a subset of the target audience.
If partial delivery occurs, the narrowcast request will succeed but fail asynchronously.
You can verify whether the message delivery was canceled by checking the narrowcast message progress.

This property can only be set to true when upToRemainingQuota is also true.

For more details, see the https://developers.line.biz/en/news/2025/10/21/narrowcast-message-update/.

Example:
$bot->narrowcast(new NarrowcastRequest([
  'messages' => [
    (new TextMessage(['text' => 'Hello']))->setType('text'),
  ],
  'limit' => new Limit([
    'max' => 1000,
    'upToRemainingQuota' => true,
    'forbidPartialDelivery' => true
  ])
]))

(original PR is line/line-openapi#114)

Use cases

Previously, when upToRemainingQuota was set to true, messages could be partially delivered if the remaining message quota was smaller than the target audience size.
With the new forbidPartialDelivery option, you can now ensure that such partial deliveries do not occur.

  • Ensuring that a campaign message is sent only if it can reach the full target audience, avoiding incomplete distributions.

line-openapi updates

Full Changelog: v12.0.0...v12.1.0


This release is prepared by @habara-k

v12.0.0 Support polymorphism in response deserialization

22 Oct 06:46
Immutable release. Only release title and notes can be modified.
b4b857c

Choose a tag to compare

What's Changed

  • Support polymorphism in response deserialization by @eucyt in #746

This change introduces polymorphism support in API responses.
⚠️ This includes breaking changes.

As-Is

Polymorphic types in responses were not handled correctly.
As a result, all responses were deserialized into the base class, making it impossible to access subclass-specific properties.

$api = new MessagingApiApi($client);
$richMenuListResponse = $api->getRichMenuList();

// Even if type=postback, it becomes an instance of Action, not PostbackAction
$action = $richMenuListResponse->getRichmenus()[0]->getAreas()[0]->getAction();
// Error: Call to undefined method LINE\Clients\MessagingApi\Model\Action::getData()
$data = $action->getData();
// or simply null
$data = $action["data"];

To-Be

Polymorphic types in responses are now properly supported.
Each response is deserialized into the correct subclass, allowing subclass properties to be accessed safely.

This change applies to all API responses, not just this specific endpoint.
If your existing code depends on the base class types, you will need to update it accordingly.
You can now directly access subclass-specific properties when polymorphism is involved.

When the discriminator is unknown, it is deserialized into the parent class, and no error occurs.

$api = new MessagingApiApi($client);
$richMenuListResponse = $api->getRichMenuList();

// If type=postback, it will now become an instance of PostbackAction
$action = $richMenuListResponse->getRichmenus()[0]->getAreas()[0]->getAction();
// You can now access subclass-specific properties
$data = $action->getData();
$data = $action["data"];

Full Changelog: v11.4.0...v12.0.0


This release is prepared by @eucyt

v11.4.0 Add an Option to Skip Webhook Signature Verification

21 Oct 08:01
Immutable release. Only release title and notes can be modified.
c6d2dc0

Choose a tag to compare

What's Changed

With this release, developers can now optionally skip signature verification when parsing incoming webhook requests. This new capability is especially useful in scenarios where the channel secret may change, potentially causing temporary signature mismatches.

Example Usage:

$options = new EventRequestOptions(function () {
    return true;
});

$parsedEvents = EventRequestParser::parseEventRequest(
    $req->getBody(), $secret, $signature[0], $options
);

When signature verification is skipped, the signatureValidator will not be invoked. This allows webhook requests to be processed even if their signatures do not match the current channel secret used for verification.

This feature is particularly helpful in high-availability systems where avoiding downtime or message loss during configuration updates is critical.

Dependency updates

  • chore(deps): update dependency squizlabs/php_codesniffer to v3.13.4 by @renovate[bot] in #734
  • chore(deps): update actions/github-script action to v7.1.0 by @renovate[bot] in #735
  • chore(deps): update actions/github-script action to v8 by @renovate[bot] in #736
  • chore(deps): update actions/setup-node action to v5 by @renovate[bot] in #737
  • chore(deps): update actions/stale action to v10 by @renovate[bot] in #738
  • chore(deps): update dependency squizlabs/php_codesniffer to v4 by @renovate[bot] in #742
  • chore(deps): update shivammathur/setup-php action to v2.35.5 by @renovate[bot] in #744
  • chore(deps): update actions/cache action to v4.3.0 by @renovate[bot] in #745
  • chore(deps): update actions/stale action to v10.1.0 by @renovate[bot] in #747
  • chore(deps): update actions/setup-node action to v6 by @renovate[bot] in #749

Other Changes

  • Set minimumReleaseAge to 7 days to avoid merge renovate PR quickly by @Yang-33 in #739
  • Use github actor id instead of bot name to avoid renaming issues by @Yang-33 in #740
  • Prevent command injection when creating release notes by @Yang-33 in #748

New Contributors

Full Changelog: v11.3.0...v11.4.0

v11.3.0 Support new AudienceGroupType POP_AD_IMP to Audience Group API

26 Aug 01:47
9f857cf

Choose a tag to compare

What's Changed

Support new AudienceGroupType POP_AD_IMP to Audience Group API

  • Add new AudienceGroupType POP_AD_IMP to Audience Group API by @github-actions[bot] in #731

We have supported for the new audience‑group type POP_AD_IMP (POP ad impression audience) to the OpenAPI schema.

Changes Made

  • Updated AudienceGroupType enumeration

    • New value: POP_AD_IMP
    • Description: Audience groups generated from impressions of LINE Beacon Network (POP) ads.
    • Region: Taiwan‑only at launch

Purpose

This update enables correct identification and handling of audience groups built from POP ad impressions, a feature that will be released for the Taiwan market.

Documents and Reference

For more information, please refer to the links provided above.

(original PR is line/line-openapi#113)

Dependency updates

  • chore(deps): update actions/upload-pages-artifact action to v4 by @renovate[bot] in #729

Other Changes

Full Changelog: v11.2.1...v11.3.0


This release is prepared by @eucyt

v11.2.1 Clean up webhook code for line things

13 Aug 01:03
a2a3e30

Choose a tag to compare

What's Changed

LINE Things has been closed. In this release we removed the following LINE Things related webhook code

  • ThingsEvent
  • ThingsContent
  • LinkThingsContent
  • UnlinkThingsContent
  • ScenarioResultThingsContent
  • ScenarioResult
  • ActionResult

As noted in the README, deletions tied to a business shutdown are shipped as a patch version, not a major version. If your code still references any of these code, they will never be emitted again, so you should remove them.

  • Bye line things by @github-actions[bot] in #727
  • Bye line things by @Yang-33 in #726

Dependency updates

  • chore(deps): update actions/cache action to v4.2.4 by @renovate[bot] in #720
  • chore(deps): update shivammathur/setup-php action to v2.35.3 by @renovate[bot] in #722
  • chore(deps): update dependency node to v22 by @renovate[bot] in #723
  • chore(deps): update actions/checkout action to v4.3.0 by @renovate[bot] in #724
  • chore(deps): update actions/checkout action to v5 by @renovate[bot] in #725

Full Changelog: v11.2.0...v11.2.1


This release is prepared by @Yang-33

v11.2.0 Add Coupon API Support to Messaging API

06 Aug 09:40
180bea9

Choose a tag to compare

What's Changed

This release introduces Coupon API support to the Messaging API, enabling developers to create, manage, and deliver coupons directly through bot integrations. These new features mirror capabilities previously only available through the LINE Official Account Manager, offering greater flexibility in automating coupon workflows via the Messaging API.

✨ New API Endpoints

💬 Messaging API Enhancements

  • Added support for a new message type: type=coupon
    You can now send coupons directly to users using the Messaging API, similar to sending text, image, or template messages.

📌 Example Use Cases

  • Create a 1000 yen off coupon
  • Send the coupon to a user using the new coupon message type

For detailed usage examples, see the official documentation.

📢 Official Announcement:

LINE Developers News — Coupon API Released (2025/08/06)

line-openapi updates

  • chore(deps): update line-openapi digest to 3e09054 by @renovate[bot] in #705
  • chore(deps): update line-openapi digest to 69a12e8 by @renovate[bot] in #707
  • chore(deps): update line-openapi digest to 92f9320 by @renovate[bot] in #709
  • Add Coupon API Support to Messaging API by @github-actions[bot] in #719

Dependency updates

  • chore(deps): update dependency squizlabs/php_codesniffer to v3.13.0 by @renovate[bot] in #706
  • chore(deps): update ramsey/composer-install action to v3.1.1 by @renovate[bot] in #710
  • chore(deps): update shivammathur/setup-php action to v2.34.0 by @renovate[bot] in #711
  • chore(deps): update dependency squizlabs/php_codesniffer to v3.13.1 by @renovate[bot] in #712
  • chore(deps): update shivammathur/setup-php action to v2.34.1 by @renovate[bot] in #713
  • chore(deps): update dependency squizlabs/php_codesniffer to v3.13.2 by @renovate[bot] in #714
  • chore(deps): update shivammathur/setup-php action to v2.35.1 by @renovate[bot] in #717
  • chore(deps): update shivammathur/setup-php action to v2.35.2 by @renovate[bot] in #718

Other Changes

  • Improve issue triage and issue template by @eucyt in #708
  • Update CONTRIBUTING.md to enhance development guidelines by @eucyt in #715
  • Add link to composer.json by @Yang-33 in #716

Full Changelog: v11.1.1...v11.2.0

v11.1.1 Fix type of CreateAudienceGroupResponse#expireTimestamp

24 Apr 11:31
1efb370

Choose a tag to compare

What's Changed

Type for CreateAudienceGroupResponse#expireTimestamp is not float or double, but integer actually. This release fixes type as bugfix.

  • Fix type of expireTimestamp by @github-actions in #704

(original PR is line/line-openapi#106)

line-openapi updates

  • chore(deps): update line-openapi digest to f8dd567 by @renovate in #703

Full Changelog: v11.1.0...v11.1.1


This release is prepared by @Yang-33