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

# Get Scan

> Fetches complete scan results for a specific scan ID. 
    Returns scan metadata immediately; full results (certificate, screenshot, etc.) are available once status is DONE. 
    Scans in PENDING or RUNNING states return metadata only.



## OpenAPI

````yaml GET /v1/scan/{scan_id}
openapi: 3.1.0
info:
  title: urlDNA API
  description: >-
    urlDNA API documentation. This API allows you to scan, analyze, and retrieve
    insights about URLs, helping to detect potential threats such as phishing,
    malware, and scams.
  version: 1.0.0
servers:
  - url: https://api.urldna.io
security: []
paths:
  /v1/scan/{scan_id}:
    get:
      tags:
        - Scan
      summary: Get Scan
      description: |-
        Fetches complete scan results for a specific scan ID. 
            Returns scan metadata immediately; full results (certificate, screenshot, etc.) are available once status is DONE. 
            Scans in PENDING or RUNNING states return metadata only.
      operationId: get_scan_v1_scan__scan_id__get
      parameters:
        - name: scan_id
          in: path
          required: true
          schema:
            type: string
            title: Scan Id
        - name: authorization
          in: header
          required: true
          schema:
            type: string
            title: Authorization
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScanResult'
        '401':
          description: 'Unauthorized: API Key is missing or invalid.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
        '404':
          description: 'Not Found: Object not found.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
        '405':
          description: >-
            Method Not Allowed: The requested HTTP method is not supported for
            this endpoint.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
        '422':
          description: 'Unprocessable Entity: The request body or parameters are invalid.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
        '429':
          description: 'Too Many Requests: Rate limit exceeded.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
        '500':
          description: 'Internal Server Error: An unexpected error occurred.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
