> ## 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.

# Adjust a date using a business-day convention.

> Use this operation to move a date according to the supplied calendar and business-day convention. The
calendar, date, and convention are required. The calculation is performed in memory and does not change
the calendar or any persisted market data.



## OpenAPI

````yaml /risk-and-pricing/atoti-risk-services/apis-endpoints/openapi/openapi.mintlify.json post /api/MarketData/AdjustBusinessDay
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/MarketData/AdjustBusinessDay:
    post:
      tags:
        - MarketData
      summary: Adjust a date using a business-day convention.
      description: >-
        Use this operation to move a date according to the supplied calendar and
        business-day convention. The

        calendar, date, and convention are required. The calculation is
        performed in memory and does not change

        the calendar or any persisted market data.
      operationId: AdjustBusinessDay
      requestBody:
        description: >-
          The calculation payload containing a calendar, the date to adjust as
          an ISO 8601 date/time value, and the `BDC` enum value that selects the
          business-day convention.
        content:
          application/json-patch+json:
            schema:
              $ref: '#/components/schemas/ApiAdjustBusinessDayRequest'
          application/json:
            schema:
              $ref: '#/components/schemas/ApiAdjustBusinessDayRequest'
          text/json:
            schema:
              $ref: '#/components/schemas/ApiAdjustBusinessDayRequest'
          application/*+json:
            schema:
              $ref: '#/components/schemas/ApiAdjustBusinessDayRequest'
      responses:
        '200':
          description: Returns the adjusted date as a UTC date/time value.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiAdjustBusinessDayResponse'
        '400':
          description: BadRequest
        '401':
          description: Unauthorized
        '403':
          description: Forbidden
      security:
        - oauth2: []
        - apikey: []
components:
  schemas:
    ApiAdjustBusinessDayRequest:
      required:
        - $type
      type: object
      properties:
        calendar:
          $ref: '#/components/schemas/Calendar'
        date:
          type: string
          description: Calendar date to adjust.
          format: date-time
        bdc:
          enum:
            - actual
            - following
            - modified_following
            - preceding
            - modified_preceding
          type: string
          description: Convention that determines how a non-business date is adjusted.
        $type:
          type: string
          enum:
            - >-
              Derivitec.Web.Core.MarketData.ApiAdjustBusinessDayRequest,
              Derivitec.Web.Core
      additionalProperties: false
      description: >-
        Selects a calendar, date, and business-day convention for date
        adjustment.
    ApiAdjustBusinessDayResponse:
      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
        date:
          type: string
          description: Adjusted UTC date and time.
          format: date-time
        $type:
          type: string
          enum:
            - >-
              Derivitec.Web.Core.MarketData.ApiAdjustBusinessDayResponse,
              Derivitec.Web.Core
      additionalProperties: false
      description: >-
        Returns the UTC date and time produced by the requested business-day
        convention.
    Calendar:
      description: Named business-day calendar with holiday dates and weekend treatment.
      discriminator:
        propertyName: $type
        mapping:
          Derivitec.Web.Core.StaticData.Calendar, Derivitec.Web.Core: '#/components/schemas/CalendarMintlifyShape'
          Derivitec.Web.Core.StaticData.CalendarIntersection, Derivitec.Web.Core: '#/components/schemas/CalendarIntersection'
          Derivitec.Web.Core.StaticData.CalendarUnion, Derivitec.Web.Core: '#/components/schemas/CalendarUnion'
      oneOf:
        - $ref: '#/components/schemas/CalendarMintlifyShape'
        - $ref: '#/components/schemas/CalendarIntersection'
        - $ref: '#/components/schemas/CalendarUnion'
    CalendarMintlifyShape:
      required:
        - $type
      type: object
      properties:
        holidays:
          type: array
          items:
            type: string
            format: date-time
          description: Dates treated as holidays by the calendar.
          nullable: true
        include_weekends:
          type: boolean
          description: >-
            Whether weekend dates are included in the calendar's
            non-business-day set.
        name:
          type: string
          description: Name of the business-day calendar.
          nullable: true
        $type:
          type: string
          enum:
            - Derivitec.Web.Core.StaticData.Calendar, Derivitec.Web.Core
      additionalProperties: false
      description: Named business-day calendar with holiday dates and weekend treatment.
    CalendarIntersection:
      required:
        - $type
      type: object
      properties:
        holidays:
          type: array
          items:
            type: string
            format: date-time
          description: Dates treated as holidays by the calendar.
          nullable: true
        include_weekends:
          type: boolean
          description: >-
            Whether weekend dates are included in the calendar's
            non-business-day set.
        name:
          type: string
          description: Name of the business-day calendar.
          nullable: true
        calendars:
          type: array
          items:
            $ref: '#/components/schemas/Calendar'
          description: Gets or sets the list of underlying calendars in the intersection.
          nullable: true
        $type:
          type: string
          enum:
            - >-
              Derivitec.Web.Core.StaticData.CalendarIntersection,
              Derivitec.Web.Core
      additionalProperties: false
      description: The calendar intersection.
    CalendarUnion:
      required:
        - $type
      type: object
      properties:
        holidays:
          type: array
          items:
            type: string
            format: date-time
          description: Dates treated as holidays by the calendar.
          nullable: true
        include_weekends:
          type: boolean
          description: >-
            Whether weekend dates are included in the calendar's
            non-business-day set.
        name:
          type: string
          description: Name of the business-day calendar.
          nullable: true
        calendars:
          type: array
          items:
            $ref: '#/components/schemas/Calendar'
          description: Gets or sets the list of underlying calendars in the union.
          nullable: true
        $type:
          type: string
          enum:
            - Derivitec.Web.Core.StaticData.CalendarUnion, Derivitec.Web.Core
      additionalProperties: false
      description: The calendar union.
  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

````