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

# Template Get Api

> Retrieves a specific template by UUID.



## OpenAPI

````yaml get /api/v1/template/{template_uuid}
openapi: 3.1.0
info:
  title: NinjaAPI
  version: 1.0.0
  description: ''
servers:
  - url: https://api.justpaid.io
security: []
paths:
  /api/v1/template/{template_uuid}:
    get:
      summary: Template Get Api
      description: Retrieves a specific template by UUID.
      operationId: loopfour_backend_template_api_external_template_get_api
      parameters:
        - in: path
          name: template_uuid
          schema:
            title: Template Uuid
            type: string
          required: true
      responses:
        '200':
          description: Template retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TemplateOut'
              example:
                uuid: 123e4567-e89b-12d3-a456-426614174000
                name: Enterprise Plan
                description: Complete solution for large organizations
                is_active: true
                options:
                  - uuid: 456e4567-e89b-12d3-a456-426614174000
                    name: Basic Option
                    description: Basic features package
                    services:
                      - uuid: 789e4567-e89b-12d3-a456-426614174000
                        service_type: fixed fee
                        billing_cycle: monthly
                        unit_price: 100
                        default_quantity: 1
                        plan_item_uuid: abc-123
                        plan_item_name: Basic Service
                        plan_item_description: Basic service description
                        discount_percent: 10
                        discount_duration: 3
                created_at: '2024-03-21T10:00:00Z'
                updated_at: '2024-03-21T10:00:00Z'
        '404':
          description: Template not found
          content:
            application/json:
              example:
                detail: Template with UUID X not found
      security:
        - HttpBearerAuth: []
components:
  schemas:
    TemplateOut:
      description: |-
        Schema for retrieving template information.

        Attributes:
            uuid (UUID): The unique identifier for the template.
            name (str): The name of the template.
            description (str): The description of the template.
            is_active (bool): Whether the template is active.
            options (List[OptionOut]): List of options associated with this template.
      properties:
        uuid:
          description: The unique identifier for the template.
          format: uuid
          title: Uuid
          type: string
        name:
          description: The name of the template.
          title: Name
          type: string
        description:
          description: The description of the template.
          title: Description
          type: string
        is_active:
          description: Whether the template is active.
          title: Is Active
          type: boolean
        options:
          description: List of options associated with this template.
          items:
            $ref: '#/components/schemas/OptionOut'
          title: Options
          type: array
        created_at:
          format: date-time
          title: Created At
          type: string
        updated_at:
          format: date-time
          title: Updated At
          type: string
      required:
        - uuid
        - name
        - description
        - is_active
        - options
        - updated_at
      title: TemplateOut
      type: object
    OptionOut:
      description: |-
        Schema for retrieving option information.

        Attributes:
            uuid (UUID): The unique identifier for the option.
            name (str): The name of the option.
            description (str): The description of the option.
            services (List[ServiceOut]): List of services associated with this option.
      properties:
        uuid:
          description: The unique identifier for the option.
          format: uuid
          title: Uuid
          type: string
        name:
          description: The name of the option.
          title: Name
          type: string
        description:
          description: The description of the option.
          title: Description
          type: string
        services:
          description: List of services associated with this option.
          items:
            $ref: '#/components/schemas/ServiceOut'
          title: Services
          type: array
        template_uuid:
          description: The UUID of the associated template.
          title: Template Uuid
          type: string
      required:
        - uuid
        - name
        - description
        - services
        - template_uuid
      title: OptionOut
      type: object
    ServiceOut:
      description: |-
        Schema for retrieving service information.

        Attributes:
            uuid (UUID): The unique identifier for the service.
            service_type (str): The type of service (fixed fee or usage based).
            billing_cycle (str): The billing cycle for the service.
            unit_price (Decimal): The price per unit for the service.
            default_quantity (Optional[int]): The default quantity for fixed fee services.
            usage_metric (Optional[str]): The metric used for usage based services.
            minimum_spend (Optional[Decimal]): The minimum spend amount for usage based services.
            allocated_units (Optional[int]): The number of allocated units.
            allocated_units_billing_cycle (Optional[str]): The billing cycle for allocated units.
      properties:
        uuid:
          description: The unique identifier for the service.
          format: uuid
          title: Uuid
          type: string
        service_type:
          description: The type of service (fixed fee or usage based).
          title: Service Type
          type: string
        billing_cycle:
          description: The billing cycle for the service.
          title: Billing Cycle
          type: string
        unit_price:
          description: The price per unit for the service.
          title: Unit Price
          type: number
        plan_item_uuid:
          description: The UUID of the associated plan item.
          title: Plan Item Uuid
          type: string
        plan_item_name:
          description: The name of the associated plan item.
          title: Plan Item Name
          type: string
        plan_item_description:
          description: The description of the associated plan item.
          title: Plan Item Description
          type: string
        option_uuid:
          description: The UUID of the associated option.
          title: Option Uuid
          type: string
        default_quantity:
          anyOf:
            - type: integer
            - type: 'null'
          title: Default Quantity
        usage_metric:
          anyOf:
            - maxLength: 255
              type: string
            - type: 'null'
          title: Usage Metric
        minimum_spend:
          anyOf:
            - pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
              type: string
            - type: 'null'
          title: Minimum Spend
        allocated_units:
          anyOf:
            - type: integer
            - type: 'null'
          title: Allocated Units
        allocated_units_billing_cycle:
          anyOf:
            - maxLength: 20
              type: string
            - type: 'null'
          title: Allocated Units Billing Cycle
        discount_percent:
          anyOf:
            - pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
              type: string
            - type: 'null'
          description: Percentage discount to be applied (0-100)
          title: Discount Percent
        discount_duration:
          anyOf:
            - type: integer
            - type: 'null'
          description: Number of billing cycles the discount applies for
          title: Discount Duration
      required:
        - uuid
        - service_type
        - billing_cycle
        - unit_price
        - plan_item_uuid
        - plan_item_name
        - plan_item_description
        - option_uuid
      title: ServiceOut
      type: object
  securitySchemes:
    HttpBearerAuth:
      type: http
      scheme: bearer

````