ebay-api 9.3.1 → 9.4.0

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/README.md CHANGED
@@ -75,26 +75,25 @@ For more examples, check out the [examples directory](./examples).
75
75
 
76
76
  ## Changelog
77
77
 
78
- * `v9.3.1` is the latest release.
78
+ * `v9.4.0` is the latest release.
79
79
  * See [here](https://github.com/hendt/ebay-api/blob/master/CHANGELOG.md) for the full changelog.
80
80
 
81
81
  ## Implementation status
82
82
 
83
83
  ### RESTful API
84
84
 
85
- | API | Implemented |
86
- |:-------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
87
- | **Buy API** | ✔ Browse API `v1.10.0`<br>✔ Deal API `v1.3.0`<br>✔ Feed API `v1.3.1`<br>✔ Marketing API `v1_beta.1.0`<br>✔ Offer API `v1_beta.0.0`<br>✔ Order API `v1_beta.20.0`<br>✔ Marketplace Insights API `v1_beta.2.2` |
88
- | **Commerce API** | ✔ Catalog API `v1_beta.3.1`<br>✔ Charity API `v1.2.0`<br>✔ Identity API `v1.0.0`<br>✔ Notification API `v1.2.0`<br>✔ Taxonomy API `v1.0.0`<br>✔ Translation API `v1_beta.1.4`<br>✔ Media API `v1_beta.1.0` |
89
- | **Developer API** | ✔ Analytics API |
90
- | **Post Order API** | ✔ Cancellation API<br>✔ Case Management API<br>✔ Inquiry API<br>✔ Return API |
85
+ | API | Implemented |
86
+ |:-------------------|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
87
+ | **Buy API** | ✔ Browse API `v1.10.0`<br>✔ Deal API `v1.3.0`<br>✔ Feed API `v1.3.1`<br>✔ Marketing API `v1_beta.1.0`<br>✔ Offer API `v1_beta.0.0`<br>✔ Order API `v1_beta.20.0`<br>✔ Marketplace Insights API `v1_beta.2.2` |
88
+ | **Commerce API** | ✔ Catalog API `v1_beta.3.1`<br>✔ Charity API `v1.2.0`<br>✔ Identity API `v1.0.0`<br>✔ Notification API `v1.2.0`<br>✔ Taxonomy API `v1.0.0`<br>✔ Translation API `v1_beta.1.4`<br>✔ Media API `v1_beta.1.0`<br>✔ Message API `v1.0.0` |
89
+ | **Developer API** | ✔ Analytics API |
90
+ | **Post Order API** | ✔ Cancellation API<br>✔ Case Management API<br>✔ Inquiry API<br>✔ Return API |
91
91
  | **Sell API** | ✔ Account API `v1.9.0`<br>✔ Analytics API `v1.3.0`<br>✔ Compliance API `v1.4.1`<br>✔ Feed API `v1.3.1`<br>✔ Finance API `v1.9.0`<br>✔ Fulfillment API `v1.19.10`<br>✔ Inventory API `v1.18.0`<br>✔ Listing API `v1_beta.2.1`<br>✔ Logistics API `v1_beta.0.0`<br>✔ Marketing API `v1.17.0`<br>✔ Metadata API `v1.7.1`<br>✔ Negotiation API `v1.1.0`<br>✔ Recommendation API `v1.1.0` |
92
92
 
93
93
  ### Traditional API
94
94
 
95
95
  | API | Implemented |
96
96
  |:----------------------|:------------|
97
- | **Finding API** | ✔ |
98
97
  | **Shopping API** | ✔ |
99
98
  | **Merchandising API** | ✔ |
100
99
  | **Trading API** | ✔ |
@@ -742,6 +741,7 @@ Check [here](https://github.com/hendt/ebay-api/blob/master/CONTRIBUTING.md)
742
741
  ## Supported By
743
742
 
744
743
  [leaderboarded.com](https://leaderboarded.com/)
744
+
745
745
  [rootle.de](https://rootle.de)
746
746
 
747
747
  ## 📝 License
@@ -1,6 +1,6 @@
1
1
  import Api from './index.js';
2
2
  import { Browse, Deal, Feed, Marketing as BuyMarketing, MarketplaceInsights, Offer, Order } from './restful/buy/index.js';
3
- import { Catalog, Charity, Identity, Media, Notification, Taxonomy, Translation } from './restful/commerce/index.js';
3
+ import { Catalog, Charity, Identity, Media, Message, Notification, Taxonomy, Translation } from './restful/commerce/index.js';
4
4
  import { Analytics as DeveloperAnalytics, KeyManagement } from './restful/developer/index.js';
5
5
  import { Cancellation, Case, Inquiry, Return, } from './restful/postOrder/index.js';
6
6
  import { AccountV1, AccountV2, Analytics as SellAnalytics, Compliance, Feed as SellFeed, Finances, Fulfillment, Inventory, Listing, Logistics, Marketing as SellMarketing, Metadata, Negotiation, Recommendation } from './restful/sell/index.js';
@@ -30,6 +30,7 @@ export default class ApiFactory extends Api {
30
30
  media: this.createRestfulApi(Media),
31
31
  translation: this.createRestfulApi(Translation),
32
32
  taxonomy: this.createRestfulApi(Taxonomy),
33
+ message: this.createRestfulApi(Message)
33
34
  };
34
35
  }
35
36
  createDeveloperApi() {
@@ -5,6 +5,7 @@ import Media from './media/index.js';
5
5
  import Notification from './notification/index.js';
6
6
  import Taxonomy from './taxonomy/index.js';
7
7
  import Translation from './translation/index.js';
8
+ import Message from './message/index.js';
8
9
  export type Commerce = {
9
10
  catalog: Catalog;
10
11
  charity: Charity;
@@ -13,5 +14,6 @@ export type Commerce = {
13
14
  taxonomy: Taxonomy;
14
15
  translation: Translation;
15
16
  media: Media;
17
+ message: Message;
16
18
  };
17
- export { Catalog, Charity, Identity, Notification, Taxonomy, Translation, Media };
19
+ export { Catalog, Charity, Identity, Notification, Taxonomy, Translation, Media, Message };
@@ -5,4 +5,5 @@ import Media from './media/index.js';
5
5
  import Notification from './notification/index.js';
6
6
  import Taxonomy from './taxonomy/index.js';
7
7
  import Translation from './translation/index.js';
8
- export { Catalog, Charity, Identity, Notification, Taxonomy, Translation, Media };
8
+ import Message from './message/index.js';
9
+ export { Catalog, Charity, Identity, Notification, Taxonomy, Translation, Media, Message };
@@ -0,0 +1,26 @@
1
+ import { operations } from '../../../../types/restful/specs/commerce_message_v1_oas3.js';
2
+ import { BulkUpdateConversationRequest, CommerceMessageSendMessageRequest, UpdateConversationRequest } from '../../../../types/restfulTypes.js';
3
+ import Restful, { OpenApi } from '../../index.js';
4
+ export default class Message extends Restful implements OpenApi<operations> {
5
+ static id: string;
6
+ get basePath(): string;
7
+ getConversations({ limit, offset, conversationStatus, conversationType, referenceId, referenceType, startTime, endTime, otherPartyUsername }?: {
8
+ limit?: number;
9
+ offset?: number;
10
+ conversationStatus?: string;
11
+ conversationType?: string;
12
+ referenceId?: string;
13
+ referenceType?: string;
14
+ startTime?: string;
15
+ endTime?: string;
16
+ otherPartyUsername?: string;
17
+ }): Promise<any>;
18
+ getConversation(conversationId: string, { conversationType, limit, offset }: {
19
+ conversationType: string;
20
+ limit?: number;
21
+ offset?: number;
22
+ }): Promise<any>;
23
+ updateConversation(body: UpdateConversationRequest): Promise<any>;
24
+ bulkUpdateConversation(body: BulkUpdateConversationRequest): Promise<any>;
25
+ sendMessage(body: CommerceMessageSendMessageRequest): Promise<any>;
26
+ }
@@ -0,0 +1,42 @@
1
+ import Restful from '../../index.js';
2
+ class Message extends Restful {
3
+ get basePath() {
4
+ return '/commerce/message/v1';
5
+ }
6
+ getConversations({ limit, offset, conversationStatus, conversationType, referenceId, referenceType, startTime, endTime, otherPartyUsername } = {}) {
7
+ return this.get(`/conversation`, {
8
+ params: {
9
+ limit,
10
+ offset,
11
+ conversation_status: conversationStatus,
12
+ conversation_type: conversationType,
13
+ reference_id: referenceId,
14
+ reference_type: referenceType,
15
+ start_time: startTime,
16
+ end_time: endTime,
17
+ other_party_username: otherPartyUsername,
18
+ }
19
+ });
20
+ }
21
+ getConversation(conversationId, { conversationType, limit, offset }) {
22
+ return this.get(`/conversation/${conversationId}`, {
23
+ params: {
24
+ conversation_type: conversationType,
25
+ limit,
26
+ offset,
27
+ }
28
+ });
29
+ }
30
+ updateConversation(body) {
31
+ return this.post(`/update_conversation`, body);
32
+ }
33
+ bulkUpdateConversation(body) {
34
+ return this.post(`/bulk_update_conversation`, body);
35
+ }
36
+ sendMessage(body) {
37
+ return this.post(`/send_message`, body);
38
+ }
39
+ ;
40
+ }
41
+ Message.id = 'Message';
42
+ export default Message;