Getting started

Prerequisites

Acquire a BEARER token to be used in HTTP Authorization header for authentication.
Please contact us for any inquiry.

How to use the shape service

  1. Create a geometry file instance
    (POST /files)
  2. Upload your dxf/dwg file with the url and fields returned by previous request response. Once the file is uploaded, an async task will extract available layers from it.
  3. Wait for the file to be processed and ping it
    (GET /files or GET /files/{file_id})
    every couple of seconds until it is done (status changed to "Ok").
  4. Retrieve available layers from response
    (GET /files or GET /files/{file_id})
  5. Create configurations with all layers configured as 'cut' geometries
    (POST /configurations)
    At this point the following options are available to customize the configuration:

    • unit_system (String - either 'metric' or 'imperial')
    • scale (Numeric - > 0.0 and < 1.0)
    • split (Boolean): split geometries within the file or not
    • deduplicate (Boolean): regroup shapes based on geometries
    • remove_external (Boolean): remove external contour
  6. Wait for the configurations to be processed and ping
    (GET /configurations/)
    every couple of seconds until they are done (status changed to "Ok")

  7. Display png image from response in order to visualise how the shapes will be processed
  8. If necessary, go to step 5 to create new configurations with different layer types and different settings
  9. When you are satisfied with your configurations, extract the shapes from the configured files
    (POST /files/{file_id}/configurations/{configuration_id}/shapes)
  10. Wait for the shapes to be processed and ping the configuration
    (GET /configurations/)
    until they are done (shapes_status changed to "Ok")
  11. Extra: Use ShapeGroups URI to find total quantities between different files:
    (POST /shape-groups)
    then ping the group
    (GET /shape-groups/{shape_groups_id})
    until it has finished processing the shapes
    (status changed to "Ok")
    to find out which shapes have been grouped
  12. Done!

How to use the nesting result service

  1. Create an attachment instance for the PWS job json file
    (POST /attachments)
  2. Upload PWS job json file with the url and fields returned by previous request response.
  3. Repeat for the process for the PWS result json file.
  4. If you have created shapes immediately prior, got to step 9.
  5. For each shape associated with a part or imported sheet create an attachment instance
    (POST /attachments)
  6. Upload shape CPF file with the url and fields returned by previous request response.
  7. Create each shape from attachment
    (POST /shapes)
  8. Wait for the shapes to be processed and ping each shape (GET /shapes/{shape_id}) to check status is "Ok" before proceeding.
  9. Create nesting result using the shape IDs from the parts and imported sheets in the request body
    (POST /nestings)
  10. Fetch nesting result using the nesting ID
    (GET /nestings/{nesting_id})