@bid-scents/shared-sdk 1.1.1 → 1.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/index.d.ts +3 -4
- package/dist/api/index.d.ts.map +1 -1
- package/dist/api/models/ConversationResponse.d.ts +2 -2
- package/dist/api/models/ConversationResponse.d.ts.map +1 -1
- package/dist/api/models/ConversationSummary.d.ts +2 -2
- package/dist/api/models/ConversationSummary.d.ts.map +1 -1
- package/dist/api/models/MessageRequest.d.ts +1 -2
- package/dist/api/models/MessageRequest.d.ts.map +1 -1
- package/dist/api/models/MessageResData.d.ts +2 -2
- package/dist/api/models/MessageResData.d.ts.map +1 -1
- package/dist/api/models/PaymentResponse.d.ts +18 -0
- package/dist/api/models/PaymentResponse.d.ts.map +1 -0
- package/dist/api/models/RichInitiateActionContent.d.ts +29 -0
- package/dist/api/models/RichInitiateActionContent.d.ts.map +1 -0
- package/dist/api/models/TransactionRequest.d.ts +26 -0
- package/dist/api/models/TransactionRequest.d.ts.map +1 -0
- package/dist/api/services/ListingService.d.ts +9 -0
- package/dist/api/services/ListingService.d.ts.map +1 -1
- package/dist/api/services/ListingService.js +21 -0
- package/dist/api/services/MessageService.d.ts +2 -3
- package/dist/api/services/MessageService.d.ts.map +1 -1
- package/dist/api/services/MessageService.js +1 -1
- package/dist/api/services/NotificationsService.js +1 -1
- package/dist/api/services/PaymentsService.d.ts +29 -10
- package/dist/api/services/PaymentsService.d.ts.map +1 -1
- package/dist/api/services/PaymentsService.js +54 -9
- package/dist/api/services/ProfileService.d.ts +20 -0
- package/dist/api/services/ProfileService.d.ts.map +1 -1
- package/dist/api/services/ProfileService.js +50 -0
- package/dist/stores/auth.d.ts +15 -0
- package/dist/stores/auth.d.ts.map +1 -1
- package/dist/stores/auth.js +31 -5
- package/package.json +1 -1
- package/dist/api/models/ActionContent.d.ts +0 -12
- package/dist/api/models/ActionContent.d.ts.map +0 -1
- package/dist/api/models/BoostResponse.d.ts +0 -22
- package/dist/api/models/BoostResponse.d.ts.map +0 -1
- package/dist/api/models/Message.d.ts +0 -28
- package/dist/api/models/Message.d.ts.map +0 -1
- package/dist/api/models/RichActionContent.d.ts +0 -13
- package/dist/api/models/RichActionContent.d.ts.map +0 -1
- package/dist/api/models/RichActionContent.js +0 -1
- /package/dist/api/models/{ActionContent.js → PaymentResponse.js} +0 -0
- /package/dist/api/models/{BoostResponse.js → RichInitiateActionContent.js} +0 -0
- /package/dist/api/models/{Message.js → TransactionRequest.js} +0 -0
package/dist/api/index.d.ts
CHANGED
|
@@ -2,7 +2,6 @@ export { ApiError } from './core/ApiError';
|
|
|
2
2
|
export { CancelablePromise, CancelError } from './core/CancelablePromise';
|
|
3
3
|
export { OpenAPI } from './core/OpenAPI';
|
|
4
4
|
export type { OpenAPIConfig } from './core/OpenAPI';
|
|
5
|
-
export type { ActionContent } from './models/ActionContent';
|
|
6
5
|
export type { AddTokenRequest } from './models/AddTokenRequest';
|
|
7
6
|
export type { Auction } from './models/Auction';
|
|
8
7
|
export type { AuctionDetails } from './models/AuctionDetails';
|
|
@@ -14,7 +13,6 @@ export type { BidRequest } from './models/BidRequest';
|
|
|
14
13
|
export type { BidResData } from './models/BidResData';
|
|
15
14
|
export type { BidResponse } from './models/BidResponse';
|
|
16
15
|
export type { BoostRequest } from './models/BoostRequest';
|
|
17
|
-
export type { BoostResponse } from './models/BoostResponse';
|
|
18
16
|
export { BoostType } from './models/BoostType';
|
|
19
17
|
export type { CheckUniqueUsernameResponse } from './models/CheckUniqueUsernameResponse';
|
|
20
18
|
export type { CommentContent } from './models/CommentContent';
|
|
@@ -50,7 +48,6 @@ export { ListingStatus } from './models/ListingStatus';
|
|
|
50
48
|
export type { ListingTab } from './models/ListingTab';
|
|
51
49
|
export { ListingType } from './models/ListingType';
|
|
52
50
|
export type { LoginResponse } from './models/LoginResponse';
|
|
53
|
-
export type { Message } from './models/Message';
|
|
54
51
|
export { MessageActionType } from './models/MessageActionType';
|
|
55
52
|
export type { MessageContent } from './models/MessageContent';
|
|
56
53
|
export type { MessageRequest } from './models/MessageRequest';
|
|
@@ -67,6 +64,7 @@ export type { OutbidContent } from './models/OutbidContent';
|
|
|
67
64
|
export type { PaginationDetails } from './models/PaginationDetails';
|
|
68
65
|
export type { Participant } from './models/Participant';
|
|
69
66
|
export { PassType } from './models/PassType';
|
|
67
|
+
export type { PaymentResponse } from './models/PaymentResponse';
|
|
70
68
|
export type { PreferencesResponse } from './models/PreferencesResponse';
|
|
71
69
|
export type { ProfileDetails } from './models/ProfileDetails';
|
|
72
70
|
export type { ProfileResponse } from './models/ProfileResponse';
|
|
@@ -75,13 +73,14 @@ export type { ReviewDetails } from './models/ReviewDetails';
|
|
|
75
73
|
export type { ReviewSearchRequest } from './models/ReviewSearchRequest';
|
|
76
74
|
export { ReviewSortField } from './models/ReviewSortField';
|
|
77
75
|
export type { ReviewsTab } from './models/ReviewsTab';
|
|
78
|
-
export type {
|
|
76
|
+
export type { RichInitiateActionContent } from './models/RichInitiateActionContent';
|
|
79
77
|
export type { RichTextContent } from './models/RichTextContent';
|
|
80
78
|
export type { SearchRequest } from './models/SearchRequest';
|
|
81
79
|
export type { SearchResponse } from './models/SearchResponse';
|
|
82
80
|
export type { SortParameter } from './models/SortParameter';
|
|
83
81
|
export type { SubscriptionRequest } from './models/SubscriptionRequest';
|
|
84
82
|
export type { TextContent } from './models/TextContent';
|
|
83
|
+
export type { TransactionRequest } from './models/TransactionRequest';
|
|
85
84
|
export type { TypingReqData } from './models/TypingReqData';
|
|
86
85
|
export type { TypingResData } from './models/TypingResData';
|
|
87
86
|
export type { UpdateLastReadData } from './models/UpdateLastReadData';
|
package/dist/api/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/api/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EAAE,iBAAiB,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Y,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,YAAY,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACxE,YAAY,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9D,YAAY,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AACpE,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,YAAY,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAEhE,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAC7D,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AACvE,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ConversationType } from './ConversationType';
|
|
2
|
-
import type {
|
|
2
|
+
import type { MessageResData } from './MessageResData';
|
|
3
3
|
import type { Participant } from './Participant';
|
|
4
4
|
export type ConversationResponse = {
|
|
5
5
|
/**
|
|
@@ -25,6 +25,6 @@ export type ConversationResponse = {
|
|
|
25
25
|
/**
|
|
26
26
|
* List of messages in the conversation
|
|
27
27
|
*/
|
|
28
|
-
messages: Array<
|
|
28
|
+
messages: Array<MessageResData>;
|
|
29
29
|
};
|
|
30
30
|
//# sourceMappingURL=ConversationResponse.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConversationResponse.d.ts","sourceRoot":"","sources":["../../../src/api/models/ConversationResponse.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"ConversationResponse.d.ts","sourceRoot":"","sources":["../../../src/api/models/ConversationResponse.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,MAAM,MAAM,oBAAoB,GAAG;IAC/B;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IACX;;OAEG;IACH,IAAI,EAAE,gBAAgB,CAAC;IACvB;;OAEG;IACH,IAAI,CAAC,EAAE,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IACvB;;OAEG;IACH,aAAa,CAAC,EAAE,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAChC;;OAEG;IACH,YAAY,EAAE,KAAK,CAAC,WAAW,CAAC,CAAC;IACjC;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,cAAc,CAAC,CAAC;CACnC,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ConversationType } from './ConversationType';
|
|
2
|
-
import type {
|
|
2
|
+
import type { MessageResData } from './MessageResData';
|
|
3
3
|
import type { UserPreview } from './UserPreview';
|
|
4
4
|
export type ConversationSummary = {
|
|
5
5
|
/**
|
|
@@ -29,6 +29,6 @@ export type ConversationSummary = {
|
|
|
29
29
|
/**
|
|
30
30
|
* The last message in the conversation, if available
|
|
31
31
|
*/
|
|
32
|
-
last_message?: (
|
|
32
|
+
last_message?: (MessageResData | null);
|
|
33
33
|
};
|
|
34
34
|
//# sourceMappingURL=ConversationSummary.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConversationSummary.d.ts","sourceRoot":"","sources":["../../../src/api/models/ConversationSummary.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"ConversationSummary.d.ts","sourceRoot":"","sources":["../../../src/api/models/ConversationSummary.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,MAAM,MAAM,mBAAmB,GAAG;IAC9B;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IACX;;OAEG;IACH,aAAa,CAAC,EAAE,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAChC;;OAEG;IACH,IAAI,EAAE,gBAAgB,CAAC;IACvB;;OAEG;IACH,IAAI,CAAC,EAAE,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IACvB;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,YAAY,EAAE,KAAK,CAAC,WAAW,CAAC,CAAC;IACjC;;OAEG;IACH,YAAY,CAAC,EAAE,CAAC,cAAc,GAAG,IAAI,CAAC,CAAC;CAC1C,CAAC"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { ActionContent } from './ActionContent';
|
|
2
1
|
import type { FileContent } from './FileContent';
|
|
3
2
|
import type { MessageType } from './MessageType';
|
|
4
3
|
import type { TextContent } from './TextContent';
|
|
@@ -10,6 +9,6 @@ export type MessageRequest = {
|
|
|
10
9
|
/**
|
|
11
10
|
* Content of the message
|
|
12
11
|
*/
|
|
13
|
-
content: (TextContent | FileContent
|
|
12
|
+
content: (TextContent | FileContent);
|
|
14
13
|
};
|
|
15
14
|
//# sourceMappingURL=MessageRequest.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageRequest.d.ts","sourceRoot":"","sources":["../../../src/api/models/MessageRequest.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"MessageRequest.d.ts","sourceRoot":"","sources":["../../../src/api/models/MessageRequest.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,MAAM,MAAM,cAAc,GAAG;IACzB;;OAEG;IACH,YAAY,EAAE,WAAW,CAAC;IAC1B;;OAEG;IACH,OAAO,EAAE,CAAC,WAAW,GAAG,WAAW,CAAC,CAAC;CACxC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { FileContent } from './FileContent';
|
|
2
2
|
import type { MessageType } from './MessageType';
|
|
3
|
-
import type {
|
|
3
|
+
import type { RichInitiateActionContent } from './RichInitiateActionContent';
|
|
4
4
|
import type { RichTextContent } from './RichTextContent';
|
|
5
5
|
import type { UserPreview } from './UserPreview';
|
|
6
6
|
export type MessageResData = {
|
|
@@ -19,7 +19,7 @@ export type MessageResData = {
|
|
|
19
19
|
/**
|
|
20
20
|
* Content of the message
|
|
21
21
|
*/
|
|
22
|
-
content: (RichTextContent | FileContent |
|
|
22
|
+
content: (RichTextContent | FileContent | RichInitiateActionContent);
|
|
23
23
|
/**
|
|
24
24
|
* Information about the user who sent the message
|
|
25
25
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageResData.d.ts","sourceRoot":"","sources":["../../../src/api/models/MessageResData.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"MessageResData.d.ts","sourceRoot":"","sources":["../../../src/api/models/MessageResData.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAC;AAC7E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,MAAM,MAAM,cAAc,GAAG;IACzB;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IACX;;OAEG;IACH,eAAe,EAAE,MAAM,CAAC;IACxB;;OAEG;IACH,YAAY,EAAE,WAAW,CAAC;IAC1B;;OAEG;IACH,OAAO,EAAE,CAAC,eAAe,GAAG,WAAW,GAAG,yBAAyB,CAAC,CAAC;IACrE;;OAEG;IACH,MAAM,EAAE,WAAW,CAAC;IACpB;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;CACtB,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Model for the response returned after a payment request
|
|
3
|
+
*/
|
|
4
|
+
export type PaymentResponse = {
|
|
5
|
+
/**
|
|
6
|
+
* The client secret for the payment intent if the user has to pay
|
|
7
|
+
*/
|
|
8
|
+
client_secret?: (string | null);
|
|
9
|
+
/**
|
|
10
|
+
* The amount to be charged.
|
|
11
|
+
*/
|
|
12
|
+
amount: number;
|
|
13
|
+
/**
|
|
14
|
+
* The currency of the payment.
|
|
15
|
+
*/
|
|
16
|
+
currency: string;
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=PaymentResponse.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PaymentResponse.d.ts","sourceRoot":"","sources":["../../../src/api/models/PaymentResponse.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAC1B;;OAEG;IACH,aAAa,CAAC,EAAE,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAChC;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CACpB,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { ListingPreview } from './ListingPreview';
|
|
2
|
+
import type { MessageActionType } from './MessageActionType';
|
|
3
|
+
export type RichInitiateActionContent = {
|
|
4
|
+
/**
|
|
5
|
+
* Type of the action
|
|
6
|
+
*/
|
|
7
|
+
action_type: MessageActionType;
|
|
8
|
+
/**
|
|
9
|
+
* Listing associated with the action
|
|
10
|
+
*/
|
|
11
|
+
listing?: (ListingPreview | null);
|
|
12
|
+
/**
|
|
13
|
+
* Unit price of the listing
|
|
14
|
+
*/
|
|
15
|
+
unit_price: number;
|
|
16
|
+
/**
|
|
17
|
+
* Quantity of the listing
|
|
18
|
+
*/
|
|
19
|
+
quantity: number;
|
|
20
|
+
/**
|
|
21
|
+
* ID of the buyer
|
|
22
|
+
*/
|
|
23
|
+
buyer_id: string;
|
|
24
|
+
/**
|
|
25
|
+
* Indicates if the action is active
|
|
26
|
+
*/
|
|
27
|
+
is_active: boolean;
|
|
28
|
+
};
|
|
29
|
+
//# sourceMappingURL=RichInitiateActionContent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RichInitiateActionContent.d.ts","sourceRoot":"","sources":["../../../src/api/models/RichInitiateActionContent.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC7D,MAAM,MAAM,yBAAyB,GAAG;IACpC;;OAEG;IACH,WAAW,EAAE,iBAAiB,CAAC;IAC/B;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,cAAc,GAAG,IAAI,CAAC,CAAC;IAClC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,SAAS,EAAE,OAAO,CAAC;CACtB,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Model for creating a transaction
|
|
3
|
+
*/
|
|
4
|
+
export type TransactionRequest = {
|
|
5
|
+
/**
|
|
6
|
+
* ID of the listing to create a transaction for
|
|
7
|
+
*/
|
|
8
|
+
listing_id: string;
|
|
9
|
+
/**
|
|
10
|
+
* ID of the conversation the transaction is created in
|
|
11
|
+
*/
|
|
12
|
+
conversation_id: string;
|
|
13
|
+
/**
|
|
14
|
+
* ID of the buyer the transaction is for
|
|
15
|
+
*/
|
|
16
|
+
buyer_id: string;
|
|
17
|
+
/**
|
|
18
|
+
* The amount to be charged for the transaction
|
|
19
|
+
*/
|
|
20
|
+
unit_price: number;
|
|
21
|
+
/**
|
|
22
|
+
* The quantity of items being purchased
|
|
23
|
+
*/
|
|
24
|
+
quantity: number;
|
|
25
|
+
};
|
|
26
|
+
//# sourceMappingURL=TransactionRequest.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransactionRequest.d.ts","sourceRoot":"","sources":["../../../src/api/models/TransactionRequest.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAC7B;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,eAAe,EAAE,MAAM,CAAC;IACxB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CACpB,CAAC"}
|
|
@@ -89,5 +89,14 @@ export declare class ListingService {
|
|
|
89
89
|
* @throws ApiError
|
|
90
90
|
*/
|
|
91
91
|
static searchListingsV1ListingSearchPost(requestBody: SearchRequest): CancelablePromise<SearchResponse>;
|
|
92
|
+
/**
|
|
93
|
+
* Get Sellers You Follow Listings
|
|
94
|
+
* Get all listings from sellers that the user follows.
|
|
95
|
+
* @param cursor Timestamp of last listing in ISO format
|
|
96
|
+
* @param limit
|
|
97
|
+
* @returns ListingCard Successful Response
|
|
98
|
+
* @throws ApiError
|
|
99
|
+
*/
|
|
100
|
+
static getSellersYouFollowListingsV1ListingSellersYouFollowGet(cursor?: string, limit?: number): CancelablePromise<Array<ListingCard>>;
|
|
92
101
|
}
|
|
93
102
|
//# sourceMappingURL=ListingService.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ListingService.d.ts","sourceRoot":"","sources":["../../../src/api/services/ListingService.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,kCAAkC,CAAC;AAC/E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAGnE,qBAAa,cAAc;IACvB;;;;;;OAMG;WACW,6CAA6C,CACvD,SAAS,EAAE,MAAM,GA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WpC;;;;;;;OAOG;WACW,uDAAuD,CACjE,MAAM,CAAC,EAAE,MAAM,EACf,KAAK,GAAE,MAAW,GACnB,iBAAiB,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;CAa3C"}
|
|
@@ -193,4 +193,25 @@ export class ListingService {
|
|
|
193
193
|
},
|
|
194
194
|
});
|
|
195
195
|
}
|
|
196
|
+
/**
|
|
197
|
+
* Get Sellers You Follow Listings
|
|
198
|
+
* Get all listings from sellers that the user follows.
|
|
199
|
+
* @param cursor Timestamp of last listing in ISO format
|
|
200
|
+
* @param limit
|
|
201
|
+
* @returns ListingCard Successful Response
|
|
202
|
+
* @throws ApiError
|
|
203
|
+
*/
|
|
204
|
+
static getSellersYouFollowListingsV1ListingSellersYouFollowGet(cursor, limit = 10) {
|
|
205
|
+
return __request(OpenAPI, {
|
|
206
|
+
method: 'GET',
|
|
207
|
+
url: '/v1/listing/sellers-you-follow',
|
|
208
|
+
query: {
|
|
209
|
+
'cursor': cursor,
|
|
210
|
+
'limit': limit,
|
|
211
|
+
},
|
|
212
|
+
errors: {
|
|
213
|
+
422: `Validation Error`,
|
|
214
|
+
},
|
|
215
|
+
});
|
|
216
|
+
}
|
|
196
217
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { ConversationResponse } from '../models/ConversationResponse';
|
|
2
|
-
import type { Message } from '../models/Message';
|
|
3
2
|
import type { MessageRequest } from '../models/MessageRequest';
|
|
4
3
|
import type { MessageResData } from '../models/MessageResData';
|
|
5
4
|
import type { MessagesSummary } from '../models/MessagesSummary';
|
|
@@ -52,10 +51,10 @@ export declare class MessageService {
|
|
|
52
51
|
* @param conversationId
|
|
53
52
|
* @param cursor Timestamp of last cursor in ISO format
|
|
54
53
|
* @param limit
|
|
55
|
-
* @returns
|
|
54
|
+
* @returns MessageResData Successful Response
|
|
56
55
|
* @throws ApiError
|
|
57
56
|
*/
|
|
58
|
-
static getMessagesV1MessageMessagesConversationIdGet(conversationId: string, cursor: string, limit?: number): CancelablePromise<Array<
|
|
57
|
+
static getMessagesV1MessageMessagesConversationIdGet(conversationId: string, cursor: string, limit?: number): CancelablePromise<Array<MessageResData>>;
|
|
59
58
|
/**
|
|
60
59
|
* Get Ws Types
|
|
61
60
|
* Dummy endpoint so openapi codegen can generate the WebSocket types.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageService.d.ts","sourceRoot":"","sources":["../../../src/api/services/MessageService.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAC3E,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"MessageService.d.ts","sourceRoot":"","sources":["../../../src/api/services/MessageService.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAC3E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AACrE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAGnE,qBAAa,cAAc;IACvB;;;;;;OAMG;WACW,sCAAsC,CAChD,cAAc,EAAE,MAAM,EACtB,WAAW,EAAE,cAAc,GAC5B,iBAAiB,CAAC,cAAc,CAAC;IAcpC;;;;;;OAMG;WACW,8CAA8C,CACxD,QAAQ,EAAE,MAAM,GACjB,iBAAiB,CAAC,oBAAoB,CAAC;IAY1C;;;;;;OAMG;WACW,0CAA0C,CACpD,cAAc,EAAE,MAAM,GACvB,iBAAiB,CAAC,IAAI,CAAC;IAY1B;;;;;;OAMG;WACW,qDAAqD,CAC/D,cAAc,EAAE,MAAM,GACvB,iBAAiB,CAAC,oBAAoB,CAAC;IAY1C;;;;;OAKG;WACW,yCAAyC,IAAI,iBAAiB,CAAC,eAAe,CAAC;IAM7F;;;;;;;;OAQG;WACW,6CAA6C,CACvD,cAAc,EAAE,MAAM,EACtB,MAAM,EAAE,MAAM,EACd,KAAK,GAAE,MAAW,GACnB,iBAAiB,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;IAgB3C;;;;;;OAMG;WACW,6BAA6B,CACvC,WAAW,EAAE,CAAC,eAAe,GAAG,IAAI,CAAC,GACtC,iBAAiB,CAAC,iBAAiB,CAAC;CAW1C"}
|
|
@@ -97,7 +97,7 @@ export class MessageService {
|
|
|
97
97
|
* @param conversationId
|
|
98
98
|
* @param cursor Timestamp of last cursor in ISO format
|
|
99
99
|
* @param limit
|
|
100
|
-
* @returns
|
|
100
|
+
* @returns MessageResData Successful Response
|
|
101
101
|
* @throws ApiError
|
|
102
102
|
*/
|
|
103
103
|
static getMessagesV1MessageMessagesConversationIdGet(conversationId, cursor, limit = 20) {
|
|
@@ -69,7 +69,7 @@ export class NotificationsService {
|
|
|
69
69
|
* @returns NotificationResponse Successful Response
|
|
70
70
|
* @throws ApiError
|
|
71
71
|
*/
|
|
72
|
-
static getNotificationsV1NotificationsGet(cursor = '2025-08-
|
|
72
|
+
static getNotificationsV1NotificationsGet(cursor = '2025-08-23T15:40:46.555589+00:00', limit = 20) {
|
|
73
73
|
return __request(OpenAPI, {
|
|
74
74
|
method: 'GET',
|
|
75
75
|
url: '/v1/notifications/',
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import type { BoostRequest } from '../models/BoostRequest';
|
|
2
|
-
import type {
|
|
2
|
+
import type { MessageResData } from '../models/MessageResData';
|
|
3
|
+
import type { PaymentResponse } from '../models/PaymentResponse';
|
|
3
4
|
import type { SubscriptionRequest } from '../models/SubscriptionRequest';
|
|
5
|
+
import type { TransactionRequest } from '../models/TransactionRequest';
|
|
4
6
|
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
5
7
|
export declare class PaymentsService {
|
|
6
8
|
/**
|
|
@@ -8,17 +10,17 @@ export declare class PaymentsService {
|
|
|
8
10
|
* Create a payment intent for boosting listings.
|
|
9
11
|
* This endpoint processes the boost request and returns a payment intent client secret.
|
|
10
12
|
* @param requestBody
|
|
11
|
-
* @returns
|
|
13
|
+
* @returns PaymentResponse Successful Response
|
|
12
14
|
* @throws ApiError
|
|
13
15
|
*/
|
|
14
|
-
static boostListingV1PaymentsBoostPost(requestBody: BoostRequest): CancelablePromise<
|
|
16
|
+
static boostListingV1PaymentsBoostPost(requestBody: BoostRequest): CancelablePromise<PaymentResponse>;
|
|
15
17
|
/**
|
|
16
18
|
* Setup Payment Method
|
|
17
19
|
* Sets up a payment method for a user
|
|
18
|
-
* @returns
|
|
20
|
+
* @returns string Successful Response
|
|
19
21
|
* @throws ApiError
|
|
20
22
|
*/
|
|
21
|
-
static setupPaymentMethodV1PaymentsPaymentMethodPost(): CancelablePromise<
|
|
23
|
+
static setupPaymentMethodV1PaymentsPaymentMethodPost(): CancelablePromise<string>;
|
|
22
24
|
/**
|
|
23
25
|
* Create Subscription
|
|
24
26
|
* Creates/updates subscription to swap pass for a user
|
|
@@ -56,12 +58,29 @@ export declare class PaymentsService {
|
|
|
56
58
|
*/
|
|
57
59
|
static stripeWebhookV1PaymentsWebhookPost(): CancelablePromise<void>;
|
|
58
60
|
/**
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
* @
|
|
61
|
+
* Onboard Connect Account
|
|
62
|
+
* Creates connect account for a user
|
|
63
|
+
* @param refreshUrl
|
|
64
|
+
* @param returnUrl
|
|
65
|
+
* @returns string Successful Response
|
|
66
|
+
* @throws ApiError
|
|
67
|
+
*/
|
|
68
|
+
static onboardConnectAccountV1PaymentsConnectOnboardPost(refreshUrl: string, returnUrl: string): CancelablePromise<string>;
|
|
69
|
+
/**
|
|
70
|
+
* Create Transaction
|
|
71
|
+
* Creates a transaction for a listing in messages
|
|
72
|
+
* @param requestBody
|
|
73
|
+
* @returns MessageResData Successful Response
|
|
74
|
+
* @throws ApiError
|
|
75
|
+
*/
|
|
76
|
+
static createTransactionV1PaymentsTransactionPost(requestBody: TransactionRequest): CancelablePromise<MessageResData>;
|
|
77
|
+
/**
|
|
78
|
+
* Accept Transaction
|
|
79
|
+
* Accepts a transaction
|
|
80
|
+
* @param messageId
|
|
81
|
+
* @returns PaymentResponse Successful Response
|
|
63
82
|
* @throws ApiError
|
|
64
83
|
*/
|
|
65
|
-
static
|
|
84
|
+
static acceptTransactionV1PaymentsMessageIdAcceptPost(messageId: string): CancelablePromise<PaymentResponse>;
|
|
66
85
|
}
|
|
67
86
|
//# sourceMappingURL=PaymentsService.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaymentsService.d.ts","sourceRoot":"","sources":["../../../src/api/services/PaymentsService.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"PaymentsService.d.ts","sourceRoot":"","sources":["../../../src/api/services/PaymentsService.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAC;AACvE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAGnE,qBAAa,eAAe;IACxB;;;;;;;OAOG;WACW,+BAA+B,CACzC,WAAW,EAAE,YAAY,GAC1B,iBAAiB,CAAC,eAAe,CAAC;IAWrC;;;;;OAKG;WACW,6CAA6C,IAAI,iBAAiB,CAAC,MAAM,CAAC;IAMxF;;;;;;OAMG;WACW,4CAA4C,CACtD,WAAW,EAAE,mBAAmB,GACjC,iBAAiB,CAAC,IAAI,CAAC;IAW1B;;;;;OAKG;WACW,8CAA8C,IAAI,iBAAiB,CAAC,IAAI,CAAC;IAMvF;;;;OAIG;WACW,iCAAiC,IAAI,iBAAiB,CAAC,GAAG,CAAC;IAMzE;;;;;OAKG;WACW,+BAA+B,IAAI,iBAAiB,CAAC,GAAG,CAAC;IAMvE;;;;;;OAMG;WACW,kCAAkC,IAAI,iBAAiB,CAAC,IAAI,CAAC;IAM3E;;;;;;;OAOG;WACW,iDAAiD,CAC3D,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,GAClB,iBAAiB,CAAC,MAAM,CAAC;IAa5B;;;;;;OAMG;WACW,0CAA0C,CACpD,WAAW,EAAE,kBAAkB,GAChC,iBAAiB,CAAC,cAAc,CAAC;IAWpC;;;;;;OAMG;WACW,8CAA8C,CACxD,SAAS,EAAE,MAAM,GAClB,iBAAiB,CAAC,eAAe,CAAC;CAYxC"}
|
|
@@ -6,7 +6,7 @@ export class PaymentsService {
|
|
|
6
6
|
* Create a payment intent for boosting listings.
|
|
7
7
|
* This endpoint processes the boost request and returns a payment intent client secret.
|
|
8
8
|
* @param requestBody
|
|
9
|
-
* @returns
|
|
9
|
+
* @returns PaymentResponse Successful Response
|
|
10
10
|
* @throws ApiError
|
|
11
11
|
*/
|
|
12
12
|
static boostListingV1PaymentsBoostPost(requestBody) {
|
|
@@ -23,7 +23,7 @@ export class PaymentsService {
|
|
|
23
23
|
/**
|
|
24
24
|
* Setup Payment Method
|
|
25
25
|
* Sets up a payment method for a user
|
|
26
|
-
* @returns
|
|
26
|
+
* @returns string Successful Response
|
|
27
27
|
* @throws ApiError
|
|
28
28
|
*/
|
|
29
29
|
static setupPaymentMethodV1PaymentsPaymentMethodPost() {
|
|
@@ -99,16 +99,61 @@ export class PaymentsService {
|
|
|
99
99
|
});
|
|
100
100
|
}
|
|
101
101
|
/**
|
|
102
|
-
*
|
|
103
|
-
*
|
|
104
|
-
*
|
|
105
|
-
* @
|
|
102
|
+
* Onboard Connect Account
|
|
103
|
+
* Creates connect account for a user
|
|
104
|
+
* @param refreshUrl
|
|
105
|
+
* @param returnUrl
|
|
106
|
+
* @returns string Successful Response
|
|
106
107
|
* @throws ApiError
|
|
107
108
|
*/
|
|
108
|
-
static
|
|
109
|
+
static onboardConnectAccountV1PaymentsConnectOnboardPost(refreshUrl, returnUrl) {
|
|
109
110
|
return __request(OpenAPI, {
|
|
110
|
-
method: '
|
|
111
|
-
url: '/v1/payments/
|
|
111
|
+
method: 'POST',
|
|
112
|
+
url: '/v1/payments/connect/onboard',
|
|
113
|
+
query: {
|
|
114
|
+
'refresh_url': refreshUrl,
|
|
115
|
+
'return_url': returnUrl,
|
|
116
|
+
},
|
|
117
|
+
errors: {
|
|
118
|
+
422: `Validation Error`,
|
|
119
|
+
},
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
/**
|
|
123
|
+
* Create Transaction
|
|
124
|
+
* Creates a transaction for a listing in messages
|
|
125
|
+
* @param requestBody
|
|
126
|
+
* @returns MessageResData Successful Response
|
|
127
|
+
* @throws ApiError
|
|
128
|
+
*/
|
|
129
|
+
static createTransactionV1PaymentsTransactionPost(requestBody) {
|
|
130
|
+
return __request(OpenAPI, {
|
|
131
|
+
method: 'POST',
|
|
132
|
+
url: '/v1/payments/transaction',
|
|
133
|
+
body: requestBody,
|
|
134
|
+
mediaType: 'application/json',
|
|
135
|
+
errors: {
|
|
136
|
+
422: `Validation Error`,
|
|
137
|
+
},
|
|
138
|
+
});
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Accept Transaction
|
|
142
|
+
* Accepts a transaction
|
|
143
|
+
* @param messageId
|
|
144
|
+
* @returns PaymentResponse Successful Response
|
|
145
|
+
* @throws ApiError
|
|
146
|
+
*/
|
|
147
|
+
static acceptTransactionV1PaymentsMessageIdAcceptPost(messageId) {
|
|
148
|
+
return __request(OpenAPI, {
|
|
149
|
+
method: 'POST',
|
|
150
|
+
url: '/v1/payments/{message_id}/accept',
|
|
151
|
+
path: {
|
|
152
|
+
'message_id': messageId,
|
|
153
|
+
},
|
|
154
|
+
errors: {
|
|
155
|
+
422: `Validation Error`,
|
|
156
|
+
},
|
|
112
157
|
});
|
|
113
158
|
}
|
|
114
159
|
}
|
|
@@ -60,6 +60,26 @@ export declare class ProfileService {
|
|
|
60
60
|
* @throws ApiError
|
|
61
61
|
*/
|
|
62
62
|
static getUserPreviewV1ProfileUserIdPreviewGet(userId: string): CancelablePromise<UserPreview>;
|
|
63
|
+
/**
|
|
64
|
+
* Get User Followers
|
|
65
|
+
* Gets followers for a user
|
|
66
|
+
* @param userId
|
|
67
|
+
* @param cursor Timestamp for last follow
|
|
68
|
+
* @param limit
|
|
69
|
+
* @returns UserPreview Successful Response
|
|
70
|
+
* @throws ApiError
|
|
71
|
+
*/
|
|
72
|
+
static getUserFollowersV1ProfileUserIdFollowersGet(userId: string, cursor?: string, limit?: number): CancelablePromise<Array<UserPreview>>;
|
|
73
|
+
/**
|
|
74
|
+
* Get User Following
|
|
75
|
+
* Gets users that a specific user is following
|
|
76
|
+
* @param userId
|
|
77
|
+
* @param cursor Timestamp for last follow
|
|
78
|
+
* @param limit
|
|
79
|
+
* @returns UserPreview Successful Response
|
|
80
|
+
* @throws ApiError
|
|
81
|
+
*/
|
|
82
|
+
static getUserFollowingV1ProfileUserIdFollowingGet(userId: string, cursor?: string, limit?: number): CancelablePromise<Array<UserPreview>>;
|
|
63
83
|
/**
|
|
64
84
|
* Get User Listings
|
|
65
85
|
* Get (more) listings for a user based on tab.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProfileService.d.ts","sourceRoot":"","sources":["../../../src/api/services/ProfileService.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,kBAAkB,E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IAAI,CAAC;IAc1B;;;;;;;OAOG;WACW,uCAAuC,CACjD,MAAM,EAAE,MAAM,GACf,iBAAiB,CAAC,WAAW,CAAC;IAYjC;;;;;;;;OAQG;WACW,2CAA2C,CACrD,MAAM,EAAE,MAAM,EACd,MAAM,GAAE,MAA2C,EACnD,KAAK,GAAE,MAAW,GACnB,iBAAiB,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;IAgBxC;;;;;;;;OAQG;WACW,2CAA2C,CACrD,MAAM,EAAE,MAAM,EACd,MAAM,GAAE,MAA2C,EACnD,KAAK,GAAE,MAAW,GACnB,iBAAiB,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;IAgBxC;;;;;;;;OAQG;WACW,yCAAyC,CACnD,MAAM,EAAE,MAAM,EACd,OAAO,EAAE,UAAU,EACnB,WAAW,EAAE,oBAAoB,GAClC,iBAAiB,CAAC,UAAU,CAAC;CAenC"}
|
|
@@ -122,6 +122,56 @@ export class ProfileService {
|
|
|
122
122
|
},
|
|
123
123
|
});
|
|
124
124
|
}
|
|
125
|
+
/**
|
|
126
|
+
* Get User Followers
|
|
127
|
+
* Gets followers for a user
|
|
128
|
+
* @param userId
|
|
129
|
+
* @param cursor Timestamp for last follow
|
|
130
|
+
* @param limit
|
|
131
|
+
* @returns UserPreview Successful Response
|
|
132
|
+
* @throws ApiError
|
|
133
|
+
*/
|
|
134
|
+
static getUserFollowersV1ProfileUserIdFollowersGet(userId, cursor = '2025-08-23T15:40:46.539164+00:00', limit = 20) {
|
|
135
|
+
return __request(OpenAPI, {
|
|
136
|
+
method: 'GET',
|
|
137
|
+
url: '/v1/profile/{user_id}/followers',
|
|
138
|
+
path: {
|
|
139
|
+
'user_id': userId,
|
|
140
|
+
},
|
|
141
|
+
query: {
|
|
142
|
+
'cursor': cursor,
|
|
143
|
+
'limit': limit,
|
|
144
|
+
},
|
|
145
|
+
errors: {
|
|
146
|
+
422: `Validation Error`,
|
|
147
|
+
},
|
|
148
|
+
});
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* Get User Following
|
|
152
|
+
* Gets users that a specific user is following
|
|
153
|
+
* @param userId
|
|
154
|
+
* @param cursor Timestamp for last follow
|
|
155
|
+
* @param limit
|
|
156
|
+
* @returns UserPreview Successful Response
|
|
157
|
+
* @throws ApiError
|
|
158
|
+
*/
|
|
159
|
+
static getUserFollowingV1ProfileUserIdFollowingGet(userId, cursor = '2025-08-23T15:40:46.539799+00:00', limit = 20) {
|
|
160
|
+
return __request(OpenAPI, {
|
|
161
|
+
method: 'GET',
|
|
162
|
+
url: '/v1/profile/{user_id}/following',
|
|
163
|
+
path: {
|
|
164
|
+
'user_id': userId,
|
|
165
|
+
},
|
|
166
|
+
query: {
|
|
167
|
+
'cursor': cursor,
|
|
168
|
+
'limit': limit,
|
|
169
|
+
},
|
|
170
|
+
errors: {
|
|
171
|
+
422: `Validation Error`,
|
|
172
|
+
},
|
|
173
|
+
});
|
|
174
|
+
}
|
|
125
175
|
/**
|
|
126
176
|
* Get User Listings
|
|
127
177
|
* Get (more) listings for a user based on tab.
|
package/dist/stores/auth.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { User } from '../api/models/User';
|
|
2
|
+
import type { LoginResponse } from '../api/models/LoginResponse';
|
|
2
3
|
interface AuthState {
|
|
3
4
|
user: User | null;
|
|
4
5
|
session: any | null;
|
|
@@ -9,6 +10,7 @@ interface AuthState {
|
|
|
9
10
|
deviceToken: string | null;
|
|
10
11
|
setUser: (user: User | null) => void;
|
|
11
12
|
setSession: (session: any | null) => void;
|
|
13
|
+
setAuthState: (session: any | null, loginResponse: LoginResponse | null) => void;
|
|
12
14
|
setLoading: (loading: boolean) => void;
|
|
13
15
|
setError: (error: string | null) => void;
|
|
14
16
|
logout: () => void;
|
|
@@ -20,6 +22,19 @@ interface AuthState {
|
|
|
20
22
|
* Manages user data, session state, loading states, and errors.
|
|
21
23
|
* Supabase automatically handles token refresh in the background.
|
|
22
24
|
*
|
|
25
|
+
* ## Usage Guidelines:
|
|
26
|
+
*
|
|
27
|
+
* **For complete auth operations (login, OAuth, session establishment):**
|
|
28
|
+
* - Use `setAuthState(session, loginResponse)` - sets all auth state atomically
|
|
29
|
+
* - Prevents race conditions by updating isAuthenticated and isOnboarded together
|
|
30
|
+
*
|
|
31
|
+
* **For partial updates (profile edits, user data changes):**
|
|
32
|
+
* - Use `setUser(user)` - updates only user data without changing auth state
|
|
33
|
+
* - Use `setSession(session)` - updates only session without changing auth state
|
|
34
|
+
*
|
|
35
|
+
* **For clearing all auth state:**
|
|
36
|
+
* - Use `logout()` - clears everything atomically
|
|
37
|
+
*
|
|
23
38
|
* @returns Auth store with user state, session, loading, and actions
|
|
24
39
|
*/
|
|
25
40
|
export declare const useAuthStore: import("zustand").UseBoundStore<Omit<import("zustand").StoreApi<AuthState>, "persist"> & {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/stores/auth.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;
|
|
1
|
+
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/stores/auth.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAA;AAEhE,UAAU,SAAS;IACjB,IAAI,EAAE,IAAI,GAAG,IAAI,CAAA;IACjB,OAAO,EAAE,GAAG,GAAG,IAAI,CAAA;IACnB,eAAe,EAAE,OAAO,CAAA;IACxB,WAAW,EAAE,OAAO,CAAA;IACpB,OAAO,EAAE,OAAO,CAAA;IAChB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAA;IACpB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAA;IAC1B,OAAO,EAAE,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,KAAK,IAAI,CAAA;IACpC,UAAU,EAAE,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,KAAK,IAAI,CAAA;IACzC,YAAY,EAAE,CAAC,OAAO,EAAE,GAAG,GAAG,IAAI,EAAE,aAAa,EAAE,aAAa,GAAG,IAAI,KAAK,IAAI,CAAA;IAChF,UAAU,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAA;IACtC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAA;IACxC,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,cAAc,EAAE,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,CAAA;CACrD;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,YAAY;;;;;;;;;;EA0GxB,CAAA"}
|
package/dist/stores/auth.js
CHANGED
|
@@ -7,6 +7,19 @@ import AsyncStorage from '@react-native-async-storage/async-storage';
|
|
|
7
7
|
* Manages user data, session state, loading states, and errors.
|
|
8
8
|
* Supabase automatically handles token refresh in the background.
|
|
9
9
|
*
|
|
10
|
+
* ## Usage Guidelines:
|
|
11
|
+
*
|
|
12
|
+
* **For complete auth operations (login, OAuth, session establishment):**
|
|
13
|
+
* - Use `setAuthState(session, loginResponse)` - sets all auth state atomically
|
|
14
|
+
* - Prevents race conditions by updating isAuthenticated and isOnboarded together
|
|
15
|
+
*
|
|
16
|
+
* **For partial updates (profile edits, user data changes):**
|
|
17
|
+
* - Use `setUser(user)` - updates only user data without changing auth state
|
|
18
|
+
* - Use `setSession(session)` - updates only session without changing auth state
|
|
19
|
+
*
|
|
20
|
+
* **For clearing all auth state:**
|
|
21
|
+
* - Use `logout()` - clears everything atomically
|
|
22
|
+
*
|
|
10
23
|
* @returns Auth store with user state, session, loading, and actions
|
|
11
24
|
*/
|
|
12
25
|
export const useAuthStore = create()(persist((set) => ({
|
|
@@ -18,28 +31,41 @@ export const useAuthStore = create()(persist((set) => ({
|
|
|
18
31
|
error: null,
|
|
19
32
|
deviceToken: null,
|
|
20
33
|
/**
|
|
21
|
-
* Updates the current user
|
|
34
|
+
* Updates the current user only (without changing auth state).
|
|
35
|
+
* Use setAuthState() for complete auth state updates.
|
|
22
36
|
*
|
|
23
37
|
* @param user - User profile data or null to clear
|
|
24
38
|
*/
|
|
25
39
|
setUser: (user) => {
|
|
26
40
|
set({
|
|
27
41
|
user,
|
|
28
|
-
isOnboarded: !!user?.onboarded_at,
|
|
29
|
-
loading: false, // Clear loading when user is set
|
|
30
42
|
error: null // Clear any errors
|
|
31
43
|
});
|
|
32
44
|
},
|
|
33
45
|
/**
|
|
34
|
-
* Updates the Supabase session
|
|
46
|
+
* Updates the Supabase session only (without changing auth state).
|
|
47
|
+
* Use setAuthState() for complete auth state updates.
|
|
35
48
|
*
|
|
36
49
|
* @param session - Supabase session object containing tokens
|
|
37
50
|
*/
|
|
38
51
|
setSession: (session) => {
|
|
52
|
+
set({ session });
|
|
53
|
+
},
|
|
54
|
+
/**
|
|
55
|
+
* Sets complete authentication state atomically from session and LoginResponse.
|
|
56
|
+
* This prevents race conditions by updating both auth and onboarding status together.
|
|
57
|
+
*
|
|
58
|
+
* @param session - Supabase session object or null
|
|
59
|
+
* @param loginResponse - API response containing onboarded status and user profile
|
|
60
|
+
*/
|
|
61
|
+
setAuthState: (session, loginResponse) => {
|
|
39
62
|
set({
|
|
40
63
|
session,
|
|
41
64
|
isAuthenticated: !!session,
|
|
42
|
-
|
|
65
|
+
isOnboarded: loginResponse?.onboarded || false,
|
|
66
|
+
user: loginResponse?.profile || null,
|
|
67
|
+
loading: false,
|
|
68
|
+
error: null
|
|
43
69
|
});
|
|
44
70
|
},
|
|
45
71
|
/**
|
package/package.json
CHANGED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { MessageActionType } from './MessageActionType';
|
|
2
|
-
export type ActionContent = {
|
|
3
|
-
/**
|
|
4
|
-
* Type of the action
|
|
5
|
-
*/
|
|
6
|
-
action_type: MessageActionType;
|
|
7
|
-
/**
|
|
8
|
-
* ID of the listing associated with the action
|
|
9
|
-
*/
|
|
10
|
-
listing_id: string;
|
|
11
|
-
};
|
|
12
|
-
//# sourceMappingURL=ActionContent.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ActionContent.d.ts","sourceRoot":"","sources":["../../../src/api/models/ActionContent.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC7D,MAAM,MAAM,aAAa,GAAG;IACxB;;OAEG;IACH,WAAW,EAAE,iBAAiB,CAAC;IAC/B;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;CACtB,CAAC"}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Model for the response returned after a boost request
|
|
3
|
-
*/
|
|
4
|
-
export type BoostResponse = {
|
|
5
|
-
/**
|
|
6
|
-
* The client secret for the payment intent.
|
|
7
|
-
*/
|
|
8
|
-
client_secret: string;
|
|
9
|
-
/**
|
|
10
|
-
* The amount to be charged.
|
|
11
|
-
*/
|
|
12
|
-
amount: number;
|
|
13
|
-
/**
|
|
14
|
-
* The currency of the payment.
|
|
15
|
-
*/
|
|
16
|
-
currency: string;
|
|
17
|
-
/**
|
|
18
|
-
* The boost credits available for the user.
|
|
19
|
-
*/
|
|
20
|
-
boost_credits: Record<string, number>;
|
|
21
|
-
};
|
|
22
|
-
//# sourceMappingURL=BoostResponse.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"BoostResponse.d.ts","sourceRoot":"","sources":["../../../src/api/models/BoostResponse.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG;IACxB;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC;IACtB;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACzC,CAAC"}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import type { FileContent } from './FileContent';
|
|
2
|
-
import type { MessageType } from './MessageType';
|
|
3
|
-
import type { RichActionContent } from './RichActionContent';
|
|
4
|
-
import type { RichTextContent } from './RichTextContent';
|
|
5
|
-
import type { UserPreview } from './UserPreview';
|
|
6
|
-
export type Message = {
|
|
7
|
-
/**
|
|
8
|
-
* Unique identifier for the message
|
|
9
|
-
*/
|
|
10
|
-
id: string;
|
|
11
|
-
/**
|
|
12
|
-
* Information about the user who sent the message
|
|
13
|
-
*/
|
|
14
|
-
sender?: (UserPreview | null);
|
|
15
|
-
/**
|
|
16
|
-
* Type of the message
|
|
17
|
-
*/
|
|
18
|
-
type: MessageType;
|
|
19
|
-
/**
|
|
20
|
-
* Content of the message
|
|
21
|
-
*/
|
|
22
|
-
content: (RichTextContent | FileContent | RichActionContent);
|
|
23
|
-
/**
|
|
24
|
-
* Timestamp when the message was created, in ISO 8601 format
|
|
25
|
-
*/
|
|
26
|
-
created_at: string;
|
|
27
|
-
};
|
|
28
|
-
//# sourceMappingURL=Message.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Message.d.ts","sourceRoot":"","sources":["../../../src/api/models/Message.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC7D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AACjD,MAAM,MAAM,OAAO,GAAG;IAClB;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IACX;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,WAAW,GAAG,IAAI,CAAC,CAAC;IAC9B;;OAEG;IACH,IAAI,EAAE,WAAW,CAAC;IAClB;;OAEG;IACH,OAAO,EAAE,CAAC,eAAe,GAAG,WAAW,GAAG,iBAAiB,CAAC,CAAC;IAC7D;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;CACtB,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { ListingPreview } from './ListingPreview';
|
|
2
|
-
import type { MessageActionType } from './MessageActionType';
|
|
3
|
-
export type RichActionContent = {
|
|
4
|
-
/**
|
|
5
|
-
* Type of the action
|
|
6
|
-
*/
|
|
7
|
-
action_type: MessageActionType;
|
|
8
|
-
/**
|
|
9
|
-
* Listing associated with the action
|
|
10
|
-
*/
|
|
11
|
-
listing?: (ListingPreview | null);
|
|
12
|
-
};
|
|
13
|
-
//# sourceMappingURL=RichActionContent.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"RichActionContent.d.ts","sourceRoot":"","sources":["../../../src/api/models/RichActionContent.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC7D,MAAM,MAAM,iBAAiB,GAAG;IAC5B;;OAEG;IACH,WAAW,EAAE,iBAAiB,CAAC;IAC/B;;OAEG;IACH,OAAO,CAAC,EAAE,CAAC,cAAc,GAAG,IAAI,CAAC,CAAC;CACrC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
File without changes
|
|
File without changes
|
|
File without changes
|