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

# Get asset by ID

> Retrieves a single asset by its ID.



## OpenAPI

````yaml /api-reference/openapi.json get /api/assets/{id}
openapi: 3.0.0
info:
  title: Open Attack Surface Management
  description: Open-source platform for cybersecurity Attack Surface Management (ASM)
  version: '1.0'
  contact: {}
servers:
  - url: https://{baseUrl}/api/v1
    variables:
      baseUrl:
        default: localhost:3000
        description: API server hostname with port (e.g. localhost:3000, api.example.com)
security: []
tags: []
externalDocs:
  description: Authentication Docs
  url: auth/docs
paths:
  /api/assets/{id}:
    get:
      tags:
        - Assets
      summary: Get asset by ID
      description: Retrieves a single asset by its ID.
      operationId: AssetsController_getAssetById
      parameters:
        - name: id
          required: true
          in: path
          schema:
            type: string
        - name: X-Workspace-Id
          in: header
          description: Workspace ID
          schema:
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetAssetsResponseDto'
                allOf:
                  - $ref: '#/components/schemas/AppResponseSerialization'
components:
  schemas:
    GetAssetsResponseDto:
      type: object
      properties:
        id:
          type: string
        value:
          type: string
        targetId:
          type: string
        isPrimary:
          type: boolean
        createdAt:
          format: date-time
          type: string
        updatedAt:
          format: date-time
          type: string
        tags:
          type: array
          items:
            $ref: '#/components/schemas/AssetTag'
        dnsRecords:
          type: object
        ipAddresses:
          type: array
          items:
            type: string
        httpResponses:
          $ref: '#/components/schemas/HttpResponseDTO'
        port:
          type: number
        isEnabled:
          type: boolean
        screenshotPath:
          type: object
      required:
        - id
        - value
        - targetId
        - createdAt
        - updatedAt
        - tags
        - ipAddresses
        - isEnabled
    AssetTag:
      type: object
      properties:
        id:
          type: string
        createdAt:
          format: date-time
          type: string
        updatedAt:
          format: date-time
          type: string
        tag:
          type: string
        tool:
          $ref: '#/components/schemas/PickToolIdName'
      required:
        - id
        - createdAt
        - updatedAt
        - tag
        - tool
    HttpResponseDTO:
      type: object
      properties:
        id:
          type: string
        createdAt:
          format: date-time
          type: string
        updatedAt:
          format: date-time
          type: string
        timestamp:
          format: date-time
          type: string
        tls:
          $ref: '#/components/schemas/TlsInfo'
        port:
          type: string
        url:
          type: string
        input:
          type: string
        title:
          type: string
        scheme:
          type: string
        webserver:
          type: string
        body:
          type: string
        content_type:
          type: string
        method:
          type: string
        host:
          type: string
        path:
          type: string
        favicon:
          type: string
        favicon_md5:
          type: string
        favicon_url:
          type: string
        header:
          type: object
        raw_header:
          type: string
        request:
          type: string
        time:
          type: string
        a:
          type: array
          items:
            type: string
        tech:
          type: array
          items:
            type: string
        words:
          type: number
        lines:
          type: number
        status_code:
          type: number
        content_length:
          type: number
        failed:
          type: boolean
        knowledgebase:
          $ref: '#/components/schemas/KnowledgebaseInfo'
        resolvers:
          type: array
          items:
            type: string
        chain_status_codes:
          type: array
          items:
            type: string
        assetServiceId:
          type: string
        jobHistoryId:
          type: string
        techList:
          type: array
          items:
            type: string
      required:
        - id
        - createdAt
        - updatedAt
        - timestamp
        - tls
        - port
        - url
        - input
        - title
        - scheme
        - webserver
        - body
        - content_type
        - method
        - host
        - path
        - favicon
        - favicon_md5
        - favicon_url
        - header
        - raw_header
        - request
        - time
        - a
        - tech
        - words
        - lines
        - status_code
        - content_length
        - failed
        - knowledgebase
        - resolvers
        - chain_status_codes
        - assetServiceId
        - jobHistoryId
        - techList
    PickToolIdName:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
      required:
        - id
        - name
    TlsInfo:
      type: object
      properties:
        host:
          type: string
        port:
          type: string
        probe_status:
          type: boolean
        tls_version:
          type: string
        cipher:
          type: string
        not_before:
          type: string
        not_after:
          type: string
        subject_dn:
          type: string
        subject_cn:
          type: string
        subject_an:
          type: array
          items:
            type: string
        serial:
          type: string
        issuer_dn:
          type: string
        issuer_cn:
          type: string
        issuer_org:
          type: array
          items:
            type: string
        fingerprint_hash:
          type: object
        wildcard_certificate:
          type: boolean
        tls_connection:
          type: string
        sni:
          type: string
      required:
        - host
        - port
        - probe_status
        - tls_version
        - cipher
        - not_before
        - not_after
        - subject_dn
        - subject_cn
        - subject_an
        - serial
        - issuer_dn
        - issuer_cn
        - issuer_org
        - fingerprint_hash
        - wildcard_certificate
        - tls_connection
        - sni
    KnowledgebaseInfo:
      type: object
      properties:
        PageType:
          type: string
        pHash:
          type: number
      required:
        - PageType
        - pHash

````