Skip to content

Feat: Make people's first request easy#9950

Open
CurryYangxx wants to merge 7 commits into
developfrom
feat/first-request-creation
Open

Feat: Make people's first request easy#9950
CurryYangxx wants to merge 7 commits into
developfrom
feat/first-request-creation

Conversation

@CurryYangxx
Copy link
Copy Markdown
Member

@CurryYangxx CurryYangxx commented May 25, 2026

This pull request introduces a new "First Request Creation" experience to the project landing page, allowing users to quickly create or select a collection and immediately add a request, with improved state handling and flexibility around redirection after creation. It also adds a new generic SelectPopover component for reusable dropdown selection UIs, and implements in-memory tracking of recent project requests. Several backend and UI changes support these new flows, including enhancements to workspace and request creation APIs.

New UI Components and Flows:

  • Added a reusable SelectPopover component in select-popover.tsx for dropdown selection UIs.
  • Introduced the FirstRequestCreation component on the project landing page, enabling users to select or create a collection and jump directly into creating their first request. [1] [2] [3] [4] [5]

Workspace and Request Creation Enhancements:

  • Updated workspace creation to support an optional redirectAfterCreate flag, allowing the UI to control whether to redirect after creation or remain on the current page, and updated the fetcher/action logic accordingly. [1] [2] [3] [4]
  • Improved new request creation API to accept partial request data, pre-fill fields like name, URL, body, and authentication, and support custom request initialization from the UI. [1] [2] [3]
  • Added support for passing mcpServerUrl when creating a new workspace for MCP clients. [1] [2]

Recent Requests Tracking:

  • Implemented in-memory tracking of recent requests per project, with automatic cleanup on request deletion, to support "Jump back in" and similar features.

Miscellaneous Improvements:

  • Enhanced project loader logic to handle first-time landing for personal organizations, improving onboarding experience.

These changes collectively improve the onboarding experience for new users, streamline request and workspace creation, and lay the groundwork for tracking recent activity within projects.<!--
Please open an Issue first to discuss new
features or non-trivial changes. Please provide as much detail as possible on the change as
possible including general description, implementation details, potential shortcomings, etc.

If this PR closes an issue, please mention "Closes #XX" where #XX is the issue number.

If this PR fixes a bug or regression, please make sure to add a test.
-->
INS-2379

image

@CurryYangxx CurryYangxx force-pushed the feat/first-request-creation branch from 4e85134 to 9787c7a Compare May 26, 2026 09:43
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 26, 2026

✅ Circular References Report

Generated at: 2026-05-27T03:46:09.633Z
Status: ✅ NO CHANGE

Summary

Metric Base (develop) PR Change
Total Circular References 19 19 0 (0.00%)
Click to view all circular references in PR (19)
insomnia-inso/src/db/models/types.ts -> insomnia-inso/src/db/types.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/cancellation.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/cancellation.ts -> insomnia/src/script-executor.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/cancellation.ts -> insomnia/src/script-executor.ts -> insomnia/src/scripting/require-interceptor.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/concurrency.ts
insomnia/src/network/network.ts -> insomnia/src/common/render.ts
insomnia/src/network/network.ts -> insomnia/src/common/render.ts -> insomnia/src/templating/index.ts -> insomnia/src/plugins/index.ts -> insomnia/src/plugins/context/app.ts -> insomnia/src/templating/types.ts -> insomnia/src/plugins/context/network.ts
insomnia/src/network/network.ts -> insomnia/src/main/network/get-auth-header.ts -> insomnia/src/main/network/o-auth-2/get-token.ts
insomnia/src/plugins/index.ts -> insomnia/src/plugins/context/app.ts -> insomnia/src/templating/types.ts -> insomnia/src/plugins/context/store.ts
insomnia/src/plugins/index.ts -> insomnia/src/plugins/misc.ts
insomnia/src/templating/base-extension-worker.ts -> insomnia/src/templating/worker.ts
insomnia/src/templating/index.ts -> insomnia/src/templating/base-extension.ts
insomnia/src/templating/types.ts -> insomnia/src/plugins/context/network.ts
insomnia/src/templating/types.ts -> insomnia/src/templating/utils.ts
insomnia/src/ui/components/settings/import-export.tsx -> insomnia/src/ui/components/modals/export-requests-modal.tsx
insomnia/src/ui/components/tabs/tab-list.tsx -> insomnia/src/ui/components/tabs/tab.tsx
insomnia/src/ui/components/templating/tag-editor-arg-sub-form.tsx -> insomnia/src/ui/components/templating/external-vault/external-vault-form.tsx
insomnia/src/ui/components/viewers/response-viewer.tsx -> insomnia/src/ui/components/viewers/response-multipart-viewer.tsx
Click to view all circular references in base branch (19)
insomnia-inso/src/db/models/types.ts -> insomnia-inso/src/db/types.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/cancellation.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/cancellation.ts -> insomnia/src/script-executor.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/cancellation.ts -> insomnia/src/script-executor.ts -> insomnia/src/scripting/require-interceptor.ts
insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts -> insomnia/src/network/network.ts -> insomnia/src/network/concurrency.ts
insomnia/src/network/network.ts -> insomnia/src/common/render.ts
insomnia/src/network/network.ts -> insomnia/src/common/render.ts -> insomnia/src/templating/index.ts -> insomnia/src/plugins/index.ts -> insomnia/src/plugins/context/app.ts -> insomnia/src/templating/types.ts -> insomnia/src/plugins/context/network.ts
insomnia/src/network/network.ts -> insomnia/src/main/network/get-auth-header.ts -> insomnia/src/main/network/o-auth-2/get-token.ts
insomnia/src/plugins/index.ts -> insomnia/src/plugins/context/app.ts -> insomnia/src/templating/types.ts -> insomnia/src/plugins/context/store.ts
insomnia/src/plugins/index.ts -> insomnia/src/plugins/misc.ts
insomnia/src/templating/base-extension-worker.ts -> insomnia/src/templating/worker.ts
insomnia/src/templating/index.ts -> insomnia/src/templating/base-extension.ts
insomnia/src/templating/types.ts -> insomnia/src/plugins/context/network.ts
insomnia/src/templating/types.ts -> insomnia/src/templating/utils.ts
insomnia/src/ui/components/settings/import-export.tsx -> insomnia/src/ui/components/modals/export-requests-modal.tsx
insomnia/src/ui/components/tabs/tab-list.tsx -> insomnia/src/ui/components/tabs/tab.tsx
insomnia/src/ui/components/templating/tag-editor-arg-sub-form.tsx -> insomnia/src/ui/components/templating/external-vault/external-vault-form.tsx
insomnia/src/ui/components/viewers/response-viewer.tsx -> insomnia/src/ui/components/viewers/response-multipart-viewer.tsx

