@pushwoosh/rpc-v2-http-api-data 0.2.249 → 0.2.250
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/approvals.d.ts +37 -0
- package/data.js +92 -0
- package/package.json +1 -1
package/approvals.d.ts
CHANGED
|
@@ -4,6 +4,8 @@ export type ApprovalsService_Approve = RpcMethod<ApproveRequest, ApproveResponse
|
|
|
4
4
|
export type ApprovalsService_Reject = RpcMethod<RejectRequest, RejectResponse>;
|
|
5
5
|
export type ApprovalsService_Cancel = RpcMethod<CancelApprovalRequest, CancelApprovalResponse>;
|
|
6
6
|
export type ApprovalsService_List = RpcMethod<ListApprovalsRequest, ListApprovalsResponse>;
|
|
7
|
+
export type ApprovalsService_ListVersions = RpcMethod<ListContentVersionsRequest, ListContentVersionsResponse>;
|
|
8
|
+
export type ApprovalsService_GetVersion = RpcMethod<GetContentVersionRequest, GetContentVersionResponse>;
|
|
7
9
|
export interface ApprovalsService {
|
|
8
10
|
/** Sends one content version of a push preset or email template for approval. The author submits, someone holding the ApproveMessages right decides; while the request is pending the version cannot be sent. */
|
|
9
11
|
Submit: ApprovalsService_Submit;
|
|
@@ -15,6 +17,10 @@ export interface ApprovalsService {
|
|
|
15
17
|
Cancel: ApprovalsService_Cancel;
|
|
16
18
|
/** Lists approval requests of the account, newest first, optionally narrowed to one state or one content item. This is the approver inbox. */
|
|
17
19
|
List: ApprovalsService_List;
|
|
20
|
+
/** Lists the stored versions of one content item, newest first, without their snapshots. Use to show the history of a push preset or email template. */
|
|
21
|
+
ListVersions: ApprovalsService_ListVersions;
|
|
22
|
+
/** Returns one content version together with its snapshot — the content exactly as it would be sent. Use to show what a version holds, or to compare two of them. */
|
|
23
|
+
GetVersion: ApprovalsService_GetVersion;
|
|
18
24
|
}
|
|
19
25
|
export type ApprovalState = 'APPROVAL_STATE_UNSPECIFIED' | 'APPROVAL_STATE_PENDING' | 'APPROVAL_STATE_APPROVED' | 'APPROVAL_STATE_REJECTED' | 'APPROVAL_STATE_CANCELLED';
|
|
20
26
|
export type ContentOwnerType = 'CONTENT_OWNER_TYPE_UNSPECIFIED' | 'CONTENT_OWNER_TYPE_PUSH_PRESET' | 'CONTENT_OWNER_TYPE_EMAIL_TEMPLATE';
|
|
@@ -78,3 +84,34 @@ export type ListApprovalsResponse = {
|
|
|
78
84
|
perPage: number;
|
|
79
85
|
total: number;
|
|
80
86
|
};
|
|
87
|
+
export type ContentVersion = {
|
|
88
|
+
id: number;
|
|
89
|
+
application: string;
|
|
90
|
+
ownerType: ContentOwnerType;
|
|
91
|
+
ownerCode: string;
|
|
92
|
+
/** Sequential number within one content item, starts at 1. */
|
|
93
|
+
versionNo: number;
|
|
94
|
+
authorId: number;
|
|
95
|
+
created: Date;
|
|
96
|
+
/** The content as it would be sent, serialised as JSON; empty in list responses. */
|
|
97
|
+
snapshot: string;
|
|
98
|
+
};
|
|
99
|
+
export type ListContentVersionsRequest = {
|
|
100
|
+
ownerType?: ContentOwnerType;
|
|
101
|
+
/** Code of the push preset or email template. */
|
|
102
|
+
ownerCode?: string;
|
|
103
|
+
page?: number;
|
|
104
|
+
perPage?: number;
|
|
105
|
+
};
|
|
106
|
+
export type ListContentVersionsResponse = {
|
|
107
|
+
versions: ContentVersion[];
|
|
108
|
+
page: number;
|
|
109
|
+
perPage: number;
|
|
110
|
+
total: number;
|
|
111
|
+
};
|
|
112
|
+
export type GetContentVersionRequest = {
|
|
113
|
+
id?: number;
|
|
114
|
+
};
|
|
115
|
+
export type GetContentVersionResponse = {
|
|
116
|
+
version: ContentVersion;
|
|
117
|
+
};
|
package/data.js
CHANGED
|
@@ -7541,6 +7541,18 @@ export const data = {
|
|
|
7541
7541
|
"response": "pushwoosh.rpc_v2.approvals.ListApprovalsResponse",
|
|
7542
7542
|
"method": "get",
|
|
7543
7543
|
"path": "/api/approvals"
|
|
7544
|
+
},
|
|
7545
|
+
"ListVersions": {
|
|
7546
|
+
"request": "pushwoosh.rpc_v2.approvals.ListContentVersionsRequest",
|
|
7547
|
+
"response": "pushwoosh.rpc_v2.approvals.ListContentVersionsResponse",
|
|
7548
|
+
"method": "get",
|
|
7549
|
+
"path": "/api/approvals/versions"
|
|
7550
|
+
},
|
|
7551
|
+
"GetVersion": {
|
|
7552
|
+
"request": "pushwoosh.rpc_v2.approvals.GetContentVersionRequest",
|
|
7553
|
+
"response": "pushwoosh.rpc_v2.approvals.GetContentVersionResponse",
|
|
7554
|
+
"method": "get",
|
|
7555
|
+
"path": "/api/approvals/versions/{id}"
|
|
7544
7556
|
}
|
|
7545
7557
|
}
|
|
7546
7558
|
},
|
|
@@ -7710,6 +7722,86 @@ export const data = {
|
|
|
7710
7722
|
}
|
|
7711
7723
|
}
|
|
7712
7724
|
},
|
|
7725
|
+
"pushwoosh.rpc_v2.approvals.ContentVersion": {
|
|
7726
|
+
"type": "I",
|
|
7727
|
+
"fields": {
|
|
7728
|
+
"id": {
|
|
7729
|
+
"type": "number"
|
|
7730
|
+
},
|
|
7731
|
+
"application": {
|
|
7732
|
+
"type": "string"
|
|
7733
|
+
},
|
|
7734
|
+
"ownerType": {
|
|
7735
|
+
"type": "pushwoosh.rpc_v2.approvals.ContentOwnerType"
|
|
7736
|
+
},
|
|
7737
|
+
"ownerCode": {
|
|
7738
|
+
"type": "string"
|
|
7739
|
+
},
|
|
7740
|
+
"versionNo": {
|
|
7741
|
+
"type": "number"
|
|
7742
|
+
},
|
|
7743
|
+
"authorId": {
|
|
7744
|
+
"type": "number"
|
|
7745
|
+
},
|
|
7746
|
+
"created": {
|
|
7747
|
+
"type": "Date"
|
|
7748
|
+
},
|
|
7749
|
+
"snapshot": {
|
|
7750
|
+
"type": "string"
|
|
7751
|
+
}
|
|
7752
|
+
}
|
|
7753
|
+
},
|
|
7754
|
+
"pushwoosh.rpc_v2.approvals.ListContentVersionsRequest": {
|
|
7755
|
+
"type": "I",
|
|
7756
|
+
"fields": {
|
|
7757
|
+
"ownerType": {
|
|
7758
|
+
"type": "pushwoosh.rpc_v2.approvals.ContentOwnerType"
|
|
7759
|
+
},
|
|
7760
|
+
"ownerCode": {
|
|
7761
|
+
"type": "string"
|
|
7762
|
+
},
|
|
7763
|
+
"page": {
|
|
7764
|
+
"type": "number"
|
|
7765
|
+
},
|
|
7766
|
+
"perPage": {
|
|
7767
|
+
"type": "number"
|
|
7768
|
+
}
|
|
7769
|
+
}
|
|
7770
|
+
},
|
|
7771
|
+
"pushwoosh.rpc_v2.approvals.ListContentVersionsResponse": {
|
|
7772
|
+
"type": "I",
|
|
7773
|
+
"fields": {
|
|
7774
|
+
"versions": {
|
|
7775
|
+
"type": "pushwoosh.rpc_v2.approvals.ContentVersion",
|
|
7776
|
+
"array": true
|
|
7777
|
+
},
|
|
7778
|
+
"page": {
|
|
7779
|
+
"type": "number"
|
|
7780
|
+
},
|
|
7781
|
+
"perPage": {
|
|
7782
|
+
"type": "number"
|
|
7783
|
+
},
|
|
7784
|
+
"total": {
|
|
7785
|
+
"type": "number"
|
|
7786
|
+
}
|
|
7787
|
+
}
|
|
7788
|
+
},
|
|
7789
|
+
"pushwoosh.rpc_v2.approvals.GetContentVersionRequest": {
|
|
7790
|
+
"type": "I",
|
|
7791
|
+
"fields": {
|
|
7792
|
+
"id": {
|
|
7793
|
+
"type": "number"
|
|
7794
|
+
}
|
|
7795
|
+
}
|
|
7796
|
+
},
|
|
7797
|
+
"pushwoosh.rpc_v2.approvals.GetContentVersionResponse": {
|
|
7798
|
+
"type": "I",
|
|
7799
|
+
"fields": {
|
|
7800
|
+
"version": {
|
|
7801
|
+
"type": "pushwoosh.rpc_v2.approvals.ContentVersion"
|
|
7802
|
+
}
|
|
7803
|
+
}
|
|
7804
|
+
},
|
|
7713
7805
|
"pushwoosh.rpc_v2.campaigns.CampaignsService": {
|
|
7714
7806
|
"type": "S",
|
|
7715
7807
|
"key": "campaigns",
|