Skip to content

Commit

Permalink
Codes are generated by openapi generator (#1410)
Browse files Browse the repository at this point in the history
line/line-openapi#65

In the Messaging API, we've added the following values as conditions for
filtering the age range of recipients in the [demographic filter
objects](https://developers.line.biz/en/reference/messaging-api/#narrowcast-demographic-filter)
of [narrowcast
messages](https://developers.line.biz/en/reference/messaging-api/#send-narrowcast-message):

- `age_55`
- `age_60`
- `age_65`
- `age_70`

Until now, the upper limit was `age_50`, so it wasn't possible to filter
ages over 50 in detail. By specifying the added age ranges, you can now
filter recipients more flexibly than before.

For example, the following is a demographic filter object that filters
by age 50 and older but less than 60:

```json
{
  "type": "age",
  "gte": "age_50",
  "lt": "age_60"
}
```

news:
https://developers.line.biz/en/news/2024/08/26/age-filter-subdivision/

Co-authored-by: github-actions <[email protected]>
  • Loading branch information
github-actions[bot] and github-actions authored Aug 26, 2024
1 parent f40dc08 commit 55e1958
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,18 @@ public enum AgeDemographic {
@JsonProperty("age_50")
AGE_50,

@JsonProperty("age_55")
AGE_55,

@JsonProperty("age_60")
AGE_60,

@JsonProperty("age_65")
AGE_65,

@JsonProperty("age_70")
AGE_70,

@JsonEnumDefaultValue
UNDEFINED;

Expand All @@ -66,6 +78,10 @@ public String toValue() {
case AGE_40 -> "age_40";
case AGE_45 -> "age_45";
case AGE_50 -> "age_50";
case AGE_55 -> "age_55";
case AGE_60 -> "age_60";
case AGE_65 -> "age_65";
case AGE_70 -> "age_70";

default -> "UNDEFINED";
};
Expand Down
2 changes: 1 addition & 1 deletion line-openapi

0 comments on commit 55e1958

Please sign in to comment.