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

# Integration Create

> Endpoint to create a new integration for a GPT.

Args:
    gpt_name (str): The name of the GPT model to integrate.

Returns:
    IntegrationModel: The created integration record, including website metadata.

Raises:
    HTTPException 400:
        - If an integration with the given name already exists.
        - If the GPT has no description available (required for the integration overview).
    HTTPException 404: If no GPT is found with the provided name.
    HTTPException 500: If any unexpected error occurs during creation.



## OpenAPI

````yaml post /api/integration/{gpt_name}/create
openapi: 3.1.0
info:
  title: Apigene
  description: Apigene API
  version: 1.0.0
  contact:
    name: Apigene Support
    url: https://app.apigene.ai
    email: support@apigene.ai
servers:
  - url: https://app.apigene.ai
security:
  - BearerAuth: []
paths:
  /api/integration/{gpt_name}/create:
    post:
      tags:
        - Integration
      summary: Integration Create
      description: |-
        Endpoint to create a new integration for a GPT.

        Args:
            gpt_name (str): The name of the GPT model to integrate.

        Returns:
            IntegrationModel: The created integration record, including website metadata.

        Raises:
            HTTPException 400:
                - If an integration with the given name already exists.
                - If the GPT has no description available (required for the integration overview).
            HTTPException 404: If no GPT is found with the provided name.
            HTTPException 500: If any unexpected error occurs during creation.
      operationId: integration_create
      parameters:
        - name: gpt_name
          in: path
          required: true
          schema:
            type: string
            title: Gpt Name
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IntegrationModel'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - BearerAuth: []
components:
  schemas:
    IntegrationModel:
      properties:
        state:
          type: string
          title: State
          description: Hold the integration state.
          default: draft
        gpt_name:
          type: string
          title: Gpt Name
          description: The name of the gpt for the integration.
        installs:
          additionalProperties: true
          type: object
          title: Installs
          description: Installation details.
          default: Less than 100
        website_details:
          anyOf:
            - $ref: '#/components/schemas/IntegrationWebsiteModel'
            - type: 'null'
          description: Website information for model.
        partner_info:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Partner Info
          description: Client details of an official partner.
      type: object
      required:
        - gpt_name
      title: IntegrationModel
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    IntegrationWebsiteModel:
      properties:
        overview:
          anyOf:
            - type: string
            - type: 'null'
          title: Overview
          description: Integration overview.
        tags:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Tags
          description: Integration SEO related tags.
        assets:
          anyOf:
            - $ref: '#/components/schemas/IntegrationAssets'
            - type: 'null'
          description: Integration video and image assets.
        details:
          anyOf:
            - $ref: '#/components/schemas/IntegrationDetails'
            - type: 'null'
          description: Integration details
      type: object
      title: IntegrationWebsiteModel
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    IntegrationAssets:
      properties:
        videos:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Videos
          description: Integration videos.
        images:
          items:
            type: string
          type: array
          title: Images
          description: Integration images.
        authentication_instructions:
          anyOf:
            - items:
                $ref: '#/components/schemas/APIInstructions'
              type: array
            - type: 'null'
          title: Authentication Instructions
          description: URL for GPT API authentication instructions.
      type: object
      title: IntegrationAssets
    IntegrationDetails:
      properties:
        developer:
          $ref: '#/components/schemas/Details'
          description: Developer details.
        website:
          $ref: '#/components/schemas/Details'
          description: Website details.
      type: object
      required:
        - developer
        - website
      title: IntegrationDetails
    APIInstructions:
      properties:
        api:
          type: string
          title: Api
          description: Name of the api
        url:
          type: string
          title: Url
          description: URL for API authentication instructions.
      type: object
      required:
        - api
        - url
      title: APIInstructions
    Details:
      properties:
        text:
          anyOf:
            - type: string
            - type: 'null'
          title: Text
          description: Details text.
        link:
          anyOf:
            - type: string
            - type: 'null'
          title: Link
          description: Details link.
      type: object
      title: Details
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        JWT Authorization header using the Bearer scheme. Example:
        'Authorization: Bearer {token}'

````