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

# Create License

> Generates a new license key for the specified plugin with the given parameters



## OpenAPI

````yaml POST /plugins/{pluginId}/licenses
openapi: 3.0.1
info:
  title: MC License API
  description: API for validating and managing Minecraft plugin licenses
  version: 1.0.0
  license:
    name: MIT
servers:
  - url: https://api.mclicense.org
    description: Production API Server
security:
  - apiKey: []
paths:
  /plugins/{pluginId}/licenses:
    post:
      summary: Create a license for a plugin
      description: >-
        Generates a new license key for the specified plugin with the given
        parameters
      parameters:
        - name: pluginId
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - maxIps
                - expiresOn
              properties:
                maxIps:
                  type: integer
                  description: Maximum number of IP addresses allowed
                expiresOn:
                  type: string
                  description: Expiration date or 'Never'
                user:
                  type: string
                  description: Optional user identifier
      responses:
        '200':
          description: License created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/License'
components:
  schemas:
    License:
      type: object
      required:
        - key
        - pluginId
        - maxIps
      properties:
        key:
          type: string
          readOnly: true
          description: Unique license key (alphanumeric + hyphens, max 36 chars)
        pluginId:
          type: string
          description: ID of the associated plugin
        maxIps:
          type: integer
          description: Maximum number of IP addresses allowed
        expiresOn:
          type: string
          description: Expiration date in ISO 8601 format or 'Never'
        user:
          type: string
          description: Optional user identifier
        createdAt:
          type: string
          format: date-time
          readOnly: true
          description: License creation timestamp
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: MCL-Key
      description: API key must start with 'mcl_'

````