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

# Add Version From Existing File

> Create a new AssetVersion record in the database that points to a file already present in FileService.



## OpenAPI

````yaml docs/avxcelerate/assets-manager-rest-api/scenario-manager.aws-preprod-api-asset-manager-v1.json POST /assets/{asset_id}/versions-from-existing-file
openapi: 3.1.0
info:
  title: Assets Manager
  summary: Service to manage assets for the simulations
  version: 0.1.0
servers:
  - url: https://{host}/api/assets-manager/v1
    variables:
      host:
        default: api.example.com
        description: Host the API is served from
security: []
paths:
  /assets/{asset_id}/versions-from-existing-file:
    post:
      tags:
        - assets
      summary: Add Version From Existing File
      description: >-
        Create a new AssetVersion record in the database that points to a file
        already present in FileService.
      operationId: assets-add_version_from_existing_file
      parameters:
        - name: asset_id
          in: path
          required: true
          schema:
            type: string
            title: Asset Id
        - name: file_format
          in: query
          required: true
          schema:
            type: string
            title: File format
            description: The file format of the asset
          description: The file format of the asset
        - name: file_url
          in: query
          required: true
          schema:
            type: string
            title: File URL
            description: >-
              The internal URL pointing to an existing file that has not been
              registered yet with any other asset version.
          description: >-
            The internal URL pointing to an existing file that has not been
            registered yet with any other asset version.
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AssetVersionRead'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    AssetVersionRead:
      properties:
        asset:
          type: string
          title: Asset
        asset_url:
          type: string
          title: Asset Url
        version:
          type: integer
          title: Version
        user:
          type: string
          title: User
        attributes:
          additionalProperties:
            $ref: '#/components/schemas/JsonValue'
          type: object
          title: Attributes
          default: {}
        created_at:
          type: string
          format: date-time
          title: Created At
        checksum:
          type: string
          title: Checksum
      type: object
      required:
        - asset
        - asset_url
        - version
        - user
        - created_at
        - checksum
      title: AssetVersionRead
      description: Read class for asset version definition.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    JsonValue: {}
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````