This year I built a little over twenty Forge apps for Jira, and 14 of them are now live on the Atlassian Marketplace. Most of what I know about Forge I learned from something that passed every check and still didn't work.
This series covers the parts the hello world skips. Part 1 starts at the very beginning: what a Forge app actually is, a small working app (a panel that counts a work item's links), and the five mistakes from my own apps I'd warn you about first.
What Forge is, in one picture
You don't run a server. Your UI runs inside Jira, your backend code (a "resolver") runs on Atlassian's cloud, and manifest.yml ties it all together. The manifest also lists the scopes your app needs, such as read:jira-work to read work items.
That last part matters more than it looks: adding a scope later turns the next release into a major version, and every site that installed your app has to approve it before they get it. I'll come back to that in mistake 5.
Before you start
- Node.js 22 or 24. The docs ask for 22.23.4+ or 24.22.1+.
- The CLI:
npm install -g @forge/cli, thenforge --version. - Log in:
forge loginasks for your email and an API token. Create the token at id.atlassian.com  Security  API tokens, choosing "Create API token with scopes" and Forge as the app. - A Jira site to test on.
forge install --demo-sitegives you one (it lasts 90 days), or create a free developer site at go.atlassian.com/cloud-dev.
The app: a panel that counts links
On a big work item it's hard to see at a glance what it blocks and what blocks it. So the panel lists the links by type: "2 ┬À is blocked by", "1 ┬À relates to".
Start from the official template. The name you give becomes the folder:
forge create link-count --template jira-issue-panel-ui-kit cd link-count npm install @forge/api The first time, forge create asks which developer space the app belongs to and asks you to accept the developer terms. The template doesn't include @forge/api, which the backend below needs, hence the last line.
The manifest
modules: jira:issuePanel: - key: link-count-panel resource: main resolver: function: resolver render: native title: Link count icon: https://developer.atlassian.com/platform/forge/images/icons/issue-panel-icon.svg function: - key: resolver handler: index.handler resources: - key: main path: src/frontend/index.jsx permissions: scopes: - read:jira-work app: runtime: name: nodejs24.x memoryMB: 256 architecture: arm64 id: '<your app id>' render: native means UI Kit: you write React with Atlassian's components and Jira draws them. Compared with the template, I renamed the key and title and added the permissions block. Without read:jira-work, the call in the next step fails.
The resolver (backend)
// src/resolvers/index.js import Resolver from '@forge/resolver'; import api, { route } from '@forge/api'; const resolver = new Resolver(); resolver.define('getLinkCounts', async ({ context }) => { const issueKey = context.extension.issue.key; const res = await api.asUser().requestJira( route`/rest/api/3/issue/${issueKey}?fields=issuelinks` ); // A failed read must not look like "no links" if (!res.ok) throw new Error(`Jira returned ${res.status}`); const data = await res.json(); const links = data.fields.issuelinks ?? []; // Count by the wording Jira shows: "blocks", "is blocked by"... const counts = {}; for (const link of links) { const label = link.outwardIssue ? link.type.outward : link.type.inward; counts[label] = (counts[label] ?? 0) + 1; } return { total: links.length, counts }; }); export const handler = resolver.getDefinitions(); Three things here I'd keep in every app:
-
asUser(): the call runs with the permissions of the person looking at the page, so the app can't show them something they couldn't open themselves. -
route: the tagged template escapes the issue key for you. Pass a plain string instead and@forge/apithrows: "You must create your route using the 'route' export". -
if (!res.ok) throw: if this line is missing, a 403 looks exactly like "this work item has no links". Silent zeros are the worst kind of bug, because nobody reports them.
The UI (frontend)
// src/frontend/index.jsx import React, { useEffect, useState } from 'react'; import ForgeReconciler, { Inline, Lozenge, SectionMessage, Spinner, Stack, Text, } from '@forge/react'; import { invoke } from '@forge/bridge'; const App = () => { const [data, setData] = useState(null); const [error, setError] = useState(null); useEffect(() => { invoke('getLinkCounts').then(setData).catch((e) => setError(e.message)); }, []); if (error) { return ( <SectionMessage appearance="error"> <Text>Couldn't read the links: {error}</Text> </SectionMessage> ); } if (!data) return <Spinner label="Loading links" />; if (data.total === 0) return <Text>No linked work items yet.</Text>; return ( <Stack space="space.100"> <Text>{data.total} linked work items</Text> {Object.entries(data.counts).map(([label, n]) => ( <Inline key={label} space="space.100" alignBlock="center"> <Lozenge>{n}</Lozenge> <Text>{label}</Text> </Inline> ))} </Stack> ); }; ForgeReconciler.render( <React.StrictMode> <App /> </React.StrictMode> ); invoke('getLinkCounts') is the bridge between the two halves. Give every panel three states besides the happy one: loading, error and empty. A blank panel makes people think the app is broken, and they're right.
One detail on the error state: the message that reaches the UI isn't exactly the one you threw. Forge wraps it, so a 403 shows as "There was an error invoking the function - Jira returned 403". Fine for a demo; in a real app, map it to a sentence a user understands.
Run it
forge deploy forge install # pick Jira and your site forge tunnel # now edit, save, refresh the Jira page Open any work item and look for the app under View app actions. In a service project it's a button in the action bar instead.
The commands confused me at first, so here's the table I wish I'd had:
forge tunnel runs your code from your machine, so you only refresh the page. When you stop tunnelling, run forge deploy again, or the site keeps the last deployed version.
This is roughly where my own link counter started. The version on the Marketplace today groups links by type and shows each linked item's status, but the core is the same call you just wrote:
Five things that broke for me
All of these are real, from my own apps, and none of them was caught by the linter, TypeScript or my unit tests.
1. A made-up event name lints clean and never fires
I wrote scheduled jobs with triggers like avi:forge:scheduled:hourly, and a sprint trigger on avi:jira:sprint:completed. forge lint accepted them (I checked again while writing this: CLI 15.1 still says "No issues found"). They don't exist. Three apps had schedules that never ran, and a fourth app's sprint report never started.
Fix: schedules are scheduledTrigger modules with interval: fiveMinute | hour | day | week. Check every event name against the Forge events reference by hand, because nothing else will.
2. requestJira imported on its own is not logged in
import { requestJira } from '@forge/api'; // every call: 401 import api from '@forge/api'; api.asApp().requestJira(...) // or api.asUser() The bare import isn't authenticated, so every call returned 401 "Client must be authenticated". In my licence-audit app the scan "worked" and reported zero users, because I didn't check res.ok. That's why the resolver above throws.
3. A resolver's null arrives as {}
A resolver that returns null reaches the browser as an empty object. So does one that returns nothing. I first hit this in Custom UI (your own React app in an iframe), and while testing this article I found UI Kit does exactly the same. if (result) is true, the next line reads result.config.something, and the panel crashes into its error state. The resolver succeeded, so forge logs shows nothing.
Fix: return a wrapper ({ config: null }) or check the shape before using it.
4. window.confirm() does nothing
The app's frame is sandboxed without modals. confirm() returns false straight away, so the code after "Are you sure?" never runs. In one of my apps, deleting a policy had never worked. Nobody had told me.
Fix: ask inside the page: an inline "Delete? Yes / No" next to the button.
5. A new scope is a bigger release than it looks
Adding a scope changes the app's permissions, so forge deploy treats it as a major version. It stops with MAJOR_VERSION_RULE until you run forge deploy --approve MAJOR_VERSION_RULE, and then you run forge install --upgrade on your own sites. Sites that already installed your app keep the old version until their admin approves the new permissions. On a live app, some sites take a long time to do that.
Fix: think about scopes up front. My own rule for routine releases now: no new scopes and no new egress, ever. If a feature needs one, it waits for a planned major release.
What's next in the series
- Your first app (this one)
- The UI-to-resolver contract:
invokenames and payloads nothing checks, UI Kit vs Custom UI, and how I test both halves - Calling Jira properly:
asUservsasApp, pagination, and why team-managed boards vanish from "scrum boards" - Storage and scheduled jobs: KVS surprises, capping data, and personal data reporting
- Shipping it: environments, major vs minor versions, licences and trials, and my release checklist
- Moving from Connect to Forge before Connect support ends on 31 January 2027
If something here is wrong or out of date, tell me in the comments. Forge changes often, and I'd rather fix the article than have you lose an afternoon.
How I wrote this: I used an AI assistant to help structure and edit the draft and to draw the diagrams. The code, the mistakes and the fixes come from my own apps, and I checked the commands against the Forge docs on 30 November 2026. On 1 December I ran every code sample in this article in a test app on a real Jira site.







