---
id: JNY-PFM-CSH-003
title: Open a shared record link and retain its context
feature: FEAT-PFM-CSH-03
product_area: platform
module: console-shell
revision: 2
status: draft
product_intent: proposed
implementation_evidence: observed
supersedes: []
source_sha:
  react-console: baf6dae382d6f41dce976c7f848667ccc37e076f
  services-platform: ad3f6a6582843008ed0f5a17b131878d15829af1
actor: ACT-PFM-002
goal: >-
  Reach a colleague’s shared record, signing in if necessary, and preserve the destination through
  subsequent browser navigation.
capabilities:
  - CAP-PFM-CSH-009
  - CAP-PFM-CSH-010
  - CAP-PFM-CSH-012
  - CAP-PFM-CSH-013
  - CAP-PFM-CSH-015
screens:
  - '/console/{tenantId}/crm/contacts/{contactId}'
  - /login
steps:
  - 'n': 1
    surface: '/console/{tenantId}/crm/contacts/{contactId}'
    action: Follows a contact link containing query information while signed out.
    capability: CAP-PFM-CSH-009
    expected: The sign-in experience begins.
    provenance: documented
    source: 'react-console:docs/url-architecture.md#6. Tenant from the URL'
  - 'n': 2
    surface: getMySecurityContext
    action: Signs in and waits for access to the workspace requested by the link.
    capability: CAP-PFM-CSH-010
    expected: The URL-entry request names the requested workspace explicitly.
    provenance: observed
    source: 'react-console:lib/security-context/provider.tsx:openTenantId'
  - 'n': 3
    surface: '/console/{tenantId}/crm/contacts/{contactId}'
    action: Completes entry to the requested contact.
    capability: CAP-PFM-CSH-009
    expected: 'The intended workspace, contact and query information remain the destination.'
    provenance: documented
    source: 'react-console:docs/url-architecture.md#6. Tenant from the URL'
  - 'n': 4
    surface: '/console/{tenantId}/crm/contacts/{contactId}'
    action: Reloads the record page.
    capability: CAP-PFM-CSH-009
    expected: The same workspace record remains open.
    provenance: test
    source: 'react-console:e2e/mock/url-architecture.mock.spec.ts#a record deep link survives a reload'
  - 'n': 5
    surface: '/console/{tenantId}/crm/contacts'
    action: Opens the contacts list and then uses browser history.
    capability: CAP-PFM-CSH-009
    expected: History restores the earlier contact and list destinations.
    provenance: documented
    source: 'react-console:docs/url-architecture.md#8. Tests'
alternates:
  - from_step: 1
    condition: The colleague sent a link using the earlier address scheme.
    path: Compatibility handling places it in the remembered workspace.
    outcome: The record identifier and query information survive the redirect.
    provenance: test
    source: >-
      react-console:e2e/mock/url-architecture.mock.spec.ts#an old tenant-less URL lands on its
      canonical URL, id and query kept
  - from_step: 2
    condition: A cleared Rhythm staff member follows the workspace link.
    path: The staff session enters the requested workspace directly.
    outcome: The requested contact becomes the working destination.
    provenance: documented
    source: 'react-console:docs/url-architecture.md#11. Decisions made during the build'
failures:
  - from_step: 2
    condition: The link names an unknown workspace.
    path: The workspace entry response presents not found.
    outcome: The requested workspace page remains unopened.
    provenance: test
    source: 'react-console:e2e/mock/url-architecture.mock.spec.ts#an id no tenant has shows not found'
  - from_step: 2
    condition: The person cannot reach the named workspace.
    path: The console explains the refusal and offers a reachable return context.
    outcome: The requested workspace is not entered.
    provenance: observed
    source: 'react-console:components/console/tenant-id-gate.tsx:TenantIdGate, deniedReturnTenant'
  - from_step: 2
    condition: The staff member has no clearance for the requested workspace.
    path: Rhythm HQ opens with an explanatory notice.
    outcome: The console does not start an emergency-access dialog.
    provenance: test
    source: >-
      react-console:e2e/controlled/staff-deep-link.controlled.spec.ts#an uncleared staff member's
      deep link goes to Rhythm HQ with a notice, not the emergency-access dialog
  - from_step: 3
    condition: The linked work is in an application unavailable to the organization.
    path: The page body explains product unavailability.
    outcome: Home and application-list destinations provide ways onward.
    provenance: test
    source: >-
      react-console:e2e/mock/application-access.mock.spec.ts#a deep link into one of them says the
      application isn't available
rules_in_play:
  - BR-CAP-PFM-CSH-009-06
  - BR-CAP-PFM-CSH-009-07
  - BR-CAP-PFM-CSH-010-01
  - BR-CAP-PFM-CSH-010-02
  - BR-CAP-PFM-CSH-010-03
  - BR-CAP-PFM-CSH-010-04
  - BR-CAP-PFM-CSH-010-09
  - BR-CAP-PFM-CSH-012-01
  - BR-CAP-PFM-CSH-013-07
  - BR-CAP-PFM-CSH-015-01
  - BR-CAP-PFM-SEC-007-06
  - BR-CAP-PFM-SEC-007-12
assertions:
  - id: AS-JNY-PFM-CSH-003-01
    statement: Sign-in can restore the page and query requested by a direct link.
    provenance: test
    source: >-
      react-console:e2e/dev/url-architecture.dev.spec.ts#a signed-out deep link goes through sign-in
      and comes back to the same page and query
  - id: AS-JNY-PFM-CSH-003-02
    statement: Reload preserves the workspace record destination.
    provenance: test
    source: 'react-console:e2e/mock/url-architecture.mock.spec.ts#a record deep link survives a reload'
  - id: AS-JNY-PFM-CSH-003-03
    statement: An unknown workspace identity produces a not-found response.
    provenance: test
    source: 'react-console:e2e/mock/url-architecture.mock.spec.ts#an id no tenant has shows not found'
  - id: AS-JNY-PFM-CSH-003-04
    statement: Compatibility handling retains the old link’s record identity and query.
    provenance: test
    source: >-
      react-console:e2e/mock/url-architecture.mock.spec.ts#an old tenant-less URL lands on its
      canonical URL, id and query kept
e2e_policy: required
e2e_reason: >-
  Sign-in return, workspace entry and browser history require browser evidence. Current bindings
  cover specific destinations; a contact-specific sign-in and history journey still needs direct
  proof.
evidence:
  - >-
    react-console at baf6dae: docs/url-architecture.md §6 to §8,
    components/console/tenant-id-gate.tsx, e2e/mock/url-architecture.mock.spec.ts,
    e2e/dev/{url-architecture,initialisation}.dev.spec.ts,
    e2e/controlled/staff-deep-link.controlled.spec.ts, e2e/mock/application-access.mock.spec.ts.
  - >-
    services-platform at ad3f6a6: modules/security/aws/api/access.routes.ts (getMySecurityContext
    with tenant_id; MOD-PFM-SEC).
proved_by: []
---

# Open a shared record link and retain its context

## Story

Lee follows a colleague’s contact link and signs in when prompted. The link supplies the intended workspace and record. Lee reloads the page and later moves between the record and list through browser history. If the workspace cannot be entered, the console explains that problem rather than silently changing the record destination.
