@daocloud-proto/leopard 0.10.0-dev1 → 0.10.0-rc1
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/package.json +1 -1
- package/v1alpha1/accounts.pb.ts +13 -0
- package/v1alpha1/product.pb.ts +11 -0
package/package.json
CHANGED
package/v1alpha1/accounts.pb.ts
CHANGED
|
@@ -21,6 +21,16 @@ export enum RequestMethod {
|
|
|
21
21
|
PATCH = "PATCH",
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
+
export type ListSubAccountsRequest = {
|
|
25
|
+
page?: number
|
|
26
|
+
pageSize?: number
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export type ListSubAccountsResponse = {
|
|
30
|
+
items?: AccountInfo[]
|
|
31
|
+
pagination?: Pagination
|
|
32
|
+
}
|
|
33
|
+
|
|
24
34
|
export type ListCurrentMembersRequest = {
|
|
25
35
|
page?: number
|
|
26
36
|
pageSize?: number
|
|
@@ -55,6 +65,9 @@ export class Accounts {
|
|
|
55
65
|
static ListCurrentMembers(req: ListCurrentMembersRequest, initReq?: fm.InitReq): Promise<ListCurrentMembersResponse> {
|
|
56
66
|
return fm.fetchReq<ListCurrentMembersRequest, ListCurrentMembersResponse>(`/apis/leopard.io/v1alpha1/accounts/current/members?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
57
67
|
}
|
|
68
|
+
static ListSubAccounts(req: ListSubAccountsRequest, initReq?: fm.InitReq): Promise<ListSubAccountsResponse> {
|
|
69
|
+
return fm.fetchReq<ListSubAccountsRequest, ListSubAccountsResponse>(`/apis/leopard.io/v1alpha1/accounts?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
70
|
+
}
|
|
58
71
|
static GetExportURL(req: GetExportURLRequest, initReq?: fm.InitReq): Promise<GetExportURLResponse> {
|
|
59
72
|
return fm.fetchReq<GetExportURLRequest, GetExportURLResponse>(`/apis/leopard.io/v1alpha1/export/url?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
60
73
|
}
|
package/v1alpha1/product.pb.ts
CHANGED
|
@@ -352,6 +352,14 @@ export type DeleteSKUInfoRequest = {
|
|
|
352
352
|
export type DeleteSKUInfoResponse = {
|
|
353
353
|
}
|
|
354
354
|
|
|
355
|
+
export type CreateRegionDomainRequest = {
|
|
356
|
+
region?: string
|
|
357
|
+
domain?: string
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
export type CreateRegionDomainResponse = {
|
|
361
|
+
}
|
|
362
|
+
|
|
355
363
|
export class Product {
|
|
356
364
|
static ListProductSKUs(req: ListProductSKUsRequest, initReq?: fm.InitReq): Promise<ListProductSKUsResponse> {
|
|
357
365
|
return fm.fetchReq<ListProductSKUsRequest, ListProductSKUsResponse>(`/apis/leopard.io/v1alpha1/products/skus`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
|
|
@@ -416,4 +424,7 @@ export class Product {
|
|
|
416
424
|
static UpdateSKUDiscountRule(req: UpdateSKUDiscountRuleRequest, initReq?: fm.InitReq): Promise<UpdateSKUDiscountRuleResponse> {
|
|
417
425
|
return fm.fetchReq<UpdateSKUDiscountRuleRequest, UpdateSKUDiscountRuleResponse>(`/apis/leopard.io/v1alpha1/products/sku-infos/${req["skuId"]}/discount`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
|
|
418
426
|
}
|
|
427
|
+
static CreateRegionDomain(req: CreateRegionDomainRequest, initReq?: fm.InitReq): Promise<CreateRegionDomainResponse> {
|
|
428
|
+
return fm.fetchReq<CreateRegionDomainRequest, CreateRegionDomainResponse>(`/apis/leopard.io/v1alpha1/products/region-domain`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
|
|
429
|
+
}
|
|
419
430
|
}
|