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

# Track Conversion

> The tracking API allows you to track conversions for any affiliate.



## OpenAPI

````yaml POST /v2/tracking/conversion
openapi: 3.1.0
info:
  title: Reditus API - Tracking V2
  description: API specification for tracking conversions in Reditus (Version 2).
  version: 1.0.0
servers:
  - url: https://api.getreditus.com/api
security: []
paths:
  /v2/tracking/conversion:
    post:
      summary: Referral Conversion
      description: The tracking API allows you to track conversions for any affiliate.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TrackingV2Request'
      responses:
        '201':
          description: Successful conversion
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TrackingV2Response'
        '400':
          description: Invalid affiliate slug
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    default: Invalid request
        '409':
          description: Referral already exists
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    default: Referral already exists
      security:
        - BearerAuth: []
components:
  schemas:
    TrackingV2Request:
      type: object
      properties:
        affiliate_slug:
          type: string
          description: >-
            URL parameter of the affiliate (i.e. https://company.com?red=john ->
            john). You can use a competitor slug as well.
        advocate_slug:
          type: string
          description: >-
            **required** if affiliate_slug is not set - URL parameter of the
            advocate (i.e. https://company.com?refby=jwe512 -> jwe512).
        email:
          type: string
          description: '**required** if uid is not set - Email of the referral'
        uid:
          type: string
          description: >-
            **required** if email is not set - Your internal ID of the
            user/customer
        gr_id:
          type: string
          description: >-
            Cookie set by the tracking script in the referral's browser. Used to
            match the exact click that converted.
      required:
        - affiliate_slug
    TrackingV2Response:
      type: object
      properties:
        data:
          type: object
          properties:
            id:
              type: string
            type:
              type: string
            attributes:
              type: object
              properties:
                email:
                  type: string
                uid:
                  type: string
                state:
                  type: string
                state_set_at:
                  type: integer
                created_at:
                  type: integer
                updated_at:
                  type: integer
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````