> ## Documentation Index
> Fetch the complete documentation index at: https://docs.activeviam.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Load saved historical VaR position P&L vectors into Atoti.

> Requires authenticated VaR report, organisation, portfolio and market-data access and explicitly enabled Atoti services for local development or the caller's organisation in the current environment. Queues the original saved full historical VaR snapshot without rerunning the report or applying current page overrides. Imports base position P&L observations and calculates grouped historical VaR using saved weighting settings and the saved confidence level as the default for Atoti query-context overrides. Expected shortfall is not calculated. Reports with row restrictions or restricted-user access to another owner's report are rejected. Position metadata is stored once and joined to compact position-observation rows in Atoti. Imports default to 20,000,000 observations and 256 MiB of combined Parquet artifacts; configured capacity can increase these limits to 100,000,000 observations and 1 GiB respectively. Position metadata remains limited to 50 MiB. The configured byte budget applies across both position and observation artifacts. Saved-report preparation defaults to a 300-second deadline, configurable up to 1800 seconds; adapter import has its own separate deadline. Poll VarStatus while loading. A loading response may expose an empty dashboard when dashboard_ready is true, after schema, layout and deny-all access controls are published. Repeated opens reuse an existing cube session and restore the authenticated user's saved dashboard for this organisation and report definition, binding the layout to the requested saved run; call VarOpen again after a failed import or session restart to retry. Set restore_cube_only to true to prepare or check the report cubes without creating or rebinding a personal dashboard; responses then have a null dashboard URL. The default is false. Use the same flag on Open and Status, or VarOpen and VarStatus, when restoring data for an existing dashboard. All report access checks still apply. Set dashboard_template_only to true on both open and status requests to obtain an unsaved dashboard_template JSON layout once report data is ready, without creating or rebinding a personal dashboard. This flag defaults to false, takes precedence over restore_cube_only, and keeps the dashboard URL null; loading responses do not contain a template.



## OpenAPI

````yaml /risk-and-pricing/atoti-risk-services/apis-endpoints/openapi/openapi.mintlify.json post /api/AtotiReport/VarOpen
openapi: 3.0.4
info:
  title: Derivitec Api 1.0
  version: '1.0'
servers:
  - url: https://api.riskportal.activeviam.com
security:
  - oauth2: []
  - apikey: []
tags:
  - name: AdminUser
  - name: AtotiReport
  - name: AtotiSession
  - name: BloombergOAuth
  - name: Bond
  - name: BondYieldCurvePage
  - name: BookAccess
  - name: Books
  - name: Commodity
  - name: Counterparties
  - name: Currencies
  - name: Equity
  - name: EquityDividend
  - name: EquityPage
  - name: FeatureFlag
  - name: Fx
  - name: FxPage
  - name: GroupAccess
  - name: Home
  - name: LegacyPosition
  - name: MarketData
  - name: MarketDataProvider
  - name: MarketDataProviderAccess
  - name: Meta
  - name: Notification
  - name: Organisation
  - name: PnLReport
  - name: PortfolioAccess
  - name: Portfolios
  - name: Position
  - name: PositionFilter
  - name: PricingEnvironment
  - name: PricingEnvironmentAccess
  - name: RateAsset
  - name: RateAssetPage
  - name: Report
  - name: ReportDefinition
  - name: ReportHistoryLauncherQuery
  - name: ReportLauncher
  - name: ReportQuery
  - name: ReportQueryViewUser
  - name: ReportRestriction
  - name: ReportView
  - name: RiskReport
  - name: Tradable
  - name: TradeBooking
  - name: User
  - name: VarReport
  - name: VarReportQuery
  - name: YieldCurvePage
