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

# Create a new link

> Create a new link for the authenticated workspace.



## OpenAPI

````yaml POST /links/new/{workspace}
openapi: 3.1.0
info:
  title: Reqlick API
  description: >-
    REST API for Reqlick — link shortening, QR codes, file-to-link, custom
    domains and analytics.


    Authenticate with a workspace API key (`Authorization: Bearer rqk_...`),
    created under Settings → API Keys.


    A key is scoped to the single workspace it was created in. Using it against
    a different workspace returns 403, even when the owning user is a member of
    both.


    API access requires a paid plan.
  version: 3.0.0
  contact:
    name: Reqlick Support
    email: support@reqlick.com
servers:
  - url: https://api.reqlick.com
security:
  - bearerAuth: []
tags:
  - name: Links
  - name: QR Codes
  - name: Documents
  - name: Domains
  - name: Workspaces
  - name: Users
  - name: Subscriptions
paths:
  /links/new/{workspace}:
    post:
      tags:
        - Links
      summary: Create a link
      operationId: createLink
      parameters:
        - name: workspace
          in: path
          required: true
          description: Workspace slug.
          schema:
            type: string
        - name: subscriptionId
          in: query
          required: true
          description: >-
            Subscription ID that owns the workspace. Available from `GET
            /subscriptions`.
          schema:
            type: string
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                url:
                  type: string
                  description: Destination URL.
                domain:
                  type: string
                  default: rqk.sh
                key:
                  type: string
                  description: Custom short key. Generated when omitted.
                title:
                  type: string
                description:
                  type: string
                image:
                  type: string
                file:
                  type: string
                  format: binary
                  description: Social card image.
                expiresAt:
                  type: string
                  format: date-time
                password:
                  type: string
                ios:
                  type: string
                android:
                  type: string
                utm_source:
                  type: string
                utm_medium:
                  type: string
                utm_campaign:
                  type: string
                utm_term:
                  type: string
                utm_content:
                  type: string
              required:
                - url
      responses:
        '200':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LinkCreated'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: No access to this workspace, or a plan limit has been reached
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          $ref: '#/components/responses/ServerError'
components:
  schemas:
    LinkCreated:
      type: object
      properties:
        link_id:
          type: string
        link_url:
          type: string
          examples:
            - rqk.sh/k5zvrg
    Error:
      type: object
      properties:
        error:
          type: string
      required:
        - error
  responses:
    BadRequest:
      description: Invalid request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: >-
        Missing, malformed or revoked API key — or the plan no longer includes
        API access
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    ServerError:
      description: Server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Workspace API key, prefixed `rqk_`.

````