You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: guides/build-plane-app.mdx
+162-6Lines changed: 162 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,9 +18,6 @@ Connect everything you already use. Your team probably uses 5-10 different tools
18
18
19
19
Build exactly what you need. Unlike rigid SaaS platforms, Plane's open-source nature means you can create integrations that fit your specific workflow.
20
20
21
-
### Promote Your Plane Integration
22
-
Contact us to help promote your Plane integration and feature it within blogs and Plane itself: [email protected]
23
-
24
21
## Prerequisites
25
22
26
23
- A [Plane](https://app.plane.so) workspace
@@ -56,9 +53,15 @@ To build an OAuth application with Plane:
56
53
57
54
### Generating Consent URL
58
55
59
-
Before handling authentication, if your app manages installation, you must generate the consent (authorization) URL to initiate the OAuth flow. Below is a sample Python implementation:
56
+
Before handling authentication, if your app manages installation, you must generate the consent (authorization) URL to initiate the OAuth flow. Below are sample implementations:
In this flow, your app exchanges the `code` received as a query parameter on the callback (to your `redirect_uri`) for an access token and refresh token. The access token is short-lived and must be refreshed using the refresh token when it expires. Both tokens should be securely stored.
In both user-authorized and app-authorized flows, the `app_installation_id` identifies the app's installation within a specific workspace. It is recommended that developers fetch workspace details after OAuth is successfully completed. Plane provides an `app-installation` endpoint that works with both types of tokens.
171
299
172
300
#### Examples
173
301
302
+
<Tabs>
303
+
<Tabtitle="Python">
304
+
174
305
```python
175
306
import requests
176
307
@@ -188,6 +319,29 @@ response = requests.get(
188
319
workspace_details = response.data[0]
189
320
```
190
321
322
+
</Tab>
323
+
<Tabtitle="TypeScript">
324
+
325
+
```typescript
326
+
importaxiosfrom'axios';
327
+
328
+
// Set authorization header with either access token or bot token
329
+
const headers = {
330
+
Authorization: `Bearer ${token}`,
331
+
};
332
+
333
+
// Make GET request to fetch installation/workspace details
To simplify the OAuth flow and make it easier to build Plane apps, official SDKs are available:
219
373
220
-
-**Node.js**: `npm i @makeplane/plane-node-sdk`
221
-
-**Python**: `pip install plane-sdk`
374
+
| Language | Package Link | Source Code |
375
+
|----------|---------|-------------|
376
+
| Node.js |[npm i @makeplane/plane-node-sdk](https://www.npmjs.com/package/@makeplane/plane-node-sdk)|[plane-node-sdk](https://github.com/makeplane/plane-node-sdk)|
0 commit comments