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

# Generate custom affiliate link

> Generates a custom tracking link for an affiliate membership using a specific code.

**Usage:** Allows affiliates to create personalized links that can track their referral traffic and conversions.



## OpenAPI

````yaml post /affiliates/links
openapi: 3.0.0
info:
  title: Blink API
  description: Comprehensive API documentation for Blink.
  version: 1.0.0
servers:
  - url: https://api.blink.store/v1
security: []
paths:
  /affiliates/links:
    post:
      tags:
        - Affiliates
      summary: Generate custom affiliate link
      description: >-
        Generates a custom tracking link for an affiliate membership using a
        specific code.


        **Usage:** Allows affiliates to create personalized links that can track
        their referral traffic and conversions.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                membership_id:
                  type: string
                code:
                  type: string
              required:
                - membership_id
                - code
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                      code:
                        type: string
        '400':
          description: Bad Request
        '401':
          description: Unauthorized
        '404':
          description: Not Found

````