components:
  schemas:
    ScanResult:
      properties:
        certificate:
          anyOf:
            - $ref: '#/components/schemas/Certificate'
            - type: 'null'
          description: SSL/TLS certificate information for the scanned domain.
        console_messages:
          items:
            $ref: '#/components/schemas/ConsoleMessage'
          type: array
          title: Console Messages
          description: JavaScript console messages captured during page rendering.
          default: []
        cookies:
          items:
            $ref: '#/components/schemas/Cookie'
          type: array
          title: Cookies
          description: HTTP cookies set by the page and its resources.
          default: []
        dom:
          anyOf:
            - type: string
            - type: 'null'
          title: Dom
          description: Complete HTML Document Object Model (DOM) of the rendered page.
        favicon:
          anyOf:
            - $ref: '#/components/schemas/Favicon'
            - type: 'null'
          description: Favicon metadata and perceptual hash for similarity matching.
        http_transactions:
          items:
            $ref: '#/components/schemas/HttpTransaction'
          type: array
          title: Http Transactions
          description: All HTTP requests and responses observed during page load.
          default: []
        ip_address:
          anyOf:
            - $ref: '#/components/schemas/IpAddress'
            - type: 'null'
          description: IP address and geolocation details of the hosting server.
        classification:
          anyOf:
            - $ref: '#/components/schemas/Classification'
            - type: 'null'
          description: Classification assessment indicating potential malicious activity.
        page:
          anyOf:
            - $ref: '#/components/schemas/Page'
            - type: 'null'
          description: Extracted page content and metadata.
        scan:
          $ref: '#/components/schemas/Scan'
          description: Scan configuration and processing metadata.
        scan_whois:
          anyOf:
            - $ref: '#/components/schemas/ScanWhois'
            - type: 'null'
          description: Domain registration information from WHOIS records.
        screenshot:
          anyOf:
            - $ref: '#/components/schemas/Screenshot'
            - type: 'null'
          description: Visual screenshot of the rendered webpage.
        redirect_chains:
          items:
            $ref: '#/components/schemas/RedirectChain'
          type: array
          title: Redirect Chains
          description: Complete redirect chain from submitted URL to final destination.
          default: []
        technologies:
          items:
            $ref: '#/components/schemas/Technology'
          type: array
          title: Technologies
          description: Web technologies detected on the page.
          default: []
      type: object
      required:
        - scan
      title: ScanResult
    APIError:
      properties:
        detail:
          type: string
          title: Detail
          example: Error description message
      type: object
      required:
        - detail
      title: APIError
    Certificate:
      properties:
        authority_info_access:
          anyOf:
            - type: string
            - type: 'null'
          title: Authority Info Access
          description: >-
            URLs for accessing Certificate Authority services (OCSP responder
            and CA issuer locations).
        authority_key_identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Authority Key Identifier
          description: >-
            Unique identifier for the issuing CA's public key, used for
            certificate chain validation.
        basic_constraints:
          anyOf:
            - type: string
            - type: 'null'
          title: Basic Constraints
          description: Indicates CA status and maximum certificate chain depth allowed.
        certificate_policies:
          anyOf:
            - type: string
            - type: 'null'
          title: Certificate Policies
          description: >-
            Certificate usage policies with references to policy documentation
            URLs.
        ct_precert_scts:
          anyOf:
            - type: string
            - type: 'null'
          title: Ct Precert Scts
          description: >-
            Signed Certificate Timestamps (SCTs) from Certificate Transparency
            logs for public audit trail.
        extended_key_usage:
          anyOf:
            - type: string
            - type: 'null'
          title: Extended Key Usage
          description: >-
            Permitted uses for the certificate (e.g., server authentication,
            code signing).
        issuer:
          type: string
          title: Issuer
          description: >-
            Distinguished Name (DN) of the Certificate Authority that issued
            this certificate.
        key_usage:
          anyOf:
            - type: string
            - type: 'null'
          title: Key Usage
          description: >-
            Cryptographic operations permitted for this certificate's key pair
            (e.g., digital signature, key encipherment).
        not_after:
          type: string
          title: Not After
          description: >-
            Certificate expiration timestamp after which the certificate is no
            longer valid.
        not_before:
          type: string
          title: Not Before
          description: Certificate validity start timestamp.
        serial_number:
          type: string
          title: Serial Number
          description: Unique serial number assigned by the issuing CA.
        subject:
          type: string
          title: Subject
          description: >-
            Distinguished Name (DN) of the entity for which the certificate was
            issued.
        subject_key_identifier:
          anyOf:
            - type: string
            - type: 'null'
          title: Subject Key Identifier
          description: >-
            Unique identifier for the certificate's public key, facilitating key
            management.
        version:
          type: integer
          title: Version
          description: X.509 certificate version number (typically 1, 2, or 3).
      type: object
      required:
        - issuer
        - not_after
        - not_before
        - serial_number
        - subject
        - version
      title: Certificate
    ConsoleMessage:
      properties:
        text:
          type: string
          title: Text
          description: Complete message text logged to the console.
        type:
          type: string
          title: Type
          description: Console message severity level (log, error, warn, info).
      type: object
      required:
        - text
        - type
      title: ConsoleMessage
    Cookie:
      properties:
        domain:
          type: string
          title: Domain
          description: Domain scope for which the cookie is valid.
        expiry:
          anyOf:
            - type: string
            - type: 'null'
          title: Expiry
          description: Cookie expiration timestamp in UTC format.
        http_only:
          type: boolean
          title: Http Only
          description: >-
            When true, cookie is inaccessible to JavaScript, mitigating XSS
            attacks.
        name:
          type: string
          title: Name
          description: Cookie identifier name.
        path:
          type: string
          title: Path
          description: URL path scope within the domain where the cookie applies.
        secure:
          type: boolean
          title: Secure
          description: When true, cookie is transmitted only over HTTPS connections.
        value:
          type: string
          title: Value
          description: Cookie value data.
      type: object
      required:
        - domain
        - http_only
        - name
        - path
        - secure
        - value
      title: Cookie
    Favicon:
      properties:
        blob_uri:
          anyOf:
            - type: string
            - type: 'null'
          title: Blob Uri
          description: Temporary URI for accessing the favicon image (30-minute TTL).
        format:
          type: string
          title: Format
          description: Detected image format (e.g., ico, png, svg).
        height:
          type: integer
          title: Height
          description: Favicon height in pixels.
        mimetype:
          type: string
          title: Mimetype
          description: MIME type of the favicon (e.g., image/x-icon, image/png).
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Favicon filename if available.
        phash:
          type: string
          title: Phash
          description: >-
            Perceptual hash (pHash) for identifying visually similar favicons
            across different scans.
        url:
          type: string
          title: Url
          description: Complete URL of the favicon resource.
        width:
          type: integer
          title: Width
          description: Favicon width in pixels.
      type: object
      required:
        - format
        - height
        - mimetype
        - phash
        - url
        - width
      title: Favicon
    HttpTransaction:
      properties:
        content_type:
          anyOf:
            - type: string
            - type: 'null'
          title: Content Type
          description: >-
            Content-Type header value from the HTTP response (e.g., text/html,
            application/json).
        ip:
          type: string
          title: Ip
          description: IP address of the server that responded to the request.
        method:
          type: string
          title: Method
          description: HTTP method used for the request (GET, POST, HEAD, etc.).
        mimetypes:
          anyOf:
            - type: string
            - type: 'null'
          title: Mimetypes
          description: MIME types associated with the response content.
        size:
          type: integer
          title: Size
          description: Response body size in bytes.
        status_code:
          type: integer
          title: Status Code
          description: >-
            HTTP status code returned (e.g., 200 for OK, 404 for Not Found, 301
            for redirect).
        url:
          type: string
          title: Url
          description: Complete URL of the requested resource.
      type: object
      required:
        - ip
        - method
        - size
        - status_code
        - url
      title: HttpTransaction
    IpAddress:
      properties:
        asn:
          anyOf:
            - type: string
            - type: 'null'
          title: Asn
          description: Autonomous System Number (ASN) identifying the network operator.
        city:
          anyOf:
            - type: string
            - type: 'null'
          title: City
          description: City location of the IP address.
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: Country where the IP address is registered.
        country_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Country Code
          description: Two-letter ISO 3166-1 alpha-2 country code.
        ip:
          type: string
          title: Ip
          description: IP address being analyzed.
        isp:
          anyOf:
            - type: string
            - type: 'null'
          title: Isp
          description: Internet Service Provider managing this IP address.
        latitude:
          anyOf:
            - type: number
            - type: 'null'
          title: Latitude
          description: Approximate latitude coordinate of the IP location.
        longitude:
          anyOf:
            - type: number
            - type: 'null'
          title: Longitude
          description: Approximate longitude coordinate of the IP location.
        org:
          anyOf:
            - type: string
            - type: 'null'
          title: Org
          description: Organization that owns or manages the IP address.
        region:
          anyOf:
            - type: string
            - type: 'null'
          title: Region
          description: State or region where the IP address is located.
        timezone_gmt:
          anyOf:
            - type: string
            - type: 'null'
          title: Timezone Gmt
          description: Time zone offset in GMT format.
        type:
          anyOf:
            - type: string
            - type: 'null'
          title: Type
          description: >-
            IP address classification (e.g., residential, corporate, cloud
            provider, hosting).
      type: object
      required:
        - ip
      title: IpAddress
    Classification:
      properties:
        verdict:
          type: string
          title: Verdict
          description: >-
            The final classification verdict. SAFE indicates that no threats
            were detected, while MALICIOUS indicates that the AI engine
            identified potentially harmful content.
      type: object
      required:
        - verdict
      title: Classification
    Page:
      properties:
        headers:
          additionalProperties:
            type: string
          type: object
          title: Headers
          description: HTTP response headers returned by the server.
        meta_tags:
          additionalProperties:
            type: string
          type: object
          title: Meta Tags
          description: HTML meta tags extracted from the document head section.
        outgoing_links:
          items:
            type: string
          type: array
          title: Outgoing Links
          description: >-
            Array of URLs linked from the scanned page, useful for mapping site
            structure.
          default: []
        ssdeep:
          anyOf:
            - type: string
            - type: 'null'
          title: Ssdeep
          description: SSDEEP fuzzy hash for detecting similar or modified page content.
        text:
          anyOf:
            - type: string
            - type: 'null'
          title: Text
          description: >-
            Extracted plaintext content from the webpage, with HTML markup
            removed.
        title:
          anyOf:
            - type: string
            - type: 'null'
          title: Title
          description: Page title extracted from the HTML <title> tag.
      type: object
      required:
        - headers
        - meta_tags
      title: Page
    Scan:
      properties:
        id:
          type: string
          title: Id
          description: Unique auto-generated scan identifier.
        submitted_url:
          type: string
          title: Submitted Url
          description: Original URL submitted for scanning.
        domain:
          anyOf:
            - type: string
            - type: 'null'
          title: Domain
          description: Extracted domain from the submitted URL.
        target_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Target Url
          description: Final destination URL after following all redirects.
        protocol:
          anyOf:
            - type: string
            - type: 'null'
          title: Protocol
          description: Protocol used (HTTP or HTTPS).
        device:
          $ref: '#/components/schemas/DeviceEnum'
          description: Device type used for the scan simulation (DESKTOP or MOBILE).
        user_agent:
          anyOf:
            - type: string
            - type: 'null'
          title: User Agent
          description: User agent string used to simulate the browser environment.
        http_referer:
          anyOf:
            - type: string
            - type: 'null'
          title: Http Referer
          description: >-
            HTTP Referer header value indicating the originating page for the
            request.
        nsfw:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Nsfw
          description: >-
            Indicates whether the page contains Not Safe For Work (NSFW) content
            such as nudity or adult material.
          default: false
        scanned_from:
          type: string
          title: Scanned From
          description: >-
            Country code from which the scan was initiated. Available for
            PREMIUM users only.
        origin:
          $ref: '#/components/schemas/OriginEnum'
          description: >-
            Indicates whether the scan was submitted programmatically via API or
            manually by a user.
        width:
          type: integer
          title: Width
          description: Viewport width in pixels used during the scan.
        height:
          type: integer
          title: Height
          description: Viewport height in pixels used during the scan.
        private_scan:
          type: boolean
          title: Private Scan
          description: When true, scan results are only accessible to the submitting user.
        status:
          $ref: '#/components/schemas/StatusEnum'
          description: >-
            Current scan status. PENDING and RUNNING are transient states; DONE
            and ERROR are terminal states.
        submitted_date:
          type: string
          format: date-time
          title: Submitted Date
          description: ISO 8601 timestamp when the scan was submitted.
        submitter_tags:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Submitter Tags
          description: User-defined tags for organizing and categorizing scans.
        error_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Error Code
          description: >-
            Error code when scan status is ERROR, indicating the reason for
            failure.
      type: object
      required:
        - id
        - submitted_url
        - device
        - user_agent
        - scanned_from
        - origin
        - width
        - height
        - private_scan
        - status
        - submitted_date
      title: Scan
    ScanWhois:
      properties:
        address:
          anyOf:
            - type: string
            - type: 'null'
          title: Address
          description: Registrant's physical address from WHOIS record.
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: Country of domain registration.
        creation_date:
          anyOf:
            - type: string
            - type: 'null'
          title: Creation Date
          description: Date when the domain was initially registered.
        domain_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Domain Name
          description: Fully qualified domain name.
        expiration_date:
          anyOf:
            - type: string
            - type: 'null'
          title: Expiration Date
          description: Date when the domain registration expires.
        name:
          anyOf:
            - type: string
            - type: 'null'
          title: Name
          description: Registrant name from WHOIS record.
        org:
          anyOf:
            - type: string
            - type: 'null'
          title: Org
          description: Organization name of the domain owner.
        registrant_postal_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Registrant Postal Code
          description: Postal code associated with the registrant address.
        registrar:
          anyOf:
            - type: string
            - type: 'null'
          title: Registrar
          description: Domain registrar company through which the domain was registered.
        state:
          anyOf:
            - type: string
            - type: 'null'
          title: State
          description: State or province of domain registration.
        updated_date:
          anyOf:
            - type: string
            - type: 'null'
          title: Updated Date
          description: Date when the WHOIS record was last modified.
      type: object
      title: ScanWhois
    Screenshot:
      properties:
        blob_uri:
          type: string
          title: Blob Uri
          description: Temporary URI for accessing the screenshot image (30-minute TTL).
        format:
          type: string
          title: Format
          description: Image file format (png or jpeg).
        height:
          type: integer
          title: Height
          description: Screenshot height in pixels.
        mimetype:
          type: string
          title: Mimetype
          description: MIME type of the screenshot image.
        phash:
          type: string
          title: Phash
          description: Perceptual hash (pHash) for detecting visually similar pages.
        width:
          type: integer
          title: Width
          description: Screenshot width in pixels.
      type: object
      required:
        - blob_uri
        - format
        - height
        - mimetype
        - phash
        - width
      title: Screenshot
    RedirectChain:
      properties:
        redirect_url:
          type: string
          title: Redirect Url
          description: Intermediate URL in the redirect chain.
        status:
          type: string
          title: Status
          description: HTTP status code for this redirect hop.
        elapsed_time:
          type: number
          title: Elapsed Time
          description: Time duration in milliseconds for this redirect hop.
      type: object
      required:
        - redirect_url
        - status
        - elapsed_time
      title: RedirectChain
    Technology:
      properties:
        category:
          type: string
          title: Category
          description: >-
            Technology classification (e.g., CMS, Analytics, JavaScript
            Framework, CDN).
        name:
          type: string
          title: Name
          description: Technology name (e.g., WordPress, Google Analytics, React).
        version:
          anyOf:
            - type: string
            - type: 'null'
          title: Version
          description: Detected version number if identifiable.
      type: object
      required:
        - category
        - name
      title: Technology
    DeviceEnum:
      type: string
      enum:
        - DESKTOP
        - MOBILE
      title: DeviceEnum
    OriginEnum:
      type: string
      enum:
        - USER
        - API
        - TELEGRAM
      title: OriginEnum
    StatusEnum:
      type: string
      enum:
        - PENDING
        - RUNNING
        - DONE
        - ERROR
        - PAGE_NOT_AVAILABLE
      title: StatusEnum

````