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

# Rank projects by handle

> Rank projects mentioned by one or more Twitter/X handles. Supports API key auth or x402 fallback.



## OpenAPI

````yaml /api-reference/openapi.json post /api/v1/content/top-projects-by-handle
openapi: 3.1.0
info:
  title: Kanarie API
  description: >-
    Crypto content search, project intelligence, mindshare, fundamentals, and
    wallet data APIs.
  version: 1.0.0
  license:
    name: Proprietary
    identifier: LicenseRef-Proprietary
servers:
  - url: https://api.kanarie.xyz
    description: Production
security:
  - bearerAuth: []
  - kanarieApiKey: []
tags:
  - name: Health
    description: Service health endpoints.
  - name: Content
    description: Search content and rank project or handle mentions.
  - name: Projects
    description: Search, filter, map, and analyze crypto projects.
  - name: Data
    description: Virality and fundamentals datasets.
  - name: Wallets
    description: Smart money and wallet PnL datasets.
paths:
  /api/v1/content/top-projects-by-handle:
    post:
      tags:
        - Content
      summary: Rank projects by handle
      description: >-
        Rank projects mentioned by one or more Twitter/X handles. Supports API
        key auth or x402 fallback.
      operationId: postTopProjectsByHandle
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TopProjectsByHandleRequest'
            examples:
              handles:
                value:
                  handles:
                    - inversebrah
                    - DefiIgnas
                  days_back: 30
                  limit: 20
                  included_attributes:
                    - market_data
                    - recent_posts
      responses:
        '200':
          $ref: '#/components/responses/ProjectMentionsSuccess'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '402':
          $ref: '#/components/responses/PaymentRequired'
        '403':
          $ref: '#/components/responses/Forbidden'
        '429':
          $ref: '#/components/responses/RateLimited'
        '500':
          $ref: '#/components/responses/InternalError'
components:
  schemas:
    TopProjectsByHandleRequest:
      type: object
      required:
        - handles
      properties:
        handles:
          type: array
          minItems: 1
          maxItems: 50
          items:
            type: string
        days_back:
          type: integer
          minimum: 1
          maximum: 365
          default: 30
        limit:
          type: integer
          minimum: 1
          maximum: 100
          default: 50
        offset:
          type: integer
          minimum: 0
          maximum: 10000
          default: 0
        sort_by:
          type: string
          enum:
            - total_relevance
            - total_sentiment
            - post_count
            - avg_relevance
            - market_cap
          default: total_relevance
        included_attributes:
          type: array
          items:
            $ref: '#/components/schemas/SocialProjectAttribute'
        attribute_limit:
          type: integer
          default: 5
        include_retweets:
          type: boolean
          default: true
        min_relevance:
          type:
            - number
            - 'null'
    SocialProjectAttribute:
      type: string
      enum:
        - market_data
        - mindshare
        - project_info
        - token_details
        - recent_posts
        - technical_analysis
    GenericSuccessResponse:
      type: object
      required:
        - success
      properties:
        success:
          type: boolean
        error:
          type:
            - string
            - 'null'
        data:
          type:
            - object
            - array
            - 'null'
          additionalProperties: true
          items:
            $ref: '#/components/schemas/ObjectAny'
        analysis:
          $ref: '#/components/schemas/ObjectAny'
        results:
          type: array
          items:
            $ref: '#/components/schemas/ObjectAny'
        projects:
          type: array
          items:
            $ref: '#/components/schemas/ObjectAny'
        metadata:
          $ref: '#/components/schemas/ObjectAny'
      additionalProperties: true
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: string
        details:
          type: array
          items:
            type: string
        reason:
          type: string
      additionalProperties: true
    PaymentRequiredResponse:
      type: object
      required:
        - x402Version
        - error
        - accepts
      properties:
        x402Version:
          type: integer
          example: 2
        error:
          type: string
          example: Payment required
        accepts:
          type: array
          items:
            type: object
            additionalProperties: true
      additionalProperties: true
    RateLimitResponse:
      type: object
      required:
        - error
        - limit
        - plan
        - window
        - retryAfter
      properties:
        error:
          type: string
          example: Rate limit exceeded
        limit:
          type: integer
        plan:
          type: string
          enum:
            - free
            - casual
            - pro
            - enterprise
          example: casual
        window:
          type: string
          example: 15 minutes
        retryAfter:
          type: integer
          example: 900
    ObjectAny:
      type: object
      additionalProperties: true
  responses:
    ProjectMentionsSuccess:
      description: Ranked projects mentioned by the requested handles.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/GenericSuccessResponse'
          examples:
            success:
              value:
                success: true
                error: null
                data:
                  - project_id: 1
                    project_name: Jupiter
                    symbol: JUP
                    total_relevance: 0.95
                    post_count: 12
                metadata:
                  handles:
                    - inversebrah
                  total_results: 1
    BadRequest:
      description: The request body or query parameters failed validation.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            validation:
              value:
                error: Validation failed
                details:
                  - limit must be a number between 1 and 100
    Unauthorized:
      description: The API key header is missing.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            missing:
              value:
                error: >-
                  Missing API key. Expected Authorization: Bearer <api-key> or
                  x-kanarie-api-key: <api-key>.
    PaymentRequired:
      description: >-
        x402 payment is required when no API key is present, API-key auth fails
        client-side checks, or an API key exceeds plan limits on an x402-enabled
        endpoint.
      headers:
        X-Payment-Required:
          description: Encoded x402 payment requirements.
          schema:
            type: string
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/PaymentRequiredResponse'
    Forbidden:
      description: >-
        The API key is invalid, inactive, expired, or unauthorized for the
        request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            invalid:
              value:
                error: Invalid API key
    RateLimited:
      description: >-
        The API key exceeded a route limit on an API-key-only path. x402-enabled
        endpoints normally return payment requirements for over-limit requests.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/RateLimitResponse'
    InternalError:
      description: The API encountered an internal error while processing the request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            internal:
              value:
                error: Internal server error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: Kanarie API key
      description: >-
        Preferred Kanarie API key authentication using Authorization: Bearer
        <api-key>.
      x-default: YOUR_KANARIE_API_KEY
    kanarieApiKey:
      type: apiKey
      in: header
      name: x-kanarie-api-key
      description: Kanarie API key header for current clients.
      x-default: YOUR_KANARIE_API_KEY

````