# API Reference

    # Auto Sketch

    The Auto Sketch API makes it easy to convert 2D floorplans into 3D Collada files.
    Use the list below to see the different types of resources you can verify by using the API. It also supports methods for inserting, updating, or deleting information in the floorplan.
    The guide explains how you can utilize the API.
    Resource refers to Unique ID, information about drawings, Meta Data required to convert to 3D Collada files.
    In the guide, one or more representations are represented by the resource type, and resources are represented by JSON objects.
    Explains how to use one or more supported methods for each resource type (‘POST’, ‘GET’, ‘DELETE’, etc.).
    Requests for resources must use the API key or **provide the OAuth 2.0 token.
    Any insert, update, or delete request must send an authentication token.
    Resources use JSON media types.




    # [POST] - validity

    The validity resource validates the UUID, image, and area information of the drawing to be processed and registers it in the transformation queue. This method only accepts data with the following attributes: If it is invalid, it returns an error.

    • Restrictions
      • Unique ID that does not overlap.
      • Color model: RGB model
      • Depth: 8 Bit
      • Maximum file size : 10MB
      • Maximum image size : 1280 pixel
    • Request
      • uuid String
        (required)
        UUID of the floorplan to be converted.
      • image_path String
        (required)
        Image path of the floorplan to be converted.
      • unit_area Number
        (required)
        Area of the house (Square meter,㎡).
        Based on SI unit system ㎡.
    • Response
      {
        "code": number, // Response status code of the requested result.
        "message": string // Response status message of the requested result.
      }
      
      1
      2
      3
      4
      • Error
        • AccessDeniedException
          Do not have the authorization to perform the action.
          {
              "code": 400,
              "message": "AccessDeniedException"
          }
          
          1
          2
          3
          4
        • IntegrityError
          The UUID is not unique.
          {
              "code": 400,
              "message": "IntegrityError"
          }
          
          1
          2
          3
          4
        • InvalidImageFormatException
          The image format provided is not supported.
          {
              "code": 400,
              "message": "InvalidImageFormatException"
          }
          
          1
          2
          3
          4
        • InvalidParameterException
          The input parameter violated the constraint.
          {
              "code": 400,
              "message": "InvalidParameterException"
          }
          
          1
          2
          3
          4
        • ImageTooLargeException
          The image size exceeds the allowed limit.
          {
              "code": 400,
              "message": "ImageTooLargeException"
          }
          
          1
          2
          3
          4
        • UnitAreaException
          The input area does not meet the allowed limit.
          {
              "code": 400,
              "message": "UnitAreaException"
          }
          
          1
          2
          3
          4

    # [GET] - analysis/<uuid>/

    The analysis resource analyzes the drawing and returns the results of the analysis. If the analysis fails, it returns an error.

    • Request
      • uuid String
        (required)
        UUID of the drawing to be converted.
    • Response
      {
          "code": number, // Response status code of the requested result. 
          "message": string // Response status message of the requested result. 
      }
      
      1
      2
      3
      4
      • Error
        • AccessDeniedException
          You do not have the authorization to perform the action.
          {
              "code": 400,
              "message": "AccessDeniedException"
          }
          
          1
          2
          3
          4
        • NotFoundException
          The requested floorplan could not be found.
          {
              "code": 400,
              "message": "NotFoundException"
          }
          
          1
          2
          3
          4
        • DetectionException
          Failed to detect the Auto Sketch Detection
          {
              "code": 400,
              "message": "DetectionException"
          }
          
          1
          2
          3
          4
        • InvalidParameterException
          The input parameter violated the constraint.
          {
              "code": 400,
              "message": "InvalidParameterException"
          }
          
          1
          2
          3
          4
        • InternalServerError
          There was a problem with Auto Sketch Engine.
          {
              "code": 400,
              "message": "InternalServerError"
          }
          
          1
          2
          3
          4

    # [GET] - metadata/<uuid>/

    Returns metadata from AutoSketch Engine. If metadata generation fails, it returns an error. This request requires permission to perform.

    • Request

      • uuid String
        (required)
        UUID of the drawing to be converted.
    • Response

      {
          "code": number, // Response status code of the processed result. 
          "message": string, // Response status message of the processed result.
          "data": [ // Conversion data of the processed result. 
              {
                  "uuid": string, // UUID of the converted floorplan. 
                  "scale": number, // Scale of the converted floorplan. 
                  "version": number, // Version of Auto Sketch Engine. 
                  "wall": [ // Information of the analyzed wall. 
                      {
                          number,
                      },
                  ],
                  "doors": [ // Information of the analyzed door. 
                      {
                          "angle": number, // Angle of the analyzed door. 
                          "point": [number, number], // Location of the analyzed door. 
                          "size": number, // Size of the analyzed door. 
                          "type": number // Type of the analyzed door. 
                      }
                  ],
                  "windows": [ // Information of the analyzed window. 
                      {
                          "angle": number, // Angle of the analyzed window. 
                          "point": [number, number], // Location of the analyzed window. 
                          "size": number, // Size of the analyzed window. 
                          "type": number // Type of the analyzed window. 
                      }
                  ],
                  "rooms": [ // Information of the analyzed room.
                      {
                          "poly": [ // Location of the analyzed room.
                              {
                                  number
                              },
                          ],
                          "area": number, // Area of the analyzed room. 
                          "type": string // Type of the analyzed room. 
                      }
                  ]            
              }
          ]
      }
      
      1
      2
      3
      4
      5
      6
      7
      8
      9
      10
      11
      12
      13
      14
      15
      16
      17
      18
      19
      20
      21
      22
      23
      24
      25
      26
      27
      28
      29
      30
      31
      32
      33
      34
      35
      36
      37
      38
      39
      40
      41
      42
      43
      • Error
        • AccessDeniedException
          You do not have the authorization to perform the action.
          {
              "code": 400,
              "message": "AccessDeniedException"
          }
          
          1
          2
          3
          4
        • NotFoundException
          The requested floorplan could not be found.
          {
              "code": 400,
              "message": "NotFoundException"
          }
          
          1
          2
          3
          4
        • DetectionException
          Failed to detect the Auto Sketch Detection.
          {
              "code": 400,
              "message": "DetectionException"
          }
          
          1
          2
          3
          4
        • InternalServerError
          There was a problem with Auto Sketch Engine.
          {
              "code": 400,
              "message": "InternalServerError"
          }
          
          1
          2
          3
          4

    # [GET] - exporter/<uuid>/

    It combines the data from AutoSketch Engine and returns 3D buildings with a DAE extension of collada format. If 3D file creation fails, it returns an error.

    • Request
      • uuid String
        (required)
        The uuid of the drawing to be converted.
    • Response
      {
          "code": number, // Response status code of the processed result. 
          "message": string, // Response message code of the processed result.
          "data": [ // Conversion data of processed result. 
              {
                  "uuid": string, // The uuid of the converted floorplan. 
                  "result_path": string // The generated DAE file. 
              }
          ]
      }
      
      1
      2
      3
      4
      5
      6
      7
      8
      9
      10
      • Error
        • AccessDeniedException
          You do not have the authorization to perform the action.
          {
              "code": 400,
              "message": "AccessDeniedException"
          }
          
          1
          2
          3
          4
        • NotFoundException
          The requested floorplan could not be found.
          {
              "code": 400,
              "message": "NotFoundException"
          }
          
          1
          2
          3
          4
        • DetectionException
          Failed to detect the Auto Sketch Detection engine.
          {
              "code": 400,
              "message": "DetectionException"
          }
          
          1
          2
          3
          4
        • InternalServerError
          There was a problem with Auto Sketch Engine.
          {
              "code": 400,
              "message": "InternalServerError"
          }
          
          1
          2
          3
          4
    top button