Skip to content

Commit 1b668fc

Browse files
authored
Merge pull request #336 from line/next
Release 7.5.0
2 parents e096fe2 + 7ce5ae9 commit 1b668fc

File tree

21 files changed

+5534
-18884
lines changed

21 files changed

+5534
-18884
lines changed

.github/workflows/test.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Test
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
build:
7+
8+
runs-on: ubuntu-latest
9+
10+
strategy:
11+
matrix:
12+
node: [ '10', '12', '14', '16' ]
13+
fail-fast: false
14+
15+
name: Node.js ${{ matrix.node }}
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
- name: Setup Node.js
20+
uses: actions/setup-node@v2
21+
with:
22+
node-version: ${{ matrix.node }}
23+
cache: 'npm'
24+
- name: Install Dependency
25+
run: npm ci
26+
- name: Test Project
27+
run: npm test
28+

.travis.yml

Lines changed: 0 additions & 9 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,29 @@
1+
## 7.5.0 (8 Apr 2022)
2+
3+
### Feature
4+
* add oauth verify api (#291)
5+
* Messaging API Update - November 2021 (#316)
6+
* Update type definition with image set (#305)
7+
* Flex message update 3 (#329)
8+
9+
### Bug fix
10+
* Fix http method of updateRichMenuAlias (#310)
11+
* docs: fix broken link (#308)
12+
13+
### Misc
14+
* add rich menu sample code (#314)
15+
* Bump follow-redirects from 1.14.3 to 1.14.9 (#332)
16+
* Bump follow-redirects from 1.14.4 to 1.14.9 in /examples/rich-menu (#333)
17+
* Bump follow-redirects from 1.14.0 to 1.14.9 in /examples/echo-bot (#335)
18+
* Bump follow-redirects from 1.14.0 to 1.14.9 in /examples/echo-bot-ts (#334)
19+
* Bump ajv from 6.12.2 to 6.12.6 in /examples/kitchensink (#320)
20+
* Bump lodash from 4.17.19 to 4.17.21 in /examples/kitchensink (#286)
21+
* update dependencies by using npm update (#331)
22+
* update ci badge (#313)
23+
* Migrate Travis CI to GitHub Actions (#312)
24+
* Allow pixel values for flex sizing (#309)
25+
* Correct flex text type def (#311)
26+
127
## 7.4.0 (7 Sep 2021)
228

329
### Feature

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# LINE Messaging API SDK for nodejs
22

3-
[![Travis CI](https://travis-ci.org/line/line-bot-sdk-nodejs.svg?branch=master)](https://travis-ci.org/line/line-bot-sdk-nodejs)
3+
[![Github Action](https://github.com/line/line-bot-sdk-nodejs/actions/workflows/test.yml/badge.svg)](https://github.com/line/line-bot-sdk-nodejs/actions/workflows/test.yml)
44
[![npmjs](https://badge.fury.io/js/%40line%2Fbot-sdk.svg)](https://www.npmjs.com/package/@line/bot-sdk)
55

66

docs/api-reference/oauth.md

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ class OAuth {
1111

1212
issueAccessToken(client_id: string, client_secret: string): Promise<Types.ChannelAccessToken>
1313
revokeAccessToken(access_token: string): Promise<{}>
14+
verifyAccessToken(access_token: string): Promise<Types.VerifyAccessToken>
1415
issueChannelAccessTokenV2_1(
1516
client_assertion: string,
1617
): Promise<Types.ChannelAccessToken>
@@ -22,6 +23,12 @@ class OAuth {
2223
client_secret: string,
2324
access_token: string,
2425
): Promise<{}>
26+
verifyIdToken(
27+
id_token: string,
28+
client_id: string,
29+
nonce: string = undefined,
30+
user_id: string = undefined,
31+
): Promise<Types.VerifyIDToken>
2532
}
2633
```
2734

@@ -66,9 +73,19 @@ It corresponds to the [Issue channel access token](https://developers.line.biz/e
6673
const { access_token, expires_in, token_type } = await oauth.issueAccessToken("client_id", "client_secret");
6774
```
6875

76+
77+
#### `verifyAccessToken(access_token: string): Promise<Types.VerifyAccessToken>`
78+
79+
It corresponds to the [Verify access token validity](https://developers.line.biz/en/reference/line-login/#verify-access-token) API.
80+
81+
82+
``` js
83+
await oauth.verifyAccessToken("access_token");
84+
```
85+
6986
#### `revokeAccessToken(access_token: string): Promise<{}>`
7087

71-
It corresponds to the [Revoke channel access token](https://developers.line.biz/en/reference/messaging-api/#revoke-channel-access-token) API.
88+
It corresponds to the [Revoke channel access token](https://developers.line.biz/en/reference/line-login/#revoke-access-token) API.
7289

7390

7491
``` js
@@ -86,3 +103,7 @@ It corresponds to the [Get all valid channel access token key IDs v2.1](https://
86103
#### revokeChannelAccessTokenV2_1(client_id: string, client_secret: string, access_token: string): Promise<{}>
87104

88105
It corresponds to the [Revoke channel access token v2.1](https://developers.line.biz/en/reference/messaging-api/#revoke-channel-access-token-v2-1) API.
106+
107+
#### verifyIdToken(id_token: string, client_id: string, nonce: string = undefined, user_id: string = undefined): Promise<{}>
108+
109+
It corresponds to the [Verify ID token v2.1](https://developers.line.biz/en/reference/line-login/#verify-id-token) API.

docs/guide/client.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ if (event.type === 'message') {
6262
```
6363

6464
For more detail of building webhook and retrieve event objects, please refer to
65-
its [guide](./webhook.html).
65+
its [guide](./webhook.md).
6666

6767
## Error handling
6868

examples/echo-bot-ts/package-lock.json

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/echo-bot/package-lock.json

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/kitchensink/package-lock.json

Lines changed: 6 additions & 24 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/rich-menu/README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# rich menu
2+
3+
[Using rich menus](https://developers.line.biz/en/docs/messaging-api/using-rich-menus/)
4+
5+
## How to use
6+
7+
### Install deps
8+
9+
``` shell
10+
$ npm install
11+
```
12+
13+
### Configuration
14+
15+
``` shell
16+
$ export CHANNEL_SECRET=YOUR_CHANNEL_SECRET
17+
$ export CHANNEL_ACCESS_TOKEN=YOUR_CHANNEL_ACCESS_TOKEN
18+
```
19+
20+
### Run
21+
22+
``` shell
23+
$ node .
24+
```

0 commit comments

Comments
 (0)