Skip to content

Commit f0ce79f

Browse files
committed
chore: fix links in linear agent blog post
1 parent e13e6e9 commit f0ce79f

2 files changed

Lines changed: 32 additions & 20 deletions

File tree

  • site/src/posts/2025-05-28-building-linear-agents-in-node-js-and-rivet-full-walkthrough-and-starter-kit

Cargo.lock

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

site/src/posts/2025-05-28-building-linear-agents-in-node-js-and-rivet-full-walkthrough-and-starter-kit/page.mdx

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ This project is built with:
1717
- [Linear SDK](https://developers.linear.app/docs/sdk/installation) for Linear API integration
1818
- [AI SDK](https://ai-sdk.dev) for AI-powered responses
1919

20-
[View Source Code on GitHub](https://github.com/rivet-gg/rivet/tree/main/examples/linear-agent-starter).
20+
[View Source Code on GitHub](https://github.com/rivet-gg/rivet/tree/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter).
2121

2222
## TL;DR
2323

24-
The core functionality is in [`src/actors/issue-agent.ts`](https://github.com/rivet-gg/rivet/blob/05-27-docs_add_linear-agent-starter_example/examples/linear-agent-starter/src/actors/issue-agent.ts), where the agent handles different types of Linear events and interfaces with the LLM.
24+
The core functionality is in [`src/actors/issue-agent.ts`](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/issue-agent.ts), where the agent handles different types of Linear events and interfaces with the LLM.
2525

2626
## Walkthrough
2727

@@ -34,15 +34,15 @@ The Linear integration works through the following steps:
3434

3535
The system exposes three endpoints:
3636

37-
- `GET /connect-linear`: Initiates the Linear OAuth flow
38-
- `GET /oauth/callback/linear`: OAuth callback endpoint
39-
- `POST /webhook/linear`: Receives Linear webhook events
37+
- `GET /connect-linear`: Initiates the Linear OAuth flow ([src/server/index.ts](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/server/index.ts#L41))
38+
- `GET /oauth/callback/linear`: OAuth callback endpoint ([src/server/index.ts](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/server/index.ts#L82))
39+
- `POST /webhook/linear`: Receives Linear webhook events ([src/server/index.ts](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/server/index.ts#L116))
4040

4141
And maintains state using three main [ActorCore](https://actorcore.org) actors:
4242

43-
1. **Issue Agent** (`src/actors/issue-agent.ts`): Handles Linear issue events and generates responses
44-
2. **Linear App User** (`src/actors/linear-app-user.ts`): Manages authentication state for the application
45-
3. **OAuth Session** (`src/actors/oauth-session.ts`): Handles OAuth flow state
43+
1. **Issue Agent**: Handles Linear issue events and generates responses ([src/actors/issue-agent.ts](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/issue-agent.ts#L11))
44+
2. **Linear App User**: Manages authentication state for the application ([src/actors/linear-app-user.ts](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/linear-app-user.ts#L6))
45+
3. **OAuth Session**: Handles OAuth flow state ([src/actors/oauth-session.ts](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/oauth-session.ts#L10))
4646

4747
<Tip>
4848
You can read more about actors [in the ActorCore documentation](https://actorcore.org/concepts/overview).
@@ -56,9 +56,9 @@ Before our agent can interact with a Linear workspace, we need to set up authent
5656

5757
**Step 1: Initial OAuth Request**
5858

59-
The user is directed to `GET /connect-linear` to initiate the OAuth flow:
59+
The user is directed to `GET /connect-linear` ([src/server/index.ts](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/server/index.ts#L41)) to initiate the OAuth flow:
6060
- We generate a secure session with a unique ID and nonce
61-
- We store this state in an `oauthSession` ActorCore actor
61+
- We store this state in an [`oauthSession`](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/oauth-session.ts#L10) ActorCore actor
6262
- We redirect to Linear's authorization page with our OAuth parameters
6363

6464
```typescript {{"title":"src/server/index.ts"}}
@@ -113,7 +113,7 @@ When the user completes authentication, Linear redirects to our callback URL wit
113113
- We validate the state parameter for security
114114
- We exchange the code for an access token
115115
- We get the app user ID for the agent in this workspace (our unique identifier for this workspace)
116-
- We store the access token in the `linearAppUser` ActorCore actor
116+
- We store the access token in the [`linearAppUser`](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/linear-app-user.ts#L6) ActorCore actor
117117

118118
```typescript {{"title":"src/server/index.ts"}}
119119
router.get("/oauth/callback/linear", async (c) => {
@@ -156,7 +156,7 @@ After OAuth completes, our agent is fully integrated with the Linear workspace:
156156

157157
Once a user has authorized our application in their Linear workspace, Linear sends webhook events to our endpoint whenever something happens that involves our agent.
158158

159-
The server parses these events and routes them to the appropriate handlers in `src/actors/issue-agent.ts`:
159+
The server parses these events and routes them to the appropriate handlers in [`src/actors/issue-agent.ts`](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/issue-agent.ts#L11):
160160

161161
- **`issueMention`**: Triggered when the agent is mentioned in an issue description
162162
- **`issueEmojiReaction`**: Triggered when someone reacts with an emoji to an issue
@@ -365,7 +365,7 @@ Before getting started with building your own Linear agent, make sure you have:
365365

366366
### Adding Your Own Functionality
367367

368-
The core of the agent is in `src/actors/issue-agent.ts`. You can customize:
368+
The core of the agent is in [`src/actors/issue-agent.ts`](https://github.com/rivet-gg/rivet/blob/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter/src/actors/issue-agent.ts#L11). You can customize:
369369

370370
1. **Event Handlers**: Modify actions for different Linear events:
371371

@@ -441,5 +441,5 @@ When building a Linear agent, consider these practices for a better developer ex
441441

442442
You can find the complete source code for this Linear agent starter kit on GitHub:
443443

444-
[View Source Code on GitHub](https://github.com/rivet-gg/rivet/tree/main/examples/linear-agent-starter)
444+
[View Source Code on GitHub](https://github.com/rivet-gg/rivet/tree/e13e6e95c56ea63bc73312fa7d01a647412ac507/examples/linear-agent-starter)
445445

0 commit comments

Comments
 (0)