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

# Create Link

> Creates a new link



## OpenAPI

````yaml Post /organizations/{organizationId}/domains/{domainsId}/links
openapi: 3.0.1
info:
  title: PROlinks
  description: >-
    A sample API that uses a plant store as an example to demonstrate features
    in the OpenAPI specification
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://prolinks.pro/api/v1
security:
  - bearerAuth: []
paths:
  /organizations/{organizationId}/domains/{domainsId}/links:
    post:
      description: Creates a new link
      parameters:
        - name: organizationId
          in: path
          description: ID of the organization
          required: true
          schema:
            type: string
            example: 1
        - name: domainId
          in: path
          description: ID of the domain
          required: true
          schema:
            type: string
      requestBody:
        description: Link to add
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateLink'
      responses:
        '200':
          description: link response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Link'
components:
  schemas:
    CreateLink:
      required:
        - url
      type: object
      properties:
        url:
          description: The link url
          type: string
        slug:
          description: The link slug
          type: string
        description:
          description: The link description
          type: string
        campaign_source_id:
          description: The link campaign source
          type: integer
        campaign_medium_id:
          description: The link campaign medium
          type: integer
        campaign_name_id:
          description: The link campaign name
          type: integer
    Link:
      type: object
      properties:
        id:
          description: The Link id
          type: integer
        type:
          description: Link
          type: string
        attributes:
          type: object
          properties:
            organization:
              description: The organization that the link belongs to
              type: string
            domain:
              description: The domain that the link belongs to
              type: string
            slug:
              description: The link slug
              type: string
            url:
              description: The link url
              type: string
            description:
              description: The link description
              type: string
            campaign_source:
              description: The link campaign source
              type: string
            campaign_medium:
              description: The link campaign medium
              type: string
            campaign_name:
              description: The link campaign name
              type: string
            is_active:
              description: If the link is active or not
              type: integer
            final_url:
              description: The final url to redirect
              type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````