paths:
  /api/AtotiReport/VarOpen:
    post:
      tags:
        - AtotiReport
      summary: Load saved historical VaR position P&L vectors into Atoti.
      description: >-
        Requires authenticated VaR report, organisation, portfolio and
        market-data access and explicitly enabled Atoti services for local
        development or the caller's organisation in the current environment.
        Queues the original saved full historical VaR snapshot without rerunning
        the report or applying current page overrides. Imports base position P&L
        observations and calculates grouped historical VaR using saved weighting
        settings and the saved confidence level as the default for Atoti
        query-context overrides. Expected shortfall is not calculated. Reports
        with row restrictions or restricted-user access to another owner's
        report are rejected. Position metadata is stored once and joined to
        compact position-observation rows in Atoti. Imports default to
        20,000,000 observations and 256 MiB of combined Parquet artifacts;
        configured capacity can increase these limits to 100,000,000
        observations and 1 GiB respectively. Position metadata remains limited
        to 50 MiB. The configured byte budget applies across both position and
        observation artifacts. Saved-report preparation defaults to a 300-second
        deadline, configurable up to 1800 seconds; adapter import has its own
        separate deadline. Poll VarStatus while loading. A loading response may
        expose an empty dashboard when dashboard_ready is true, after schema,
        layout and deny-all access controls are published. Repeated opens reuse
        an existing cube session and restore the authenticated user's saved
        dashboard for this organisation and report definition, binding the
        layout to the requested saved run; call VarOpen again after a failed
        import or session restart to retry. Set restore_cube_only to true to
        prepare or check the report cubes without creating or rebinding a
        personal dashboard; responses then have a null dashboard URL. The
        default is false. Use the same flag on Open and Status, or VarOpen and
        VarStatus, when restoring data for an existing dashboard. All report
        access checks still apply. Set dashboard_template_only to true on both
        open and status requests to obtain an unsaved dashboard_template JSON
        layout once report data is ready, without creating or rebinding a
        personal dashboard. This flag defaults to false, takes precedence over
        restore_cube_only, and keeps the dashboard URL null; loading responses
        do not contain a template.
      operationId: VarOpen
      requestBody:
        description: >-
          Required completed full historical VaR run identifier. Caller
          identity, organisation and access restrictions are supplied by the
          service.
        content:
          application/json-patch+json:
            schema:
              $ref: '#/components/schemas/AtotiVarReportOpenRequest'
          application/json:
            schema:
              $ref: '#/components/schemas/AtotiVarReportOpenRequest'
          text/json:
            schema:
              $ref: '#/components/schemas/AtotiVarReportOpenRequest'
          application/*+json:
            schema:
              $ref: '#/components/schemas/AtotiVarReportOpenRequest'
      responses:
        '200':
          description: >-
            Returns loading or ready, with a trusted dashboard URL once
            dashboard_ready is true (null for cube-only restoration), or a
            failure envelope explaining configuration, snapshot or import
            limitations.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AtotiReportResponse'
        '400':
          description: BadRequest
        '401':
          description: Authentication is required.
        '403':
          description: Forbidden
      security:
        - oauth2: []
        - apikey: []
components:
  schemas:
    AtotiVarReportOpenRequest:
      required:
        - $type
        - report_id
      type: object
      additionalProperties: false
      description: >-
        Queues position P&L vectors from an authorised completed historical VaR
        snapshot for Atoti inspection.
      properties:
        report_id:
          minLength: 1
          type: string
          description: >-
            Required opaque identifier of the completed full historical VaR
            report run. This is not a report definition identifier or a
            single-observation historical P&L output identifier.
          example: synthetic-var-report-run
        restore_cube_only:
          type: boolean
          description: >-
            When true, prepares or checks only the saved historical VaR cubes
            without creating, rebinding or opening a personal dashboard.
            Defaults to false. Access checks still apply, and responses have a
            null dashboard URL. Use the same value when polling status to
            preserve an existing dashboard layout.
          example: true
        dashboard_template_only:
          type: boolean
          description: >-
            When true, returns an unsaved dashboard layout as JSON once report
            data is ready, without creating, rebinding or opening a personal
            dashboard. Defaults to false and takes precedence over
            restore_cube_only. All report access checks apply. Send the same
            value on open and status requests; the dashboard URL remains null.
          example: true
        $type:
          type: string
          enum:
            - >-
              Derivitec.Web.Core.Atoti.AtotiVarReportOpenRequest,
              Derivitec.Web.Core
    AtotiReportResponse:
      required:
        - $type
      type: object
      properties:
        is_success:
          type: boolean
          description: >-
            Whether the operation completed successfully. The default is `true`;
            error outcomes set it to `false`.
          example: true
        error_messages:
          type: array
          items:
            type: string
          description: >-
            Messages explaining operation-level failures. The collection is
            empty by default.
          nullable: true
        state:
          type: string
          description: >-
            Current state: loading while queued or importing, ready when the
            current session has committed report data and access permissions, or
            failed when unavailable, unauthorized or incompatible. Defaults to
            failed.
          nullable: true
          example: loading
        message:
          type: string
          description: >-
            Human-readable progress or failure explanation. Null when no
            additional explanation is supplied.
          nullable: true
        dashboard_ready:
          type: boolean
          description: >-
            True when the current session has published the report cube schema
            and dashboard layout with access controls that deny report rows
            until data and permissions commit. May be true while state is
            loading; this does not indicate that report data is ready. Defaults
            to false and remains available for cube-only restoration.
          example: true
        dashboard_url:
          type: string
          description: >-
            Trusted dashboard URL (portal-relative in Release, loopback in local
            development), present when ready or when loading with
            dashboard_ready true. Loading dashboards may be empty; continue
            polling until state is ready for report data. Null before dashboard
            readiness, after failure, or when restore_cube_only or
            dashboard_template_only is true; expires when the session restarts.
          nullable: true
        dashboard_template:
          type: string
          description: >-
            JSON-encoded unsaved dashboard layout object for the requested saved
            run. Present only when dashboard_template_only is true and report
            data is ready; null while loading, after failure, and for other
            request modes. The caller can display this layout without saving a
            personal dashboard.
          nullable: true
        $type:
          type: string
          enum:
            - Derivitec.Web.Core.Atoti.AtotiReportResponse, Derivitec.Web.Core
      additionalProperties: false
      description: >-
        Progress and navigation information for loading a saved report into
        Atoti.
  securitySchemes:
    oauth2:
      type: oauth2
      description: >-
        OAuth2 access-token requested from AWS Cognito and provided as a Auth
        Bearer header
      flows:
        implicit:
          authorizationUrl: https://auth.riskportal.derivitec.com/oauth2/authorize
          scopes: {}
    apikey:
      type: apiKey
      description: API-Key requested via the site and provided as a header
      name: x-api-key
      in: header

````