Analysis

No Change: This PR does not introduce or remove any circular references.


This report was generated automatically by comparing against the develop branch.

@CurryYangxx CurryYangxx force-pushed the feat/first-request-creation branch from 9787c7a to 4b53167 Compare May 26, 2026 09:50
@CurryYangxx CurryYangxx marked this pull request as ready for review May 27, 2026 03:23
Copilot AI review requested due to automatic review settings May 27, 2026 03:23
@CurryYangxx CurryYangxx force-pushed the feat/first-request-creation branch from 4b53167 to d3660e7 Compare May 27, 2026 03:24
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new “first request” onboarding experience on the project landing page, along with supporting UI primitives and lightweight in-memory tracking to enable “Jump back in” recent-request shortcuts. It also extends workspace/request creation flows to support non-redirecting creation and partial request prefill.

Changes:

  • Added FirstRequestCreation landing-page component and a reusable SelectPopover dropdown primitive.
  • Introduced in-memory “recent requests per project” tracking and recorded activity from HTTP/WebSocket/gRPC send/connect actions.
  • Enhanced workspace creation to optionally skip redirect (redirectAfterCreate) and request creation to accept Partial<Request> for pre-filling.

Reviewed changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
packages/insomnia/src/ui/components/workspace/resource-icon.tsx Replaces inline method badges with shared RequestBadge rendering.
packages/insomnia/src/ui/components/websockets/action-bar.tsx Records recent requests when connecting WS/Socket.IO requests.
packages/insomnia/src/ui/components/tags/method-tag.tsx Adds reusable RequestBadge + badge color mapping helpers.
packages/insomnia/src/ui/components/svg-icon.tsx Registers a new graphql SVG icon in the icon registry.
packages/insomnia/src/ui/components/request-url-bar.tsx Records recent requests when sending/connecting requests; minor formatting.
packages/insomnia/src/ui/components/panes/grpc-request-pane.tsx Records recent requests when starting gRPC calls; pulls projectId from params.
packages/insomnia/src/ui/components/modals/new-workspace-modal.tsx Adds redirectAfterCreate support + callback after create without relying on redirects.
packages/insomnia/src/ui/components/first-request-creation.tsx New onboarding UI for creating/selecting a collection and creating the first request.
packages/insomnia/src/ui/components/assets/svgr/IcnGraphql.tsx Adds the GraphQL SVG asset component.
packages/insomnia/src/routes/organization.$organizationId.project.$projectId.workspace.new.tsx Adds mcpServerUrl support and optional non-redirect creation via query param.
packages/insomnia/src/routes/organization.$organizationId.project.$projectId.workspace.$workspaceId.debug.request.new.tsx Accepts Partial<Request> and prefills some fields during request creation.
packages/insomnia/src/routes/organization.$organizationId.project.$projectId.tsx Persists a “personal org first landing handled” marker in localStorage.
packages/insomnia/src/routes/organization.$organizationId.project.$projectId._index.tsx Integrates FirstRequestCreation into the project landing page and wires workspace modal behavior.
packages/insomnia/src/routes/organization.$organizationId.project._index.tsx Auto-creates an initial local project/collection for first-time personal org landings.
packages/insomnia/src/common/project.ts Implements in-memory recent-request tracking + cleanup on request deletion.
packages/insomnia/src/basic-components/select-popover.tsx New generic popover-based selection component built on react-aria-components.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +270 to 279
const query = new URLSearchParams();

if (redirectAfterCreate !== undefined) {
query.set('redirectAfterCreate', String(redirectAfterCreate));
}

return submit(JSON.stringify(workspaceData), {
method: 'POST',
action: href('/organization/:organizationId/project/:projectId/workspace/new', {
organizationId,
projectId,
}),
action: query.size ? `${action}?${query.toString()}` : action,
encType: 'application/json',
Comment on lines +231 to +252
const graphqlQuery = `
query {
viewer {
repositories(first: 100, privacy: PUBLIC, affiliations: [OWNER]) {
nodes {
name
description
url
stargazerCount
}
}
}
}
`;

const githubGraphqlLookupCurl = `curl --request POST \
--url https://api.github.com/graphql \
--header 'Authorization: Bearer replace with your own token' \
--header 'Content-Type: application/json' \
--header 'User-Agent: insomnia/12.5.1-alpha.0' \
--data '{"query":"${graphqlQuery}"}'`;

Comment thread packages/insomnia/src/ui/components/first-request-creation.tsx Outdated
Comment thread packages/insomnia/src/ui/components/first-request-creation.tsx Outdated
CurryYangxx and others added 2 commits May 27, 2026 11:39
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants