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

# Create a shareable invite link (admin only)



## OpenAPI

````yaml https://portal.unicontrol.me/v1/openapi post /v1/organizations/{id}/invite-links
openapi: 3.1.0
info:
  title: Unicontrol API
  description: Welcome
  version: 1.0.0
servers:
  - url: http://0.0.0.0:3000
    description: Local Server
  - url: https://portal.test.flexhome.casa
    description: Development
  - url: https://portal.unicontrol.me
    description: Production
security:
  - bearerAuth: []
paths:
  /v1/organizations/{id}/invite-links:
    post:
      tags:
        - Organizations
      summary: Create a shareable invite link (admin only)
      operationId: postV1OrganizationsByIdInvite-links
      parameters:
        - in: path
          name: id
          required: true
          schema:
            type: string
          description: ID da organização
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                expires_in_days:
                  type: integer
                  nullable: true
                  description: 'Dias até expirar. null = nunca expira. Padrão: 7.'
                max_uses:
                  type: integer
                  nullable: true
                  description: Limite de usos. null = ilimitado.
            example:
              expires_in_days: 7
              max_uses: null
      responses:
        '201':
          description: Invite link created
          content:
            application/json:
              example:
                id: 1
                token: AbC123xyZ
                url: https://app/invite/AbC123xyZ
                expires_at: '2026-06-04T12:00:00Z'
                max_uses: null
                uses_count: 0
                revoked: false
        '401':
          description: Não autenticado
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
              example:
                error: unauthorized
        '403':
          description: Acesso negado
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
              example:
                error: forbidden
        '500':
          description: Erro interno do servidor
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
              example:
                error: internal_error
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````