Skip to content

Commit 5649be7

Browse files
authored
feat(llc)!: Regenerate API models and endpoints (#56)
1 parent 6b47a72 commit 5649be7

File tree

198 files changed

+6519
-491
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

198 files changed

+6519
-491
lines changed

melos.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ command:
4242
photo_view: ^0.15.0
4343
json_annotation: ^4.9.0
4444
meta: ^1.9.1
45-
retrofit: ^4.6.0
45+
# There's a breaking change in retrofit 4.10.0, so we limit the version to <=4.9.0
46+
retrofit: ">=4.6.0 <=4.9.0"
4647
rxdart: ^0.28.0
4748
shared_preferences: ^2.5.3
4849
state_notifier: ^1.0.0

packages/stream_feeds/CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
## unreleased
2+
- [BREAKING] Change `queryFollowSuggestions` return type to `List<FeedSuggestionData>`.
3+
- [BREAKING] Remove `activitySelectorOptions` from `FeedQuery`.
4+
- Add `hidden` and `preview` fields to `ActivityData`.
25
- Update follower and following counts on the feed state when receiving follow websocket events.
36
- Fix FeedsReactionData id for updating reactions in the feed state.
47
- Improvement for stories and minor updates to other AggregatedActivity state updates.

packages/stream_feeds/lib/src/generated/api/api/default_api.dart

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ abstract interface class DefaultApi {
5454

5555
@POST('/api/v2/feeds/comments')
5656
Future<Result<AddCommentResponse>> addComment({
57-
@Body() required AddCommentRequest addCommentRequest,
57+
@Body() AddCommentRequest? addCommentRequest,
5858
});
5959

6060
@POST('/api/v2/feeds/comments/{id}/reactions')
@@ -90,6 +90,11 @@ abstract interface class DefaultApi {
9090
@Body() required CreateBlockListRequest createBlockListRequest,
9191
});
9292

93+
@POST('/api/v2/feeds/collections')
94+
Future<Result<CreateCollectionsResponse>> createCollections({
95+
@Body() required CreateCollectionsRequest createCollectionsRequest,
96+
});
97+
9398
@POST('/api/v2/devices')
9499
Future<Result<DurationResponse>> createDevice({
95100
@Body() required CreateDeviceRequest createDeviceRequest,
@@ -150,6 +155,11 @@ abstract interface class DefaultApi {
150155
@Path('folder_id') required String folderId,
151156
});
152157

158+
@DELETE('/api/v2/feeds/collections')
159+
Future<Result<DeleteCollectionsResponse>> deleteCollections({
160+
@Query('collection_refs') required List<String> collectionRefs,
161+
});
162+
153163
@DELETE('/api/v2/feeds/comments/{id}')
154164
Future<Result<DeleteCommentResponse>> deleteComment({
155165
@Path('id') required String id,
@@ -423,6 +433,11 @@ abstract interface class DefaultApi {
423433
@Query('payload') QueryUsersPayload? payload,
424434
});
425435

436+
@GET('/api/v2/feeds/collections')
437+
Future<Result<ReadCollectionsResponse>> readCollections({
438+
@Query('collection_refs') required List<String> collectionRefs,
439+
});
440+
426441
@POST(
427442
'/api/v2/feeds/feed_groups/{feed_group_id}/feeds/{feed_id}/members/reject')
428443
Future<Result<RejectFeedMemberInviteResponse>> rejectFeedMemberInvite({
@@ -495,6 +510,11 @@ abstract interface class DefaultApi {
495510
@Body() UpdateBookmarkFolderRequest? updateBookmarkFolderRequest,
496511
});
497512

513+
@PATCH('/api/v2/feeds/collections')
514+
Future<Result<UpdateCollectionsResponse>> updateCollections({
515+
@Body() required UpdateCollectionsRequest updateCollectionsRequest,
516+
});
517+
498518
@PATCH('/api/v2/feeds/comments/{id}')
499519
Future<Result<UpdateCommentResponse>> updateComment({
500520
@Path('id') required String id,

packages/stream_feeds/lib/src/generated/api/api/default_api.g.dart

Lines changed: 162 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
// Code generated by GetStream internal OpenAPI code generator. DO NOT EDIT.
2+
3+
// coverage:ignore-file
4+
// ignore_for_file: unused_import, unnecessary_import, prefer_single_quotes, require_trailing_commas, unnecessary_raw_strings, public_member_api_docs
5+
6+
import 'package:freezed_annotation/freezed_annotation.dart';
7+
import 'package:json_annotation/json_annotation.dart';
8+
import 'package:meta/meta.dart';
9+
import 'package:stream_core/stream_core.dart' as core;
10+
11+
import '../models.dart';
12+
13+
part 'activity_feedback_event.g.dart';
14+
part 'activity_feedback_event.freezed.dart';
15+
16+
@freezed
17+
@immutable
18+
@JsonSerializable()
19+
class ActivityFeedbackEvent extends core.WsEvent with _$ActivityFeedbackEvent {
20+
const ActivityFeedbackEvent({
21+
required this.activityFeedback,
22+
required this.createdAt,
23+
required this.custom,
24+
this.receivedAt,
25+
required this.type,
26+
this.user,
27+
});
28+
29+
@override
30+
final ActivityFeedbackEventPayload activityFeedback;
31+
32+
@override
33+
@EpochDateTimeConverter()
34+
final DateTime createdAt;
35+
36+
@override
37+
final Map<String, Object?> custom;
38+
39+
@override
40+
@EpochDateTimeConverter()
41+
final DateTime? receivedAt;
42+
43+
@override
44+
final String type;
45+
46+
@override
47+
final UserResponseCommonFields? user;
48+
49+
Map<String, dynamic> toJson() => _$ActivityFeedbackEventToJson(this);
50+
51+
static ActivityFeedbackEvent fromJson(Map<String, dynamic> json) =>
52+
_$ActivityFeedbackEventFromJson(json);
53+
}

0 commit comments

Comments
 (0)