Skip to content

Commit 0f78686

Browse files
feat: publish sdk 0.1.5 with below changes (#4)
- Pages API - Issue Relation API - ModuleIssue API - CycleIssue API
1 parent 03cc30b commit 0f78686

File tree

135 files changed

+2873
-292
lines changed

Some content is hidden

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

135 files changed

+2873
-292
lines changed

.openapi-generator/FILES

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,12 @@ eslint.config.mjs
55
package.json
66
src/apis/AssetsApi.ts
77
src/apis/CyclesApi.ts
8+
src/apis/EpicsApi.ts
89
src/apis/IntakeApi.ts
910
src/apis/LabelsApi.ts
1011
src/apis/MembersApi.ts
1112
src/apis/ModulesApi.ts
13+
src/apis/PagesApi.ts
1214
src/apis/ProjectsApi.ts
1315
src/apis/StatesApi.ts
1416
src/apis/UsersApi.ts
@@ -20,15 +22,17 @@ src/apis/WorkItemPropertiesApi.ts
2022
src/apis/WorkItemTypesApi.ts
2123
src/apis/WorkItemWorklogsApi.ts
2224
src/apis/WorkItemsApi.ts
25+
src/apis/WorkspacesApi.ts
2326
src/apis/index.ts
2427
src/index.ts
25-
src/models/AccessEnum.ts
28+
src/models/AccessBd4Enum.ts
2629
src/models/Cycle.ts
2730
src/models/CycleCreateRequest.ts
2831
src/models/CycleIssue.ts
2932
src/models/CycleIssueRequestRequest.ts
3033
src/models/CycleLite.ts
3134
src/models/EntityTypeEnum.ts
35+
src/models/Epic.ts
3236
src/models/GenericAssetUploadRequest.ts
3337
src/models/GetWorkspaceMembers200ResponseInner.ts
3438
src/models/GroupEnum.ts
@@ -47,12 +51,18 @@ src/models/IssueForIntakeRequest.ts
4751
src/models/IssueLink.ts
4852
src/models/IssueLinkCreateRequest.ts
4953
src/models/IssuePropertyAPI.ts
54+
src/models/IssuePropertyAPIRelationTypeEnum.ts
5055
src/models/IssuePropertyAPIRequest.ts
5156
src/models/IssuePropertyOptionAPI.ts
5257
src/models/IssuePropertyOptionAPIRequest.ts
5358
src/models/IssuePropertyValueAPI.ts
5459
src/models/IssuePropertyValueAPIDetail.ts
5560
src/models/IssuePropertyValueAPIRequest.ts
61+
src/models/IssueRelation.ts
62+
src/models/IssueRelationCreateRelationTypeEnum.ts
63+
src/models/IssueRelationCreateRequest.ts
64+
src/models/IssueRelationRemoveRequest.ts
65+
src/models/IssueRelationResponse.ts
5666
src/models/IssueRequest.ts
5767
src/models/IssueSearch.ts
5868
src/models/IssueSearchItem.ts
@@ -69,10 +79,15 @@ src/models/ModuleIssueRequestRequest.ts
6979
src/models/ModuleLite.ts
7080
src/models/ModuleStatusEnum.ts
7181
src/models/NetworkEnum.ts
82+
src/models/PageCreateAPI.ts
83+
src/models/PageCreateAPIAccessEnum.ts
84+
src/models/PageCreateAPIRequest.ts
85+
src/models/PageDetailAPI.ts
7286
src/models/PaginatedArchivedCycleResponse.ts
7387
src/models/PaginatedArchivedModuleResponse.ts
7488
src/models/PaginatedCycleIssueResponse.ts
7589
src/models/PaginatedCycleResponse.ts
90+
src/models/PaginatedEpicResponse.ts
7691
src/models/PaginatedIntakeIssueResponse.ts
7792
src/models/PaginatedIssueActivityDetailResponse.ts
7893
src/models/PaginatedIssueActivityResponse.ts
@@ -105,7 +120,6 @@ src/models/Project.ts
105120
src/models/ProjectCreateRequest.ts
106121
src/models/ProjectWorklogSummary.ts
107122
src/models/PropertyTypeEnum.ts
108-
src/models/RelationTypeEnum.ts
109123
src/models/RetrieveWorkItemAttachment400Response.ts
110124
src/models/State.ts
111125
src/models/StateLite.ts

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## @makeplane/plane-node-sdk@0.1.4
1+
## @makeplane/plane-node-sdk@0.1.5
22

33
This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
44

@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
3636
_published:_
3737

3838
```
39-
npm install @makeplane/[email protected].4 --save
39+
npm install @makeplane/[email protected].5 --save
4040
```
4141

4242
_unPublished (not recommended):_

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@makeplane/plane-node-sdk",
3-
"version": "0.1.4",
3+
"version": "0.1.5",
44
"description": "Node SDK for Plane",
55
"author": "Plane <[email protected]>",
66
"repository": {

src/apis/AssetsApi.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* The Plane REST API
55
* The Plane REST API Visit our quick start guide and full API documentation at [developers.plane.so](https://developers.plane.so/api-reference/introduction).
66
*
7-
* The version of the API Spec: 0.0.1
7+
* The version of the API Spec: 0.0.2
88
* Contact: [email protected]
99
*
1010
* NOTE: This class is auto generated.

src/apis/CyclesApi.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* The Plane REST API
55
* The Plane REST API Visit our quick start guide and full API documentation at [developers.plane.so](https://developers.plane.so/api-reference/introduction).
66
*
7-
* The version of the API Spec: 0.0.1
7+
* The version of the API Spec: 0.0.2
88
* Contact: [email protected]
99
*
1010
* NOTE: This class is auto generated.
@@ -151,7 +151,7 @@ export class CyclesApi extends runtime.BaseAPI {
151151
* Assign multiple work items to a cycle. Automatically handles bulk creation and updates with activity tracking.
152152
* Add Work Items to Cycle
153153
*/
154-
async addCycleWorkItemsRaw(requestParameters: AddCycleWorkItemsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CycleIssue>> {
154+
async addCycleWorkItemsRaw(requestParameters: AddCycleWorkItemsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<CycleIssue>>> {
155155
if (requestParameters['cycleId'] == null) {
156156
throw new runtime.RequiredError(
157157
'cycleId',
@@ -208,14 +208,14 @@ export class CyclesApi extends runtime.BaseAPI {
208208
body: CycleIssueRequestRequestToJSON(requestParameters['cycleIssueRequestRequest']),
209209
}, initOverrides);
210210

211-
return new runtime.JSONApiResponse(response, (jsonValue) => CycleIssueFromJSON(jsonValue));
211+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(CycleIssueFromJSON));
212212
}
213213

214214
/**
215215
* Assign multiple work items to a cycle. Automatically handles bulk creation and updates with activity tracking.
216216
* Add Work Items to Cycle
217217
*/
218-
async addCycleWorkItems(requestParameters: AddCycleWorkItemsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CycleIssue> {
218+
async addCycleWorkItems(requestParameters: AddCycleWorkItemsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<CycleIssue>> {
219219
const response = await this.addCycleWorkItemsRaw(requestParameters, initOverrides);
220220
return await response.value();
221221
}

src/apis/EpicsApi.ts

Lines changed: 177 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,177 @@
1+
/* tslint:disable */
2+
/* eslint-disable */
3+
/**
4+
* The Plane REST API
5+
* The Plane REST API Visit our quick start guide and full API documentation at [developers.plane.so](https://developers.plane.so/api-reference/introduction).
6+
*
7+
* The version of the API Spec: 0.0.2
8+
* Contact: [email protected]
9+
*
10+
* NOTE: This class is auto generated.
11+
* Do not edit the class manually.
12+
*/
13+
14+
15+
import * as runtime from '../runtime';
16+
import type {
17+
Epic,
18+
PaginatedEpicResponse,
19+
} from '../models/index';
20+
import {
21+
EpicFromJSON,
22+
EpicToJSON,
23+
PaginatedEpicResponseFromJSON,
24+
PaginatedEpicResponseToJSON,
25+
} from '../models/index';
26+
27+
export interface ListEpicsRequest {
28+
projectId: string;
29+
slug: string;
30+
cursor?: string;
31+
perPage?: number;
32+
}
33+
34+
export interface RetrieveEpicRequest {
35+
pk: string;
36+
projectId: string;
37+
slug: string;
38+
fields?: string;
39+
}
40+
41+
/**
42+
*
43+
*/
44+
export class EpicsApi extends runtime.BaseAPI {
45+
46+
/**
47+
* List epics
48+
* List epics
49+
*/
50+
async listEpicsRaw(requestParameters: ListEpicsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedEpicResponse>> {
51+
if (requestParameters['projectId'] == null) {
52+
throw new runtime.RequiredError(
53+
'projectId',
54+
'Required parameter "projectId" was null or undefined when calling listEpics().'
55+
);
56+
}
57+
58+
if (requestParameters['slug'] == null) {
59+
throw new runtime.RequiredError(
60+
'slug',
61+
'Required parameter "slug" was null or undefined when calling listEpics().'
62+
);
63+
}
64+
65+
const queryParameters: any = {};
66+
67+
if (requestParameters['cursor'] != null) {
68+
queryParameters['cursor'] = requestParameters['cursor'];
69+
}
70+
71+
if (requestParameters['perPage'] != null) {
72+
queryParameters['per_page'] = requestParameters['perPage'];
73+
}
74+
75+
const headerParameters: runtime.HTTPHeaders = {};
76+
77+
if (this.configuration && this.configuration.apiKey) {
78+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuthentication authentication
79+
}
80+
81+
if (this.configuration && this.configuration.accessToken) {
82+
// oauth required
83+
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2Authentication", []);
84+
}
85+
86+
if (this.configuration && this.configuration.accessToken) {
87+
// oauth required
88+
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2Authentication", []);
89+
}
90+
91+
const response = await this.request({
92+
path: `/api/v1/workspaces/{slug}/projects/{project_id}/epics/`.replace(`{${"project_id"}}`, encodeURIComponent(String(requestParameters['projectId']))).replace(`{${"slug"}}`, encodeURIComponent(String(requestParameters['slug']))),
93+
method: 'GET',
94+
headers: headerParameters,
95+
query: queryParameters,
96+
}, initOverrides);
97+
98+
return new runtime.JSONApiResponse(response, (jsonValue) => PaginatedEpicResponseFromJSON(jsonValue));
99+
}
100+
101+
/**
102+
* List epics
103+
* List epics
104+
*/
105+
async listEpics(requestParameters: ListEpicsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedEpicResponse> {
106+
const response = await this.listEpicsRaw(requestParameters, initOverrides);
107+
return await response.value();
108+
}
109+
110+
/**
111+
* Retrieve an epic by id
112+
* Retrieve an epic
113+
*/
114+
async retrieveEpicRaw(requestParameters: RetrieveEpicRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Epic>> {
115+
if (requestParameters['pk'] == null) {
116+
throw new runtime.RequiredError(
117+
'pk',
118+
'Required parameter "pk" was null or undefined when calling retrieveEpic().'
119+
);
120+
}
121+
122+
if (requestParameters['projectId'] == null) {
123+
throw new runtime.RequiredError(
124+
'projectId',
125+
'Required parameter "projectId" was null or undefined when calling retrieveEpic().'
126+
);
127+
}
128+
129+
if (requestParameters['slug'] == null) {
130+
throw new runtime.RequiredError(
131+
'slug',
132+
'Required parameter "slug" was null or undefined when calling retrieveEpic().'
133+
);
134+
}
135+
136+
const queryParameters: any = {};
137+
138+
if (requestParameters['fields'] != null) {
139+
queryParameters['fields'] = requestParameters['fields'];
140+
}
141+
142+
const headerParameters: runtime.HTTPHeaders = {};
143+
144+
if (this.configuration && this.configuration.apiKey) {
145+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuthentication authentication
146+
}
147+
148+
if (this.configuration && this.configuration.accessToken) {
149+
// oauth required
150+
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2Authentication", []);
151+
}
152+
153+
if (this.configuration && this.configuration.accessToken) {
154+
// oauth required
155+
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2Authentication", []);
156+
}
157+
158+
const response = await this.request({
159+
path: `/api/v1/workspaces/{slug}/projects/{project_id}/epics/{pk}/`.replace(`{${"pk"}}`, encodeURIComponent(String(requestParameters['pk']))).replace(`{${"project_id"}}`, encodeURIComponent(String(requestParameters['projectId']))).replace(`{${"slug"}}`, encodeURIComponent(String(requestParameters['slug']))),
160+
method: 'GET',
161+
headers: headerParameters,
162+
query: queryParameters,
163+
}, initOverrides);
164+
165+
return new runtime.JSONApiResponse(response, (jsonValue) => EpicFromJSON(jsonValue));
166+
}
167+
168+
/**
169+
* Retrieve an epic by id
170+
* Retrieve an epic
171+
*/
172+
async retrieveEpic(requestParameters: RetrieveEpicRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Epic> {
173+
const response = await this.retrieveEpicRaw(requestParameters, initOverrides);
174+
return await response.value();
175+
}
176+
177+
}

src/apis/IntakeApi.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* The Plane REST API
55
* The Plane REST API Visit our quick start guide and full API documentation at [developers.plane.so](https://developers.plane.so/api-reference/introduction).
66
*
7-
* The version of the API Spec: 0.0.1
7+
* The version of the API Spec: 0.0.2
88
* Contact: [email protected]
99
*
1010
* NOTE: This class is auto generated.

src/apis/LabelsApi.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* The Plane REST API
55
* The Plane REST API Visit our quick start guide and full API documentation at [developers.plane.so](https://developers.plane.so/api-reference/introduction).
66
*
7-
* The version of the API Spec: 0.0.1
7+
* The version of the API Spec: 0.0.2
88
* Contact: [email protected]
99
*
1010
* NOTE: This class is auto generated.

src/apis/MembersApi.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* The Plane REST API
55
* The Plane REST API Visit our quick start guide and full API documentation at [developers.plane.so](https://developers.plane.so/api-reference/introduction).
66
*
7-
* The version of the API Spec: 0.0.1
7+
* The version of the API Spec: 0.0.2
88
* Contact: [email protected]
99
*
1010
* NOTE: This class is auto generated.

0 commit comments

Comments
 (0)