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

# Preview links

> Shows what recalculating links would look like without saving changes.



## OpenAPI

````yaml /api-reference/openapi.yml post /links/preview/{username}/{namespace}/{datasetName}
openapi: 3.0.3
info:
  title: DataLinks
  version: 2.2.3
servers:
  - url: https://api.datalinks.com/api/v1
    description: production server
security:
  - bearerAuth: []
  - openId:
      - implicit
paths:
  /links/preview/{username}/{namespace}/{datasetName}:
    post:
      tags:
        - links
      summary: Preview links
      description: Shows what recalculating links would look like without saving changes.
      operationId: previewLinks
      parameters:
        - name: namespace
          in: path
          description: Namespace for the dataset.
          required: true
          schema:
            type: string
          example: cinematography
        - name: datasetName
          in: path
          description: Name of the dataset.
          required: true
          schema:
            type: string
          examples:
            movies:
              summary: Movies
              value: movies
            actors:
              summary: Actors
              value: actors
        - name: username
          in: path
          description: The username associated with the request.
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/IngestLinksRequest'
        required: true
      responses:
        '200':
          description: Returns the preview link results.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IngestLinksResponse'
components:
  schemas:
    IngestLinksRequest:
      required:
        - data
      type: object
      properties:
        data:
          $ref: '#/components/schemas/DataArray'
        link:
          $ref: '#/components/schemas/IngestLink'
      example:
        data:
          - name: Braveheart
            year: '1995'
            budget: '72000000'
            director: Mel Gibson
          - name: Argo
            year: '2012'
            budget: '44500000'
            director: Ben Affleck
        link:
          ExactMatch: null
          GeoMatch: null
    IngestLinksResponse:
      type: array
      items:
        $ref: '#/components/schemas/ApiLink'
    DataArray:
      type: array
      description: Array of ontology data objects retrieved from queries.
      items:
        type: object
        additionalProperties: true
    IngestLink:
      type: object
      properties:
        ExactMatch:
          nullable: true
          anyOf:
            - $ref: '#/components/schemas/ExactMatchConfig'
            - $ref: '#/components/schemas/ResolutionParameters'
        GeoMatch:
          nullable: true
          anyOf:
            - $ref: '#/components/schemas/GeoMatchConfig'
            - $ref: '#/components/schemas/ResolutionParameters'
    ApiLink:
      required:
        - destination
        - hits
        - matchType
        - origin
      type: object
      properties:
        destination:
          type: string
          example: ri.user.examples.companies.other_addresses
        hits:
          type: integer
          format: int64
          example: 5
        matchType:
          type: string
          example: ExactMatch
        origin:
          type: string
          example: ri.user.examples.companies.nationalities
      example:
        destination: ri.user.examples.actor.name
        hits: 6
        matchType: ExactMatch
        origin: ri.user.examples.movies.director
    ExactMatchConfig:
      type: object
      properties:
        minDistinct:
          type: number
        minVariation:
          type: number
      nullable: true
    ResolutionParameters:
      type: object
      properties:
        bidirectional:
          type: boolean
        targetColumns:
          type: array
          items:
            type: string
        ignorePrivateColumns:
          type: boolean
    GeoMatchConfig:
      type: object
      properties:
        distance:
          type: number
        distanceUnit:
          type: string
      nullable: true
  securitySchemes:
    bearerAuth:
      type: http
      description: >
        Use a Bearer token for authentication. Submit the token using the
        `Authorization`

        header: `Authorization: Bearer <token>`.
      scheme: bearer
    openId:
      type: oauth2
      flows:
        implicit:
          authorizationUrl: >-
            https://login.datalinks.com/realms/datalinks-realm/protocol/openid-connect/auth
          scopes:
            openid: openid

````